Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.
Chapter 9. Securing the Service Registry
9.1. jUDDI and the JBoss Enterprise SOA Platform Link kopierenLink in die Zwischenablage kopiert!
The JBoss Enterprise SOA Platform product includes a pre-configured installation of a jUDDI registry. You can use a specific API to access this registry through your custom client. However, any custom client that you build will not covered by your SOA Platform support agreement. You can access the full set of jUDDI examples, documentation and APIs from: http://juddi.apache.org/.
9.2. Service Registry Authentication Link kopierenLink in die Zwischenablage kopiert!
Here is a theoretical understanding of how the authentication process works.
Authenticator interface.
GetAuthToken request is made. The goal of this phase is to turn a user id and credentials into a valid publisher id. The publisher id (referred to as the authorized name in UDDI terminology) is the value that assigns ownership within UDDI. Whenever a new entity is created, it must be tagged with ownership by the authorized name of the publisher.
GetAuthToken request, an authentication token is issued to the caller.
GetAuthToken request. This leads to the identify phase.
UddiEntityPublisher object. This object contains all the properties necessary to handle ownership of UDDI entities. Thus, the token (or publisher id) is used to identify the publisher.
Publisher entity, which is a sub-class of UddiEntityPublisher. This sub-class makes publisher properties persist within the jUDDI Registry.
9.3. authToken Link kopierenLink in die Zwischenablage kopiert!
9.4. authToken and the Service Registry Link kopierenLink in die Zwischenablage kopiert!
authToken.
Important
9.5. Obtain an authToken Link kopierenLink in die Zwischenablage kopiert!
Procedure 9.1. Task
- Make a
GetAuthToken()request. - A
GetAuthTokenobject is returned. Set a userid and credential (password) on this object:Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Locate the
juddi.propertiesconfiguration file inSOA_ROOT/jboss-as/server/PROFILE/deploy/juddi-service.sar/juddi.war/WEB-INF. Open it in a text editor. - Configure the juddi.authenticator property to how the Service Registry will check the credentials passed to it by the
GetAuthTokenrequest. (By default it uses thejUDDIAuthenticatorimplementation.) - Save the file and exit.
9.6. Security Authentication Implementations Available for the Service Registry Link kopierenLink in die Zwischenablage kopiert!
- jUDDI Authentication
Warning
Do not use this authentication method in a production environment. It accepts any credentials provided, and effectively removes the need for clients to authenticate when accessing the registry.The default authentication mechanism provided by the Service Registry is thejUDDIAuthenticator.jUDDIAuthenticator's authenticate phase checks to see if the, user ID submitted matches against a record in thePublishertable. No credentials checks are made. If, during the authentication process, the Publisher record is found to be non-existent, it is added "on-the-fly".In the identify phase, the publisher ID is used to retrieve the Publisher record and return it. The Publisher inherits every property it needs fromUddiEntityPublisher:juddi.authenticator = org.apache.juddi.auth.JUDDIAuthentication
juddi.authenticator = org.apache.juddi.auth.JUDDIAuthenticationCopy to Clipboard Copied! Toggle word wrap Toggle overflow - XMLDocAuthentication
- The authenticate phase checks that the user id and password match a value in the XML file. The identify phase uses the user ID to populate a new
UddiEntityPublisher. - CryptedXMLDocAuthentication
- The
CryptedXMLDocAuthenticationimplementation is similar to theXMLDocAuthenticationimplementation, but the passwords are encrypted:juddi.authenticator = org.apache.juddi.auth.CryptedXMLDocAuthentication juddi.usersfile = juddi-users-encrypted.xml juddi.cryptor = org.apache.juddi.cryptor.DefaultCryptor
juddi.authenticator = org.apache.juddi.auth.CryptedXMLDocAuthentication juddi.usersfile = juddi-users-encrypted.xml juddi.cryptor = org.apache.juddi.cryptor.DefaultCryptorCopy to Clipboard Copied! Toggle word wrap Toggle overflow Here, the user credential file isjuddi-users-encrypted.xml, and the content of the file will be similar to this:Copy to Clipboard Copied! Toggle word wrap Toggle overflow TheDefaultCryptorimplementation usesBEWithMD5AndDESandBase64to encrypt the passwords.Note
You can use the code in theAuthenticatorTestto learn more about how to use this Authenticator implementation. You can plug in your own encryption algorithm by implementing theorg.apache.juddi.cryptor.Cryptorinterface and referencing your implementation class in the juddi.cryptor property.The authenticate phase checks that the user ID and password match values in the XML file. The identify phase uses the user ID to populate a newUddiEntityPublisher. - LDAP Authentication
- Use
LdapSimpleAuthenticatorto authenticate users via LDAP's simple authentication functionality. This class allows you to authenticate a user based on an LDAP principle, provided that the principle and the jUDDI publisher ID are identical. - JBoss Authentication
- A final alternative is to interface with third-party credential stores. You can link it to the JBoss Application Server's authentication component.You will find the
JBossAuthenticatorclass provided in thedocs/examples/authdirectory. This class enables jUDDI deployments on JBoss to use a server security domain to authenticate users.
9.7. Configure XMLDocAuthentication Link kopierenLink in die Zwischenablage kopiert!
Procedure 9.2. Task
- Create a text file called
juddi-users.xmland save it injbossesb-registry.sar.Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Save the file and exit.
- Add the file to the class-path.
- Open the
juddi.propertiesfile in your text editor (located inSOA_ROOT/jboss-as/server/PROFILE/deploy/juddi-service.sar/juddi.war/WEB-INF). - Modify the file so that it looks like this:
juddi.authenticator = org.apache.juddi.auth.XMLDocAuthentication juddi.usersfile = juddi-users.xml
juddi.authenticator = org.apache.juddi.auth.XMLDocAuthentication juddi.usersfile = juddi-users.xmlCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Save the file and exit.
9.8. Lightweight Directory Access Protocol (LDAP) Link kopierenLink in die Zwischenablage kopiert!
9.9. Configure LDAP Authentication Link kopierenLink in die Zwischenablage kopiert!
Procedure 9.3. Task
- Locate the
juddi.propertiesfile inSOA_ROOT/jboss-as/server/PROFILE/deploy/juddi-service.sar/juddi.war/WEB-INF. Open it in your text editor. - Add the following configuration settings:
juddi.authenticator=org.apache.juddi.auth.LdapSimpleAuthenticator juddi.authenticator.url=ldap://localhost:389
juddi.authenticator=org.apache.juddi.auth.LdapSimpleAuthenticator juddi.authenticator.url=ldap://localhost:389Copy to Clipboard Copied! Toggle word wrap Toggle overflow The juddi.authenticator.url property tells theLdapSimpleAuthenticatorclass where the LDAP server resides. - Save the file and exit.
9.10. Configure JBoss Authentication Link kopierenLink in die Zwischenablage kopiert!
Procedure 9.4. Task
- Locate the
juddi.propertiesfile inSOA_ROOT/jboss-as/server/PROFILE/deploy/juddi-service.sar/juddi.war/WEB-INF. Open it in your text editor. - Add the following lines to the file:
uddi.auth=org.apache.juddi.auth.JBossAuthenticator juddi.securityDomain=java:/jaas/other
uddi.auth=org.apache.juddi.auth.JBossAuthenticator juddi.securityDomain=java:/jaas/otherCopy to Clipboard Copied! Toggle word wrap Toggle overflow The juddi.authenticator property connects theJbossAuthenticatorclass to the jUDDI Registry's Authenticator framework. Thejuddi.security.domaintellsJBossAuthenticatorwhere it can find the Application Server's security domain. It uses this domain to perform the authentications.Note that JBoss creates one security domain for each application policy element in theSOA_ROOT/jboss-as/server/PROFILE/conf/login-config.xmlfile. These domains are bound to the server JNDI tree with this name:java:/jaas/<application-policy-name>. (If a look-up refers to a non-existent application policy, a policy namedotherwill be used by default.) - Save the file and exit.