Sun Java System Identity Manager 2005Q4M3 Administration |
7
Security
This chapter provides information about Identity Manager security features, and details steps you can take to further reduce security risks.
Security FeaturesIdentity Manager features help reduce security risks by providing:
- Instant disabling of account access – Identity Manager lets you disable organizations or individual access rights with a single action.
- Active risk analysis – Identity Manager scans constantly for security risks such as inactive accounts and suspicious password activity.
- Comprehensive password management – Complete and flexible password management capabilities ensure complete access control.
- Auditing and reporting to monitor access activities – You can run a full range of reports to deliver targeted information on access activities. (See Reporting for more information about reporting features.)
- Server key encryption – Identity Manager allows you to create and manage server encryption keys through the Tasks area.
In addition, system architecture seeks to reduce security risks wherever possible. For example, once logged out, you cannot access previously visited pages through your browser’s “Back” feature.
Password ManagementIdentity Manager offers password management at multiple levels:
Pass-through AuthenticationUse pass-through authentication to grant user and administrator access through one or more different passwords. Identity Manager manages authentication through the implementation of:
About Login Applications
Login applications define a collection of login module groups, which further define the set and order of login modules that will be used when a user logs in to Identity Manager. Each login application comprises one or more login module groups.
At login, the login application checks its set of login module groups. If only one login module group is set, then it is used, and its contained login modules are processed in the group-defined order. If the login application has more than one defined login module group, then Identity Manager checks the login constraint rules applied to each login module group to determine which group to process.
Login Constraint Rules
Login constraint rules are applied to the login module groups defined in a login application. For each set of login module groups in a login application, only one cannot have a login constraint rule applied to it.
When determining which login module group of a set to process, Identity Manager evaluates the first login module group's constraint rule. If it succeeds, then it processes that login module group. If it fails, then it evaluates each login module group in turn, until a constraint rule succeeds or a login module group with no constraint rule is evaluated (and subsequently used).
Note If a login application will contain more than one login module group, then the login module group with no login constraint rules should be placed in the last position of the set.
Example Login Constraint Rule
In the following example of a location-based login constraint rule, the rule gets the IP address of the requester from the header, and then checks to see if it is located on the 192.168 network. If 192.168. is found in the IP address, then the rule will return a value of true, and this login module group is selected.
<Rule authType='LoginConstraintRule' name='Sample On Local Network'>
<match>
<ref>remoteAddr</ref>
<s>192.168.</s>
</match>
<MemberObjectGroups>
<ObjectRef type='ObjectGroup' name='All'/>
</MemberObjectGroups>
</Rule>Editing Login Applications
From the menu bar, select Configure, and then select Login to access the Login page.
The login application list shows:
From the Login page you can:
To edit a login application, select it from the list.
Setting Identity Manager Session Limits
From the Modify Login Application page, you can set a timeout value (limits) for each Identity Manager login session. Select hours, minutes, and seconds, and then click Save. The limits you establish display in the login application list.
Disabling Access to Applications
From the Create Login Application and Modify Login Application pages, you can select the Disable option to disable a login application, thereby preventing users from logging in. If a user tries to log in to a disabled application, then the interface redirects him to an alternate page, indicating that the application is currently disabled. You can edit the message that displays on this page by editing the custom catalog.
Login applications remain disabled until you de-select the option. As a safeguard, you cannot disable administrator login.
Editing Login Module Groups
The login module group list shows:
From the Login Module Groups page you can create, edit, and delete login module groups. Select one of the login module groups from the list to edit it.
Editing Login Modules
Enter details or make selections for login modules as follows. (Not all options are available for each login module.)
- Login success requirement — Select a requirement that applies to this module. Selections are:
- Required — The login module is required to succeed. Irrespective of whether it succeeds or fails, authentication proceeds to the next login module in the list. If it is the only login module, the administrator is successfully logged in.
- Requisite — The login module is required to succeed. If it succeeds, authentication proceeds to the next login module in the list. If it fails, authentication does not proceed.
- Sufficient — The login module is not required to succeed. If it does succeed, authentication does not proceed to the next login module, and the administrator is successfully logged in. If it fails, authentication continues to the next login module in the list.
- Optional — The login module is not required to succeed. Irrespective of whether it succeeds or fails, authentication continues to the next login module in the list.
- Login search attributes — (LDAP only) Specify an ordered list of LDAP user attribute names to be used when attempting to bind (log in) to the associated LDAP server. Each of the LDAP user attributes specified, along with the user's specified login name, is used (in order) to search for a matching LDAP user. This allows a user to log in to Identity Manager, when configured for pass-through to LDAP, via an LDAP cn or email address.
For example, if you specify:
cn
and the user attempts to log in as gwilson, then the LDAP resource will first attempt to find an LDAP user where cn=gwilson. If that succeeds, then the bind is attempted with the password specified by the user. If it does not succeed, then the LDAP resource will search for an LDAP user where mail=gwilson. If that also fails, then login fails.
If you do not specify a value, then the default LDAP search attributes are:
uid
cn- Login correlation rule — Select a login correlation rule to be used for the mapping of login info to the Identity Manager user. The rule you select must have the LoginCorrelationRule authType.
- New user name rule — Select a new user name rule to be used when automatically creating new Identity Manager users as part of login.
Click Save to save a login module. Once it is saved, you can place the module relative to all other modules in the login module group.
WARNING It is recommended that, if Identity Manager login is configured to authenticate to more than one system, an account's user ID and password should be the same across all systems that are targets of Identity Manager authentication.
If the user ID and password combinations differ, login will fail on each system whose user ID and password do not match the user ID and password entered on the Identity Manager User Login form. Some of these systems may have a lockout policy enforcing the number of failed login attempts before an account is locked; for these systems, user accounts will eventually be locked, even though the user's login via Identity Manager continues to succeed.
Configuring Authentication for Common ResourcesIf you have more than one resource that is physically or logically the same (for example, two resources defined for the same physical host, or several resources that represent trusted domain servers in an NT or AD domain environment), then you can specify that set of resources in the system configuration object as common resources.
By establishing resources as common, you allow a user to authenticate to one of the common resources, but be mapped to his associated Identity Manager user by using another of the common resources. For example, a user may have a resource account linked to his Identity Manager user for resource AD-1. The login module group may define that users must authenticate to resource AD-2. If AD-1 and AD-2 are defined as common resources (in this case, in the same trusted domain), then if the user successfully authenticates to AD-2, Identity Manager can map to the associated Identity Manager user by finding a user with the same accountId on resource AD-1.
The format for specifying this system configuration object attribute is:
<Attribute name=’common resources’>
<Attribute name=’Common Resource Group Name’>
<List>
<String>Common Resource Name</String>
<String>Common Resource Name</String>
</List
</Attribute>
</Attribute>
Configuring X509 Certificate AuthenticationUse the following information and procedures to configure X509 Certificate Authentication for Identity Manager.
Prerequisites
To support X509 certificate-based authentication in Identity Manager, ensure that two-way (client and server) SSL authentication is configured properly. From the client perspective, this means that an X509-compliant user certificate should have been imported into the browser (or be available through a smart card reader), and that the trusted certificate used to sign the user certificate should be imported into the Web application server’s keystore of trusted certificates.
Also, the client certificate used must be selected for client authentication. To verify this:
Configuring X509 Certificate Authentication in Identity Manager
To configure Identity Manager for X509 certificate authentication:
- Log in to the Administrator Interface as Configurator (or with equivalent permissions).
- Select Configure, and then select Login to display the Login page.
- Click Manage Login Module Groups to displays the Login Module Groups page.
- Select a login module group from the list.
- Select Identity Manager X509 Certificate Login Module from the Assign Login Module... list. Identity Manager displays the Modify Login Module page.
- Set the login success requirement. Acceptable values are:
- Required — The login module is required to succeed. Irrespective of whether it succeeds or fails, authentication proceeds to the next login module in the list. If it is the only login module, the administrator is successfully logged in.
- Requisite — The login module is required to succeed. If it succeeds, authentication proceeds to the next login module in the list. If it fails, authentication does not proceed.
- Sufficient — The login module is not required to succeed. If it does succeed, authentication does not proceed to the next login module, and the administrator is successfully logged in. If it fails, authentication continues to the next login module in the list.
- Optional — The login module is not required to succeed. Irrespective of whether it succeeds or fails, authentication continues to the next login module in the list.
- Select a login correlation rule. This could be a built-in rule or a custom correlation rule. (See the following section for information about creating custom correlation rules.)
- Click Save to return to the Modify Login Module Group page.
- Optionally, reorder the login modules (if more than one login module is assigned to the login module group, and then click Save.
- Assign the login module group to a login application if it is not yet assigned. From the Login Module Groups page, click Return to Login Applications, and then select a login application. After assigning a login module group to the application, click Save.
Note If the allowLoginWithNoPreexistingUser option is set to a value of true in the waveset.properties file, then when configuring the Identity Manager X509 Certificate Login Module, you are prompted to select a New User Name Rule. This rule is used to determine how to name new users created when one is not found by the associated Login Correlation Rule.
The New User Name Rule has the same available input arguments as the Login Correlation Rule. It returns a single string, which is the user name used to create the new Identity Manager user account.
A sample new user name rule is included in idm/sample/rules, named NewUserNameRules.xml.
Creating and Importing a Login Configuration Rule
A Login Correlation Rule is used by the Identity Manager X509 Certificate Login Module to determine how to map the certificate data to the appropriate Identity Manager user. Identity Manager includes one built-in correlation rule, named Correlate via X509 Certificate subjectDN.
You can also add your own correlation rules. Each correlation rule must follow these guidelines:
- Its authType attribute must be set to LoginCorrelationRule. (Set authType=’LoginCorrelationRule’ in the <LoginCorrelationRule> element.)
- It is expected to return an instance of a list of AttributeConditions to be used by the login module to find the associated Identity Manager user. For example, the login correlation rule might return an AttributeCondition that searches for the associated Identity Manager user by email address.
Arguments passed to login configuration rules are:
The naming convention for certificate arguments passed to the login correlation rule is:
cert.field name.subfield name
Example argument names that are available to the rule include:
The login configuration rule, using the passed-in arguments, returns a list of one or more AttributeConditions. These are used by the Identity Manager X509 Certificate Login Module to find the associated Identity Manager user.
A sample login correlation rule is included in idm/sample/rules, named LoginCorrelationRules.xml.
After creating a custom correlation rule, you must import it into Identity Manager. From the Administrator Interface, select Configure, and then select Import Exchange File to use the file import facility.
Testing the SSL Connection
To test the SSL connection, go to the configured application interface’s URL via SSL (for example, https//idm007:7002/idm/user/login.jsp). You are notified that you are entering a secure site, and then prompted to specify which personal certificate to send to the Web server.
Diagnosing Problems
Problems authenticating via X509 certificates should be reported as error messages on the login form. For more complete diagnostics, enable trace on the Identity Manager server for these classes and levels:
If the client certificate attribute is named something other than javaxservlet.request.X509Certificate in the http request, then you will receive a message that this attribute cannot be found in the http request. To correct this:
- Enable trace for SessionFactory to see the complete list of http attributes and determine the name of the X509Certificate.
- Use the Identity Manager debug facility to edit the LoginConfig object.
- Change the name of the <AuthnProperty> in the <LoginConfigEntry> for the Identity Manager X509 Certificate Login Module to the correct name.
- Save, and then retry.
You may also need to remove, and then re-add the Identity Manager X509 Certificate Login Module in the login application.
Cryptographic Use and ManagementCryptography is used to ensure the confidentiality and integrity of server data in memory and in the repository, as well as all data transmitted between the server and gateway.
The following sections provide more information about how cryptography is used and managed in the Identity Manager Server and Gateway, and addresses questions about server and gateway encryption keys.
Cryptographically Protected Data
The following table shows the types of data that are cryptographically protected in the Identity Manager product, including the ciphers used to protect each type of data.
Data Type
RSA
MD5NIST
Triple DES
168-bit key
(DESede/ECB/NoPadding)PKCS#5
Password-Based Crypto
56-bit key
(PBEwithMD5andDES)Server encryption keys
default
configuration option1
Gateway encryption keys
default
configuration option1
Policy dictionary words
yes
User passwords
yes
User password history
yes
User answers
yes
Resource passwords
yes
Resource password history
yes
All payload between server and gateways
yes
Server Encryption Key Questions and Answers
Read the following sections for answers to frequently asked questions about server encryption key source, location, maintenance, and use.
Where do server encryption keys come from?
Server encryption keys are symmetric, triple-DES 168-bit keys. There are two types of keys supported by the server:
Where are server encryption keys maintained?
Server encryption keys are objects maintained in the repository. There can be many data encryption keys in any given repository.
How does the server know which key to use for decryption and re-encryption of encrypted data?
Each piece of encrypted data stored in the repository is prefixed by the ID of the server encryption key that was used to encrypt it. When an object containing encrypted data is read into memory, Identity Manager uses the server encryption key associated with the ID prefix on the encrypted data to decrypt, and then re-encrypt with the same key if the data changed.
How do I update server encryption keys?
Identity Manager provides a task called Manage Server Encryption. This task allows an authorized security administrator to perform several key management tasks, including:
See Managing Server Encryption in this chapter for more information about how to use this task.
What happens to existing encrypted data if the "current" server key is changed?
Nothing. Existing encrypted data will still be decrypted or re-encrypted with the key referenced by the ID prefix on the encrypted data. If a new server encryption key is generated and set to be the "current" key, any new data to be encrypted will use the new server key.
Note It is very important that any server encryption key referenced by some object's encrypted data not be removed from the repository; otherwise, the server will not be able to decrypt it. If an object containing encrypted data is imported from another repository, then the associated server encryption key must first be imported to ensure the object can be successfully imported.
To avoid these multi-key issues, as well as to maintain a higher level of data integrity, use the Manage Server Encryption task to re-encrypt all existing encrypted data with the "current" server encryption key.
How are server keys protected?
If the server is not configured to use password-based encryption (PBE) - PKCS#5 encryption (set in the System Configuration object via the pbeEncrypt attribute or the Manage Server Encryption task), then the default key is used to encrypt the server keys. The default key is the same for all Identity Manager installations.
If the server is configured to use PBE encryption, then a PBE key is generated each time the server is started. The PBE key is generated by providing a password, generated from a server-specific secret, to the PBEwithMD5andDES cipher. The PBE key is maintained only in memory and never persisted. In addition, the PBE key is the same for all servers sharing a common repository.
To enable PBE encryption of server keys, the cipher PBEwithMD5andDES must be available. Identity Manager does not package this cipher by default, but it is a PKCS#5 standard that is available in many JCE providers implementations, such as those provided by Sun and IBM.
Can I export the server keys for safe external storage?
Yes. If the server keys are PBE encrypted, then before they are exported, they will be decrypted and re-encrypted with the default key. This allows them to be imported to the same or another server at a later date, independent of the local server PBE key. If the server keys are encrypted with the default key, then no pre-processing is done before they are exported.
When they are imported into a server, if the server is configured for PBE keys, the keys will be decrypted and then re-encrypted with the local server's PBE key, if that server is configured for PBE key encryption.
What data is encrypted between the server and gateway?
All data (payload) transmitted between the server and gateway is triple-DES encrypted with a randomly generated, per server-gateway session symmetric 168 bit key.
Gateway Key Questions and Answers
Read the following sections for answers to frequently asked questions about gateway source, storage, distribution, and protection.
Where do the gateway keys come from to encrypt or decrypt data?
Each time an Identity Manager Server connects to a gateway, the initial handshake will generate a new random 168-bit, triple-DES session key. This key will be used to encrypt or decrypt all subsequent data transmitted between that server and that gateway. There is a unique session key generated for each server/gateway pair.
How are gateway keys distributed to the gateways?
Session keys are randomly generated by the server and then securely exchanged between server and gateway by encrypting them with the shared secret master key as part of the initial server-to-gateway handshake.
At initial handshake time, the server queries the gateway to determine which mode it supports. The gateway can operate in two modes
- Default mode — Initial server-to-gateway protocol handshake is encrypted with the default 168 bit triple-DES key, which is compiled into the server code.
- Secure mode — A per shared repository, random, 168-bit key, triple-DES gateway key is generated and communicated from the server to the gateway as part of the initial handshake protocol. This gateway key is stored in the server repository like other encryption keys, and also stored by the gateway in its local registry.
When in secure mode and a server contacts a gateway, the server will encrypt test data with the gateway key and send it to the gateway. The gateway will then attempt to decrypt the test data, add some gateway unique data to the test data, re-encrypt both, and send the data back to the server. If the server can successfully decrypt the test data and the gateway unique data, the server will then generate the server-gateway unique session key, encrypt it with the gateway key and send it to the gateway. Upon receipt, the gateway will decrypt the session key and retain it for use for the life of the server-to-gateway session. If the server cannot successfully decrypt the test data and gateway unique data, the server will encrypt the gateway key using the default key and send it to the gateway. The gateway will decrypt the gateway key using its compiled in default key and store the gateway key in its registry. The server will then encrypt the server-gateway unique session key with the gateway key and send it to the gateway for use for the life of the server-to-gateway session.
From that point forward, the gateway will only accept requests from servers that have encrypted the session key with its gateway key. On startup, the gateway checks the registry for a key. If there is one, it will use it. If there is not one, it will use the default key. Once the gateway has a key set in the registry, it will no longer allow sessions to be established using the default key. This will prevent someone from setting up a rogue server and establishing a connection to a gateway.
Can I update the gateway keys used to encrypt or decrypt the server-to-gateway payload?
Identity Manager provides a task called Manage Server Encryption that allows an authorized security administrator to do several key management tasks, including generate a new "current" gateway key and update all gateways with the "current" gateway key. This is the key that is used to encrypt the per-session key used to protect all payload transmitted between server and gateway. The newly generated gateway key will be encrypted with either the default key or PBE key, depending on the value of the pbeEncrypt attribute in the System Configuration.
Where are the gateway keys stored on the server, on the gateway?
On the server, the gateway key is stored in the repository just like server keys. On the gateway, the gateway key is stored in a local registry key.
How are gateway keys protected?
The gateway key is protected the same way server keys are. If the server is configured to use PBE encryption, the gateway key will be encrypted with a PBE generated key. If the option is false, it will be encrypted with the default key. See the previous section titled How are server keys protected? for more information.
Can I export the gateway key for safe external storage?
The gateway key can be exported via the Manage Server Encryption task, just as with server keys. See the previous section titled Can I export the server keys for safe external storage? for more information.
How are server and gateway keys destroyed?
Server and gateway keys are destroyed by deleting them from the server repository. Note that a key should not be deleted as long as any server data is still encrypted with that key or any gateway is still relying on that key. Use the Manage Server Encryption task to re-encrypt all server data with the current server key and to synchronize the current gateway key to all gateways to ensure no old keys are still being used before they are deleted.
Managing Server EncryptionThe Identity Manager server encryption feature allows you to create new 3DES server encryption keys, and then encrypt these keys by using 3DES or PKCS#5 encryption. Only users with Security Administrator capabilities can run the Manage Server Encryption task, which is accessed from the Tasks tab.
Figure 1. Manage Server Encryption Task
Select Run Tasks, and then select Manage Server Encryption from the list to configure this information for the task:
- Update encryption of server encryption keys — Select to specify whether server encryption keys will be encrypted by using default (3DES) encryption or PKCS#5 encryption. When you select this option, two encryption choices appear (Default and PKCS#5); select one.
- Generate new server encryption key and set as current server encryption key — Select to generate a new server encryption key. Each piece of encrypted data generated after you make this selection is encrypted with this key. Generating a new server encryption key does not affect the key applied to existing encrypted data.
- Select object types to re-encrypt with current server encryption key — Select one or more Identity Manager object types (such as resources or users) to re-encrypt with the current encryption key.
- Manage Gateway Keys — When selected, the page displays these gateway key options:
- Generate a new key and synchronize all gateways
Select this option when initially enabling a secure gateway environment. This option generates a new gateway key and communicates it to all gateways.- Synchronize all gateways with current gateway key
Select to synchronize any new gateways, or gateways that have not communicated the new gateway key. Select this option if you had a gateway that was down when all gateways were synchronized with the current gateway key, or when you want to force a key update for a new gateway.- Export server encryption keys for backup — Select to export existing server encryption keys to an XML-formatted file. When you select this option, Identity Manager displays an additional field for you to specify a path and file name to export the keys.
Note If you are using PKCS#5 encryption and you choose to generate and set a new server encryption key, you should also select this option. In addition, you should store the exported keys on removable media and in a secure location (not on a network).
- Execution Mode — Select whether to run this task in the background (the default option) or in the foreground. If you choose to re-encrypt one or more object types with a newly generated key, this task can take some time and is best run in the background.
Security PracticesAs an Identity Manager administrator, you can further reduce security risks to your protected accounts and data by following these recommendations, at setup time and after.
At Setup
You should:
- Access Identity Manager through a secure Web server using https.
- Reset the passwords for the default Identity Manager administrator accounts (Administrator and Configurator). To further protect the security of these accounts, you can rename them.
- Limit access to the Configurator account.
- Limit administrators’ capability sets to only those actions needed for their job functions, and limit administrator capabilities by setting up organizational hierarchies.
- Change the default password for the Identity Manager Index Repository.
- Turn on auditing to track activities in the Identity Manager application.
- Edit the permissions on files in the Identity Manager directory.
- Customize workflows to insert approvals or other checkpoints.
- Develop a recovery procedure to describe how to recover your Identity Manager environment in the event of emergency.
During Use
You should:
- Periodically change the passwords for the default Identity Manager administrator accounts (Administrator and Configurator).
- Log out of Identity Manager when not actively using the system.
- Set or know the default timeout period for an Identity Manager session.
If your application server is Servlet 2.2-compliant, the Identity Manager installation process sets the http session timeout to a default value of 30 minutes. You can change this value by editing the property; however, you should set the value lower to increase security. Do not set the value higher than 30 minutes.
To change the session timeout value:
- Change the number value in the following lines:
<session-config>
<session-timeout>30</session-timeout>
</session-config>