<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>ASP.NET MSSQL Webhosting Blog &#187; SQL Server</title>
	<atom:link href="http://www.mywebhostingblog.net/tag/sql-server/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.mywebhostingblog.net</link>
	<description>ASP.NET, MSSQL and Windows dedicated server articles</description>
	<lastBuildDate>Tue, 10 Nov 2009 19:53:03 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>About MSSQL Server</title>
		<link>http://www.mywebhostingblog.net/mssql-server-hosting/about-mssql-server/</link>
		<comments>http://www.mywebhostingblog.net/mssql-server-hosting/about-mssql-server/#comments</comments>
		<pubDate>Tue, 17 Mar 2009 06:36:32 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[MSSQL Server]]></category>
		<category><![CDATA[Microsoft SQL]]></category>
		<category><![CDATA[MSSQL]]></category>
		<category><![CDATA[SQL Server]]></category>

		<guid isPermaLink="false">http://www.mywebhostingblog.net/?p=29</guid>
		<description><![CDATA[The architecture of Microsoft MSSQL Server is mainly divided into three components: 1. SQLOS: which implements the basic services required by MS SQL Server, including thread scheduling, I/O stat management and memory management. 2. Relational Engine: which implements the relational database components including support for databases, tables, queries and stored procedures as well as implementing [...]]]></description>
			<content:encoded><![CDATA[<p>The architecture of <strong>Microsoft MSSQL Server</strong> is mainly divided into three components:</p>
<p>1. <strong>SQLOS</strong>: which implements the basic services required by <strong>MS SQL Server</strong>, including thread scheduling, I/O stat management and memory management.</p>
<p>2. <strong>Relational Engine:</strong> which implements the relational database components including support for databases, tables, queries and stored procedures as well as implementing the type system.</p>
<p>3. <strong>Protocol Layer:</strong> which exposes the <strong>MS SQL Server </strong>functionality.</p>
<p><strong>SQLOS</strong></p>
<p><span id="more-29"></span></p>
<p>SQLOS is the base component in the <strong>Windows</strong> <strong>SQL Server</strong> architecture. It implements functions normally associated with the <strong>Operating System</strong>, thread scheduling, memory management, I/O management, buffer pool management, resource management, synchronization primitives and locking, and deadlock detection. Because the requirements of <strong>Windows SQL Server</strong> are highly specialized, it implements its own memory and thread management system, rather than using the generic one implemented in the OS. <strong>SQLOS</strong> also includes synchronization primitives for locking as well as monitoring for the worker threads to detect and recover from deadlocks.</p>
<p><strong>SQLOS</strong> handles the memory requirements of <strong>MS SQL Server</strong> as well. Reducing disc I/O is one of the primary goals of specialized memory management in SQL Server. It maintains a buffer pool, which is used to cache data pages from the disc, and to satisfy the memory requirements for the query processor, and for other internal data structures. <strong>SQLOS</strong> monitors all the memory allocated from the buffer pool, ensuring that the components return unused memory to the pool, and shuffles data out of the cache to make room for newer data. For changes that are made to the data in buffer, <strong>SQLOS</strong> writes the data back to the disc lazily, that is when the disc subsystem is either free, or there have been significant numbers of changes made to the cache, while still serving requests from the cache. For this, it implements a Lazy Writer, which handles the task of writing the data back to persistent storage.</p>
<p><strong>WIndows SQL Server</strong> normally supports up to 2 GB memory on x86 hardware, though it can be configured to use up to 64 GB if the Address Windowing Extension is used in the supporting operating system. For x64 hardware, it supports 8 TB of memory, and 7 TB for IA-64 systems (currently it is limited by Windows Server 2003 SP1 to 1TB). However, when running x86 versions of SQL Server on x64 hardware, it can access 4 GB of memory without any special configuration.</p>
<p><strong>Relational Engine:</strong></p>
<p>The Relational engine implements the relational data store using the capabilities provided by<strong> SQLOS</strong>, which is exposed to this layer via the private <strong>SQLOS</strong> API. It implements the type system, to define the types of the data that can be stored in the tables, as well as the different types of data items (such as tables, indexes, logs etc) that can be stored. It includes the Storage Engine, which handles the way data is stored on persistent storage devices and provides methods for fast access to the data. The storage engine implements log-based transaction to ensure that any changes to the data are ACID compliant. It also includes the query processor, which is the component that retrieves data. <strong>MSSQL</strong> queries specify what data to retrieve, and the query processor optimizes and translates the query into the sequence of operations needed to retrieve the data. The operations are then performed by worker threads, which are scheduled for execution by <strong>SQLOS</strong>.</p>
<p><strong>Protocol Layer:</strong></p>
<p>Protocol layer implements the external interface to <strong>MS SQL Server.</strong> All operations that can be invoked on <strong>MSSQL Server</strong> are communicated to it via a <strong>Microsoft</strong>-defined format, called Tabular Data Stream (TDS). TDS is an application layer protocol, used to transfer data between a database server and a client. Initially designed and developed by Sybase Inc. for their Sybase <strong>MS SQL Server</strong> relational database engine in 1984, and later by Microsoft in <strong>Microsoft MS SQL Server</strong>, TDS packets can be encased in other physical transport dependent protocols, including TCP/IP, Named pipes, and Shared memory. Consequently, access to <strong>MSSQL Server</strong> is available over these protocols. In addition, the <strong>MSSQL Server</strong> API is also exposed over web services.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mywebhostingblog.net/mssql-server-hosting/about-mssql-server/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Group Policies Overview for SQL Server</title>
		<link>http://www.mywebhostingblog.net/hosting-security/group-policies-overview-for-sql-server/</link>
		<comments>http://www.mywebhostingblog.net/hosting-security/group-policies-overview-for-sql-server/#comments</comments>
		<pubDate>Fri, 27 Feb 2009 08:08:14 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[Hosting Security]]></category>
		<category><![CDATA[MSSQL Server]]></category>
		<category><![CDATA[Window Hosting]]></category>
		<category><![CDATA[SQL 2005]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Windows 2003]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://www.mywebhostingblog.net/?p=368</guid>
		<description><![CDATA[Group Policy is a core part of Microsoft’s IntelliMirror technology.You can use Group Policy to manage all aspects of the Server environment for Windows Server, including Registry settings, software installation, scripts, security settings, and so on.The possibilities of what can be done with Group Policy are almost limitless.With VBScript or Jscript, you can write entire [...]]]></description>
			<content:encoded><![CDATA[<p>Group Policy is a core part of <strong>Microsoft’s IntelliMirror technology</strong>.You can use Group Policy to manage all aspects of the Server environment for <strong>Windows Server</strong>, including Registry settings, software installation, scripts, security settings, and so on.The possibilities of what can be done with Group Policy are almost limitless.With <strong>VBScript</strong> or Jscript, you can write entire applications to execute via Group Policy.You can install software automatically across the network and apply patches to applications. When deciding on the <strong>Group Policies</strong> you plan to enforce on your network, you should keep in mind that the more policies applied, the more network traffic, and hence the longer it could take for users to log onto the network. Group policies are stored in Active Directory as Group Policy Objects (<strong>GPO</strong>).These objects are the instructions for the management task to perform. Group Policy is implemented in four ways:</p>
<p><span id="more-368"></span><strong>Local Group Policy: </strong><br />
Using local Group Policy involves setting up Group Policy on the local machine.This is not very useful for managing computers on a network. Local Group Policy is configured on the local computer.</p>
<p><strong>Site Group Policy:</strong></p>
<p>Site Group Policy is when the Group Policy object is linked to the site. Site Group Policies can generate unwanted network traffic, so use these only when absolutely necessary.</p>
<p><strong>Domain Group Policy:</strong><br />
Domain Group Policy is when the Group Policy object is linked to the domain.This will apply the Group Policy object to all computers and users within a domain.This is especially useful for enforcing company-wide settings.This is one of the two most commonly used applications of Group Policy.</p>
<p><strong>Organizational Unit:</strong><br />
Group Policy When the Group Policy object is linked to the organizational unit (OU). Organizational unit Group Policy is especially useful for applying a Group Policy object to a logical grouping (organizational unit) of users or computers.</p>
<p>When a <strong>Windows Server</strong> machine logs on to a Windows AD, any legacy Windows 2000<strong> Group Policies </strong>will be applied to and work on Windows Server. The new Windows Group Policy snap-in will work on a <strong>Windows 2000 </strong>AD as well as <strong>Windows 2003</strong>.You can use the Windows Group Policy snap-in to connect to any Group Policy object in the Active Directory.You can also create a new Group Policy object using this snap-in. When you connect to a <strong>GPO</strong> using this snap-in, the <strong>ADM </strong>files are automatically updated using the newer versions of these files found on Windows XP.</p>
<p>Windows has over 200 policies.These policies are reflected in the new <strong>ADM </strong>files that are updated on the domain.The Windows admin snap-in shows what policies work on which clients. Best practice in a mixed environment: Use the Latest Windows Group Policy snap-in to administer Group Policy because it will display what policies are supported on what clients.</p>
<p><strong>Group Policy Order</strong></p>
<p>When Group Policies are applied in Windows Server, they are applied in a specific order.This is important to note because the order applied can affect the resulting policy. Group Policy is applied in the following order:</p>
<p>■ Windows NT 4 Policies (if any exist)<br />
■ Windows 2000 Policies<br />
■ Local Group Policies<br />
■ Site Group Policies<br />
■ Domain Group Policies<br />
■ Organizational Group Policy Objects (going from Highest Parent in the chain to lowest)</p>
<p>Additionally, the result of all of the applied policies can be determined by using the Resultant Set of Policy (RSOP) snap-in. More information on this topic is covered later in the “Resultant Set of Policy (RSOP)” section. Figure A.1 shows how Group Policy is applied by different organizational units along with the domain Group Policy.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mywebhostingblog.net/hosting-security/group-policies-overview-for-sql-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Secure MS SQL 2005 Database with EFS Encryption</title>
		<link>http://www.mywebhostingblog.net/aspnet-web-hosting/secure-ms-sql-2005-database-with-efs-encryption/</link>
		<comments>http://www.mywebhostingblog.net/aspnet-web-hosting/secure-ms-sql-2005-database-with-efs-encryption/#comments</comments>
		<pubDate>Wed, 18 Feb 2009 05:55:31 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[ASP.NET Web Hosting]]></category>
		<category><![CDATA[Hosting Security]]></category>
		<category><![CDATA[MSSQL Server]]></category>
		<category><![CDATA[Window Hosting]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[SQL 2005]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.mywebhostingblog.net/?p=340</guid>
		<description><![CDATA[EFS Encryption EFS can be used to encrypt SQL Server 2005 data files and folders. EFS is supported on Windows 2000 and later operating systems with New Technology File Systems (NTFS) formatted drives. EFS uses a combination of symmetric and asymmetric methods to provide transparent SQL Server 2005 data encryption. On Windows 2003 Server and [...]]]></description>
			<content:encoded><![CDATA[<p><strong>EFS Encryption</strong></p>
<p>EFS can be used to encrypt <strong>SQL Server 2005</strong> data files and folders. EFS is supported on <strong>Windows 2000</strong> and later operating systems with New Technology File Systems (<strong>NTFS</strong>) formatted drives. <strong>EFS </strong>uses a combination of symmetric and asymmetric methods to provide transparent SQL Server 2005 data encryption. On <strong>Windows 2003 Server</strong> and newer operating systems, EFS by default creates a random <strong>File Encryption Key</strong>, which is a 256-bit AES key to perform data encryption.The File Encryption Key is then itself encrypted with the user’s public key and stored within the encrypted file or folder.</p>
<p><strong>To encrypt SQL Server 2005 data files and folders using EFS, follow these steps:</strong></p>
<p>1. Stop the <strong>SQL Server</strong> service.<br />
2. Log out and log in using the<strong> SQL Server </strong>service account credentials.<br />
3. Right-click on the file or folder to be encrypted and select <strong>Properties | General Tab | Advanced.</strong></p>
<p><span id="more-340"></span><br />
4. Within the Advanced attributes window, select Encrypt contents to secure data.<br />
5. Within the Advanced attributes window, press OK.<br />
6. Within the Properties tab, press OK.<br />
7. If you are encrypting a folder containing subfolders, you will be presented with another window asking if you would like to  encrypt them as well. Press OK.<br />
8. <strong>EFS encrypted files</strong> and folder names should now appear in green within any Windows file explorer window.<br />
9. Restart the <strong>SQL Server</strong> services.</p>
<p>If errors are generated, you may have encrypted the<strong> SQL Serve</strong>r data files using an account that is not linked to the <strong>SQL Server</strong> service account.You can decrypt the data folders by reversing the steps above and trying again. When encrypting individual database files, EFS first creates a plain text copy of the file to be encrypted, encrypts the target file, and then deletes the temporary file.This temporary file is not securely deleted and can be recovered using common data recovery tools. To prevent local file disclosure, you should use a secure data deletion tool to overwrite the areas of disk containing the temporary file. Alternatively, you can simply encrypt the parent folder that contains the database files to ensure any temporary files are also encrypted.</p>
<p><strong>EFS encryption</strong> is beneficial if the database media is stolen or misplaced. When transferring<strong> EFS encrypted</strong> files over the network, Windows first decrypts the file and then transfers the plain text equivalent. Some administrators perform manual backups of database files prior to implementing changes on the database server. If this backup involves copying data files from one server to another, you will effectively be storing an unencrypted copy of your database on the destination server.</p>
<p><strong>Encryption File System Contains Inherit Flaws</strong></p>
<p>On <strong>Windows Server 2003</strong>, EFS uses a strong 256-bit AES key to encrypt data. Under most circumstances, this would be an effective method of encryption; however, this AES key is protected by the user’s public key, which is based on the user’s Windows login password. This ultimately reduces EFS protection to the strength of the user’s Windows password. There are publicly available tools that can successfully decrypt EFS encrypted data by exploiting this flaw. Because of this, EFS should not be used to encrypt sensitive database data.</p>
<p><strong>Working with EFS Encrypted Data</strong></p>
<p>EFS encryption is managed by the operating system, and seamlessly provides file and folder encryption to <strong>SQL Server 2005</strong>. All <strong>SQL Serve</strong>r functions and operations remain unchanged when using this encryption method. Because EFS is handled outside of SQL Server 2005, encryption keys must be backed up separately in addition to your database backups.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mywebhostingblog.net/aspnet-web-hosting/secure-ms-sql-2005-database-with-efs-encryption/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Pass Phrases to Encrypt Data in MSSQL 2005</title>
		<link>http://www.mywebhostingblog.net/aspnet-web-hosting/using-pass-phrases-to-encrypt-data-in-mssql-2005/</link>
		<comments>http://www.mywebhostingblog.net/aspnet-web-hosting/using-pass-phrases-to-encrypt-data-in-mssql-2005/#comments</comments>
		<pubDate>Wed, 22 Oct 2008 04:43:46 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[ASP.NET Web Hosting]]></category>
		<category><![CDATA[Hosting Security]]></category>
		<category><![CDATA[MSSQL Server]]></category>
		<category><![CDATA[Window Hosting]]></category>
		<category><![CDATA[SQL 2005]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.mywebhostingblog.net/?p=360</guid>
		<description><![CDATA[Using Pass Phrases to Encrypt Data A password that allows for spaces can be referred to as a pass phrase. The benefit of pass phrases is that you can make them meaningful and easy to remember. Instead of creating and managing encryption keys or certificates in your database server, you can encrypt data using only [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Using Pass Phrases to Encrypt Data</strong></p>
<p>A password that allows for spaces can be referred to as a pass phrase. The benefit of pass phrases is that you can make them meaningful and easy to remember. Instead of creating and managing encryption keys or certificates in your database server, you can encrypt data using only a pass phrase.The <strong>ENCRYPTBYPASSPHRASE</strong> statement uses the supplied pass phrase to generate a symmetric key, which is used to perform the actual data encryption. No key management is required, as the key will be recreated each time the same pass phrase is supplied.The common syntax of the<strong> ENCRYPTBYPASSPHRASE</strong> statement is as follows:</p>
<p><code>ENCRYPTBYPASSPHRASE ('PASSPHRASE', 'PLAINTEXT')</code></p>
<p>In this statement, <strong>PASSPHRASE </strong>specifies the data string to be used to derive an encryption key. <strong>PLAINTEXT </strong>specifies the data to be encrypted. No permissions are required to run the <strong>ENCRYPTBYPASSPHRASE </strong>statement.</p>
<p>The following syntax encrypts the string using the supplied pass phrase:</p>
<p><span id="more-360"></span></p>
<p><code>SELECT ENCRYPTBYPASSPHRASE('SQL Server 2005 Pass Phrase Encryption', 'pass phrase encryption test')</code></p>
<p>Here are the results:</p>
<p><code>0x01000000B0FA66E0152FB0B655B23439904E36F3ED5B758618BEED0F2A2BF918C6CF9DF685BC2A60A<br />
AD5E81D660BA5A396D1CA89</code></p>
<p>As mentioned earlier, the preceding results will differ from what you receive on your SQL Server.To decrypt data, you can use the <strong>DECRYPTBYPASSPHRASE</strong> statement.The general syntax of this statement is as follows:</p>
<p><code>DECRYPTBYPASSPHRASE ('PASSPHRASE', 'CIPHERTEXT')</code></p>
<p>In this statement, <strong>PASSPHRASE </strong>specifies the data string to be used to derive a decryption key. <strong>CIPHERTEXT </strong>specifies the data to be decrypted. Similar to the <strong>ENCRYPTBYPASSPHRASE </strong>statement, no permissions are required to execute the <strong>DECRYPTBYPASSPHRASE </strong>statement.The following syntax uses the <strong>DECRYPTBYPASSPHRASE </strong>statement to decrypt the previously encrypted data, and converts it into the human readable varchar format:</p>
<p><code>SELECT CAST (DECRYPTBYPASSPHRASE('SQL Server 2005 Pass Phrase Encryption',<br />
0x01000000B0FA66E0152FB0B655B23439904E36F3ED5B758618BEED0F2A2BF918C6CF9DF685BC2A60A<br />
AD5E81D660BA5A396D1CA89) AS varchar)</code></p>
<p>Note that you should substitute the cipher text in the preceding statement with the cipher text that you obtained from the earlier <strong>ENCRYPTBYPASSPHRASE </strong>statement. Here is what the results of running the preceding statement will look like:<br />
<code><br />
pass phrase encryption test</code></p>
<p>The encryption algorithm and key length used by pass phrase encryption have not been formally documented by Microsoft. Because of this, it is recommended that you do not use this encryption mechanism to encrypt sensitive data.</p>
<p><strong>Flaws within Microsoft Object Encryption</strong></p>
<p>The object encryption used by Microsoft is weak, and there are publicly available scripts that can successfully decrypt the objects. Further, at run-time, SQL Server internally decrypts the object and SQL Profiler can be used to capture object logic in plain text form. Due to this, object encryption should not be used to encrypt sensitive information, and you should not embed key or certificate passwords or pass phrases in SQL Server objects encrypted using objectbased encryption.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mywebhostingblog.net/aspnet-web-hosting/using-pass-phrases-to-encrypt-data-in-mssql-2005/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
