security-enhanced database platform. agenda business challenges and needs sql server 2008 features...

33
Security-Enhanced Database Platform

Upload: franklin-patterson

Post on 18-Jan-2016

212 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Security-Enhanced Database Platform

Page 2: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Agenda

Business challenges and needs SQL Server 2008 features

Trustworthy computing Surface Area Reduction Rich User Authentication Granular Access Control Hierarchical Encryption Auditing

Competition Press/Analyst Summary

Dan Shea
"SQL Server 2008 Security"- is that a product name?
Page 3: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Business Challenges

Data Reliability is a growing concern for many enterprises

Data Misuse & Detection/Privacy Violation Insider threat Identity theft Industrial espionage Government espionage

Recent regulations have mandated strict requirements for data security, data privacy and data integrity

Page 4: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Business Need

Ensure reliability, confidentiality, availability and integrity of data.

Demonstrate that good security practices are being followed in the database environment.

Provide a history of detailed auditing data for use by internal/external auditors.

Page 5: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

IntegrityConfidentiality

Reliability

SQL Server 2008 Security

Trustworthy Computing

*Surface Area Reduction through automated policiesSecurity updates

Kerberos/NTLMPassword Policy EnforcementEnd Point AuthenticationLogin credentials encryptedSingle sign-on

Native cryptographic capabilities

* Transparent Data Encryption

* Extensible Key Management

Principals andSecurablesRolesCatalog securityExecution ContextUser SchemaSeparation

* All Action AuditAudit actions to file, Windows Application Log, and Windows Security logCapture and audit DDL activities

Highly SecureConfiguration

GranularAuthorizationRich

Authentication AuditingData

Encryption

*: New Features in SQL Server 2008

Page 6: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Reduced Surface Area Configuration

Efforts made in reducing surfacearea include Some features are off by default

(except when you perform an upgrade) Granular permissions on SQL engine

and SQL Server Agent Users need VIEW DEFINITION permissions to see metadata

that they do not own New in SQL Server 2008, Surface Area Configurations

are handled by automated policy-based framework to help ensure compliance across the enterprise

Page 7: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

SQL Server 2008Authentication

More Secure Authentication framework By default For all types of logins

(including Standard SQL Logins) Common Authentication

Policy Enforcement Across all protocols/Logins

(including standard SQL Logins) Ease of security policy management

Granular control where needed Quick lockdown of access to server

when necessary

Page 8: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

AuthenticationFeatures

Default Secure channel for standard SQL logins No admin step required to get secure (secure by default)

NTLM and Kerberos for Windows logins Single Sign On Constrained delegation with Win2K3 (Granular control)

Endpoint Based Authentication Ability to choose which users connect over which protocols

Password Policy Enforcement Password complexity, Password expiration, Account lockout Common policy across the network for windows and SQL Granular control to turn on/off policy/expiration per login

Ability to disable a login Useful if login is compromised or user is fired

Page 9: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

SQL Server 2008Authorization Principle of Least Privileges Rich Access Control Model

Granular permissions Choice of appropriate scope (database, schema,

object, sub-object) Role Based Access control Application module based

access control Minimizing application impact for user management Both Data (above) and Metadata

Ease of security management

Page 10: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Authorization Features

Catalog Security Can only see metadata of entities you have access to

Module Execution Context Context for execution of statements in a module Can be used to create custom permission sets

Signatures on modules To prevent Trojan code Ability to grant access to modules

“Access, but only when going through a particular module” Granular Permission Control

Avoiding overloading of permissions in roles Permissions at multiple scopes

User Schema Separation For management purposes Dropping a user does not impact applications Reducing reliance on DBO schema for sharing semantics

Page 11: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Data Encryption

Why consider encryption? Additional layer of security Required by some

regulatory compliance laws In SQL Server 2000

Vendor support required In SQL Server 2005

Built-in support for explicit data encryption

In SQL Server 2008 Transparent data encryption Extensible key management

ThreatDetected

EmergencyProcedure

Server HighlyProtected

Page 12: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

SQL Server Cryptographic Capabilities

Transparent Data Encryption and Decryption built-in DDL for creation of

Symmetric Keys Asymmetric Keys and Certificates

Symmetric Keys and Private Keys are stored encrypted Securing the Keys themselves

Based on user passwords Automatic, using SQL Server key management

Page 13: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Encryption Algorithm Support

Algorithms andkey lengths vary by OpSys; depends on CSP (Cryptographic Services Provider)

Performance depends on size of data being ciphered

XP SP2 WS2003

DES 56 (64) 56 (64)

3DES 128 128

DESX 184 184

AES128 - 128

AES192 - 192

AES256 - 256

RC2 128 128

RC4 40 40

RC4_128 128 128

RSA 2048 2048

Page 14: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

It’s All About The Keys

Encryption keys needto be protected

Some keys need to be backed up If the keys are lost, data may be lost Therefore, ability to restore keys must exist

Keys may need to be regenerated In case of compromise of the keys

Keys may need to be sharedacross systems In the case, where encrypted

data is being shared

Page 15: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Encryption Hierarchy

Wraps Associatedwith

Secured By

Secured By

Secured By

Password Certificate

Public Key

Master Key Password

Service KeyDP API

Key

Private Key

KeySecured By

Page 16: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Database Master Key

Helps Secure private keys inside the database Explicitly created by owner of the database Support for regeneration and recovery

ALTER MASTER KEY DDL BACKUP/RESTORE MASTER KEY DDL

Secured using user password Stored in the database

Can also be secured usingService Master Key

Always take a backup!

Page 17: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Service Master Key

Used to help secure system data Linked server passwords Database Master keys Proxy credentials

Created upon first use Support for regeneration and recovery

ALTER SERVICE MASTER KEY DDL BACKUP/RESTORE SERVICE MASTER KEY DDL

Secured using DPAPI Includes the service account’s credentials Be sure to use the tools we provide to change

the service account Always take a backup!

Page 18: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Certificates VersusAsymmetric Keys

Not much difference, they wrap key pair It’s about

Packaging Flexibility of formats

Page 19: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Extensible Key Management – New in SQL Server 2008

Use third party key management systems• Simplify key

management

Employ enterprise-wide encryption• Consolidate and

simplify encryption across the enterprise

Separate data from keys with Hardware Security Modules• Store keys in

removable hardware such as USB drives

Page 20: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Extensible Key Management Benefits

Physical separation of data and keys Additional authorization check (separation of duties) Higher performance for hardware based encryption/decryption Ability to store keys from all across the enterprise in one place for

easy management Enterprise Key Managers enable and enhance functionality not

available in the SQL Server Engine: Key Generation Key Storage – Keeping data separate from the keys that protect it is a

best practice Key Retrieval Key Retention – Rotating keys is important to reduce the risk of one key

getting compromised Key Recovery Key Distribution Key Disposal

Page 21: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Transparent Data Encryption – New in SQL Server 2008

Encryption/decryption occurs at the database Uses Database Encryption Key

(DEK) Applications do not need to

handle encryption/decryption of data Treat encrypted and unencrypted

data in an identical way DEK is encrypted with:

Password Service Master Key Hardware Security Module

DEK must be decrypted to attach database files or restore a backup

SQL Server 2008

DEK

Client Application

Encrypted data page

Page 22: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

A lost or

stolen

laptop

contains SQL Serv

er database with sensitive data

A disconte

nt employee copies

the database files and take

s the

m to a

competit

or

An unauthorized user obtains the backup tapes for a database

Transparent Data Encryption Scenarios

Without the required password or HSM to decrypt the DEK, the database cannot be opened.

Page 23: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Using CertificatesTo Sign Modules

Scenario: “Want to grant access to a resource,but only when going through a particular module”

Execute AS support can solve this, but… Changes execution context

Another option: Signed modules Sign the module using a certificate Grant the relevant permissions to the certificate

At execution time Certificate temporarily added to token for duration of module Context of execution remains unchanged Access is granted by virtue of presence of certificate in token

Page 24: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Encryption Over The Wire

Login Credentials Encryption Uses SSL certificate from certificate store

(if available) Can be explicitly chosen Otherwise, will use SQL generated Certificate

Data packets can be encrypted Server Side Option: ‘Force Protocol Encryption’ Client Side: Encryption with or without certificate

validation

Page 25: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Data Access Audit

• SQL Trace – the server side of profiling• Auditing is performed by SQL Trace – internal

to SQL Server• Exposed through stored procedures• Can be called directly or through the

SQL Server Profiler UI• SQL Server 2008 includes audit events around

impersonation and schema management

Page 26: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Login Auditing

• Record of login activity• Necessary to keep track of potential brute force

attempts• SQL Server 2008 defaults to auditing failed login

attempts• Audit events written to error log and Windows

application log

Page 27: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

All Action Auditing – New in SQL Server 2008

Create an Audit object to automatically log actions to: File Windows Application Log Windows Security Log

Create an Audit Specification to include server and database actions in an audit Pre-defined action groups Individual action filters

Page 28: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Creating An Audit

CREATE SERVER AUDIT Statement

CREATE SERVER AUDIT HIPAA_File_Audit TO FILE ( FILEPATH=’\\SQLPROD_1\Audit\’ ); CREATE SERVER AUDIT HIPAA_AppLog_Audit TO APPLICATION_LOG WITH ( QUEUE_DELAY = 500, ON_FAILURE = SHUTDOWN);

Page 29: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Creating Audit Specifications

CREATE SERVER AUDIT SPECIFICATION

CREATE DATABASE AUDIT SPECIFICATION

CREATE SERVER AUDIT SPECIFICATION Failed_Login_SpecFOR SERVER AUDIT HIPAA_File_Audit ADD (FAILED_LOGIN_GROUP);

CREATE DATABASE AUDIT SPECIFICATION Sales_Audit_SpecFOR SERVER AUDIT HIPAA_AppLog_Audit ADD (DATABASE_OBJECT_CHANGE_GROUP), ADD (INSERT, UPDATE, DELETE ON Schema::Sales BY SalesUser, SalesAdmin);

Page 30: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Custom Auditing

• DML triggers– Can be used to audit data modifications

• DDL triggers– Custom audit DDL changes

• Event notifications– Uses Service Broker – Asynchronous audit of operations

Page 31: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

#

of

CV

E

Notes: Updated as of 10/18/2007. Vulnerabilities are included for SQL Server 2000 , SQL Server 2005 . Oracle (8i, 9i, 9iR2, 10g, 10gR2)Query for Oracle was run with vendor name: ‘Oracle’ , and product name: ‘any’ (all database product name variations were queried) .Query for Microsoft was run with vendor name: ‘Microsoft ‘ ; product name: ‘Microsoft SQL Server’; version name: ’Any’

Source: NIST National Vulnerability Database

2002 2003 2004 2005 2006 20070

40

80

120

160

24

3 0 0 0 0

46

1225

61

144

41

SQL Server Oracle Database

SQL Server Security vulnerabilities to date

Page 32: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

Summary

Surface Area Configuration Manager New features are disabled by default using automated policy-based management

framework Policy-based User Authentication More granular permission model

Separation of users/schemas Execution context switching Catalog security

Data encryption both in transit and at rest Transparent data encryption Extended 3rd party key management

Auditing All Actions Audit DDL Triggers

Page 33: Security-Enhanced Database Platform. Agenda  Business challenges and needs  SQL Server 2008 features  Trustworthy computing  Surface Area Reduction

© 2006 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation.

MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

Dan Shea
AdLaw fairly recently reevaluated our policy regarding use of the legalese that has been required for marketing and advertising collateral. Going forward, LCA has agreed that the copyright and trademark notices are not required for most advertising and marketing materials, with the following limited exceptions:1) all packaging2) when third party credits are contractually required (in which case Microsoft credits will also be included); and3) if it is required by LCA for a specific purpose, which should be very rare.