TechEd Africa 2011 - OFC308: SharePoint Security in an Insecure World: Understanding the Five Layers of SharePoint Security


Published on

One of the biggest advantage of using SharePoint as a Document Management and collaboration environment is that a robust security and permissions structure is built-in to the application itself. Authenticating and authorizing users is a fairly straightforward task, and administration of security permissions is simplified. Too often, however, security for SharePoint stops there, and organizations don’t pay enough attention to all of the other considerations that are part of a SharePoint Security stack, and more often than not don’t properly build them into a deployment. This includes such diverse categories including Edge, Transport, Infrastructure, Data, and Rights Management Security, all areas that are often neglected but are nonetheless extremely important. This session discusses the entire stack of Security within SharePoint, from best practices around managing permissions and ACLs to comply with Role Based Access Control, to techniques to secure inbound access to externally-facing SharePoint sites. The session is designed to be comprehensive, and includes all major security topics in SharePoint and a discussion of various real-world designs that are built to be secure. • Understand how to use native technologies to secure all layers of a SharePoint environment, including Data, Transport, Infrastructure, Edge, and Rights Management. • Examine tools and technologies that can help secure SharePoint, including AD Rights Management Services, Forefront Unified Access Gateway, SQL Transparent Data Encryption, and more. • Understand a Role-Based Access Control (RBAC) permissions model and how it can be used to gain better control over authorization and access control to SharePoint files and data

Published in: Technology
  • Be the first to comment

TechEd Africa 2011 - OFC308: SharePoint Security in an Insecure World: Understanding the Five Layers of SharePoint Security

  1. 17-20 OCTOBER 2011<br />DURBAN ICC<br />
  2. SharePoint Security in an Insecure World<br />Understanding the Five Layers of SharePoint Security<br />OFC308<br />
  3. SharePoint SecurityLayers of Security in a SharePoint Environment<br />1: Infrastructure Security<br />Physical Security<br />Best Practice Service Account Setup<br />Kerberos Authentication<br />2: Data Security<br />Role Based Access Control (RBAC)<br />Transparent Data Encryption (TDE) of SQL Databases<br />Antivirus<br />3: Transport Security<br />Secure Sockets Layer (SSL) from Client to Server<br />IPSec from Server to Server<br />4: Edge Security<br />Inbound Internet Security (Forefront UAG/TMG)<br />5: Rights Management<br />
  4. Infrastructure Security<br />1<br />Layer<br />
  5. Layer 1: Infrastructure SecuritySample List of Service Accounts<br />
  6. Layer 1: Infrastructure SecurityEnable Kerberos<br />When creating any Web Applications in Classic-mode, USE KERBEROS. It is much more secure and also faster with heavy loads as the SP server doesn’t have to keep asking for auth requests from AD.<br />Kerberos auth does require extra steps, which makes people shy away from it, but once configured, it improves security considerably and can improve performance on high-load sites.<br />Should also be configured on SPCA Site! (Best Practice = Configure SPCA for NLB, SSL, and Kerberos (i.e. <br />
  7. Layer 1: Infrastructure SecurityKerberos Step 1: Create the Service Principal Names<br />Use the setspn utility to create Service Principle Names in AD, the following syntax for example:<br />Setspn.exe -A HTTP/ DOMAINNAMEMYSiteAppAccount<br />Setspn.exe -A HTTP/mysite DOMAINNAMEMYSITEAppAccount<br />Setspn.exe -A HTTP/ DOMAINNAMEHOMEAppAccount<br />Setspn.exe -A HTTP/sp DOMAINNAMEHOMEAppAccount<br />
  8. Layer 1: Infrastructure SecurityKerberos Step 2: Enable Kerberos between SP and SQL<br />Use setspn to create SPNs for SQL Service Account<br />SPNs need to match the name that SharePoint uses to connect to SQL (Ideally SQL Alias, more on this later)<br />Syntax similar to following:<br />Setspn.exe -A MSSQLSvc/spsql:1433 COMPANYABCSRV-SQL-DB<br />Setspn.exe –A MSSQLSvc/ COMPANYABCSRV-SQL-DB<br />MSSQLSvc = Default instance, if named instance, specify the name instead<br />In this example, SRV-SQL-DB is the SQL Admin account<br />
  9. Layer 1: Infrastructure SecurityKerberos Step 3: Allow Accounts to Delegate (Optional)<br />Required only for Excel Services and other impersonation applications.<br />On all SP Computer accounts and on the Application Identity accounts, check the box in ADUC to allow for delegation. <br />In ADUC, navigate to the computer or user account, right-click and choose Properties. <br /> Go to the Delegation tab <br />Choose Trust this user/computer for delegation to any service (Kerberos)<br />
  10. Layer 1: Infrastructure SecurityKerberos Step 4: Enable Kerberos on Web Application<br />Go to Application Management – Authentication Providers<br />Choose the appropriate Web Application<br />Click on the link for ‘Default’ under Zone<br />Change to Integrated Windows Authentication - Kerberos (Negotiate)<br />Run iisreset /noforce from the command prompt<br />If creating Web App from scratch, this step may be unnecessary if you choose Negotiate from the beginning<br />
  11. Data Security<br />2<br />Layer<br />
  12. Layer 2: Data SecurityRole Based Access Control (RBAC)<br />Role Groups defined within Active Directory (Universal Groups) – i.e. ‘Marketing,’ ‘Sales,’ ‘IT,’ etc.<br />Role Groups added directly into SharePoint ‘Access Groups’ such as ‘Contributors,’ ‘Authors,’ etc.<br />Simply by adding a user account into the associated Role Group, they gain access to whatever rights their role requires.<br />SharePoint Group<br />
  13. SQL Server 2008 and 2008 R2 Enterprise Edition Feature<br />Encrypts SQL Databases Transparently, SharePoint is unaware of the encryption and does not need a key<br />Encrypts the backups of the database as well<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL Transparent Data Encryption (TDE)<br />
  14. Available with either SQL 2005 or SQL 2008<br />Encrypts individual cells in a database<br />Requires a password to access the cell<br />Requires that columns be changed from their original data type to varbinary<br />Advantage is that only specific info is encrypted<br />Disadvantage is that you cannot use this for SharePoint Databases<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecurityTDE vs. Cell Level Encryption<br />
  15. Two forms, older Encrypting File System (EFS) and Bitlocker<br />EFS encrypts data at the File Level<br />Bitlocker encrypts data at the Volume Level<br />Bitlocker Encrypts every file on the disk, not just database files<br />Could be used together with TDE<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecurityTDE vs. File Level Encryption<br />
  16. Does not encrypt the Communication Channel (IPSec can be added)<br />Does not protect data in memory (DBAs could access)<br />Cannot take advantage of SQL 2008 Backup Compression<br />TempDB is encrypted for the entire instance, even if only one DB is enabled for TDE, which can have a peprformance effect for other DBs<br />Replication or FILESTREAM data is not encrypted when TDE is enabled (i.e. RBS BLOBs not encrypted)<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL Transparent Data Encryption (TDE) Limitations<br />
  17. (c) 2011 Microsoft. All rights reserved.<br />Key and Cert Hierarchy<br />DPAPI Encrypts SMK<br />SMK encrypts the DMK for master DB<br /> Service Master Key<br /> Data Protection API (DPAPI)<br /> Database Master Key<br />Certificate<br /> Database Encryption Key<br />SQL Instance Level<br />Windows OS Level<br />master DB Level<br />master DB Level<br />Content DB Level<br />DMK creates Cert in master DB<br />Certificate Encrypts DEK in Content DB<br />DEK used to encrypt Content DB<br />
  18. Symmetric key used to protect private keys and asymmetric keys<br />Protected itself by Service Master Key (SMK), which is created by SQL Server setup<br />Use syntax as follows:<br />USE master;<br />GO<br />CREATE MASTER KEY ENCRYPTION BY PASSWORD = 'CrypticTDEpw4CompanyABC';<br />GO<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE Step 1: Creating the Database Master Key (DMK)<br />
  19. Protected by the DMK<br />Used to protect the database encryption key<br />Use syntax as follows:<br />USE master;<br />GO<br />CREATE CERTIFICATE CompanyABCtdeCert WITH SUBJECT = 'CompanyABC TDE Certificate' ;<br />GO<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE Step 2: Creating the TDE Certificate<br />
  20. Without a backup, data can be lost<br />Backup creates two files, the Cert backup and the Private Key File<br />Use following syntax:<br />USE master;<br />GO<br />BACKUP CERTIFICATE CompanyABCtdeCert TO FILE = 'c:BackupCompanyABCtdeCERT.cer' <br />WITH PRIVATE KEY ( <br />FILE = 'c:BackupCompanyABCtdeDECert.pvk', <br />ENCRYPTION BY PASSWORD = 'CrypticTDEpw4CompanyABC!' );<br />GO<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE Step 3: Backup the Master Key<br />
  21. DEK is used to encrypt specific database<br />One created for each database<br />Encryption method can be chosen for each DEK<br />Use following syntax:<br />USE SharePointContentDB;<br />GO<br />CREATE DATABASE ENCRYPTION KEY <br />WITH ALGORITHM = AES_256 <br />ENCRYPTION BY SERVER CERTIFICATE CompanyABCtdeCert<br />GO<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE Step 4: Creating the Database Encryption Key (DEK)<br />
  22. Data encryption will begin after running command<br />Size of DB will determine time it will take, can be lengthy and could cause user blocking<br />Use following syntax:<br />USE SharePointContentDB<br />GO<br />ALTER DATABASE SharePointContentDB<br />SET ENCRYPTION ON<br />GO<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE Step 5: Enable TDE on the Database(s)<br />
  23. State is Returned<br />State of 2 = Encryption Begun<br />State of 3 = Encryption Complete<br />Use following syntax:<br />USE SharePointContentDB<br />GO<br />SELECT *<br />FROM sys.dm_database_encryption_keys<br />WHERE encryption_state = 3;<br />GO<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE Step 6: Monitor the TDE Encryption Progress<br />
  24. Step 1: Create new Master Key on Target Server (Does not need to match source master key)<br />Step 2: Backup Cert and Private Key from Source<br />Step 3: Restore Cert and Private Key onto Target (No need to export the DEK as it is part of the backup)<br />USE master;<br />GO<br />CREATE CERTIFICATE CompanyABCtdeCert<br />FROM FILE = 'C:RestoreCompanyABCtdeCert.cer'<br />WITH PRIVATE KEY (<br />FILE = 'C:RestoreCompanyABCtdeCert.pvk'<br />, DECRYPTION BY PASSWORD = 'CrypticTDEpw4CompanyABC!'<br />)<br />Step 4: Restore DB<br />(c) 2011 Microsoft. All rights reserved.<br />Layer 2: Data SecuritySQL TDE: Restoring a TDE Database to Another Server<br />
  25. (c) 2011 Microsoft. All rights reserved.<br />
  26. Layer 2: Data SecuritySharePoint Antivirus<br />
  27. Layer 2: Data SecuritySharePoint Antivirus VSAPI<br />Realtime scanning only uses the VSAPI<br />Realtime Scan Settings are Administered through the SharePoint Central Admin Tool<br />Realtime Options are grayed out in the ForeFront Admin Console<br />
  28. Layer 2: Data SecuritySharePoint Antivirus: FPS Keyword and File Filtering<br />Look for specific keywords (sensitive company info, profanity, etc.)<br />Block<br />Simply detect and notify<br />Create Filter List<br />Add Keywords, either manually or bulk as lines in a text file<br />
  29. Layer 2: Data SecuritySharePoint Antivirus: FPS Profanity Filters<br />New Profanity lists in 11 languages available in SP2 <br />(Run KeywordInstaller.msi to install)<br />Import the lists into FF from Program FilesMicrosoft Forefront SecuritySharePointDataExample Keywords<br />
  30. Transport Security<br />3<br />Layer<br />
  31. Layer 3: Transport SecurityClient to Server: Using Secure Sockets Layer (SSL) Encryption<br />External or Internal Certs highly recommended<br />Protects Transport of content<br />20% overhead on Web Servers<br />Can be offloaded via SSL offloaders if needed<br />Don’t forget for SPCA as well!<br />
  32. Layer 3: Transport SecurityServer to Server: Using IPSec to encrypt traffic<br />By default, traffic between SharePoint Servers (i.e. Web and SQL) is unencrypted<br />IPSec encrypts all packets sent between servers in a farm<br />For very high security scenarios when all possible data breaches must be addressed<br />
  33. Edge Security<br />4<br />Layer<br />
  34. Layer 4: Edge SecurityForefront Unified Access Gateway (UAG) 2010<br />
  35. Layer 4: Edge SecurityUAG Comparison with Forefront TMG<br />
  36. Rights Management<br />5<br />Layer<br />
  37. Layer 5: Rights ManagementActive Directory Rights Management Services (AD RMS)<br />AD RMS is a form of Digital Rights Management (DRM) technology, used in various forms to protect content<br />Used to restrict activities on files AFTER they have been accessed:<br />Cut/Paste<br />Print<br />Save As…<br />Directly integrates with SharePoint DocLibs<br />
  38. Layer 5: Rights ManagementHow AD RMS Works<br />On first use, authors receive client licensor certificate from RMS server<br />Author creates content and assigns rights<br />File is distributed to recipient(s)<br />Recipient opens file, and their RMS client contacts server for user validation and to obtain a license<br />Application opens the file and enforces the restrictions<br />
  39. Layer 5: Rights ManagementInstalling AD RMS – Key Storage<br />Select Cluster Key Storage<br />CSP used for advanced scenarios<br />
  40. Layer 5: Rights ManagementInstalling AD RMS – Creating the Cluster Name<br />
  41. Layer 5: Rights ManagementInstalling AD RMS – Using an SSL Cert for Transport Encryption<br />
  42. Layer 5: Rights ManagementAllowing SharePoint to use AD RMS<br />By default, RMS server is configured to only allow the local system account of the RMS server or the Web Application Identity accounts to access the certificate pipeline directly<br />SharePoint web servers and/or Web Application Service Accounts need to be added to this security list<br />Add the RMS Service Group, the machine account(s) of the SharePoint Server and the Web App Identity accountswith Read and Excecute permissions to the ServerCertification.asmx file in the %systemroot%inetpubwwwroot_wmcsCertification folder on the RMS server<br />
  43. Layer 5: Rights ManagementClient Accessing AD RMS Documents<br />RMS-enabled client, when accessing document in doclib, will access RMS server to validate credentials<br />
  44. Layer 5: Rights ManagementClient Accessing AD RMS Documents<br />Effective permissions can be viewed from the document<br />The RMS client will enforce the restrictions<br />
  45.<br />Submit your session evaluation for a chance to win! <br />Sponsored by MVA<br />
  46. Creating<br />the future<br />together<br />
  47. Thanks for attending!Questions?<br />Michael Noel<br />Twitter: @MichaelTNoel<br /><br />Slides:<br />