2.4.6. Generating and using your own keystore

Warning

You are looking at documentation for an older release. Not what you want? See the current release documentation.

The default jbid_test_keystore.jks is useful for testing purpose, but in production you need to generate and use your own keystore as follows:

  1. Generate your file using the keytool command:

    keytool -genkey -alias secure-key -keyalg RSA -keystore secure-keystore.jks

    You will be asked to enter a keystore password and a key password. Remember them to use in next steps.

  2. Install your file to PLATFORM_*/standalone/configuration/gatein/saml2/ (for Jboss) or PLATFORM_*/gatein/conf/saml2/ (for Tomcat) if you are configuring eXo Platform SP/IDP. Install it to WEB-INF/classes/ inside PLATFORM_*/standalone/deployments/idp-sig.war if you are configuring idp-sig.war.

  3. Modify picketlink configuration file to provide your keystore password and a key password. The picketlink configuration file is:

    • PLATFORM_SP/standalone/configuration/gatein/saml2/picketlink-sp.xml (for Jboss) and PLATFORM_SP/gatein/conf/saml2/picketlink-sp.xml (for Tomcat) if you are configuring eXo Platform SP.

    • PLATFORM_IDP/standalone/configuration/gatein/saml2/picketlink-idp.xml (for Jboss) and PLATFORM_IDP/gatein/conf/saml2/picketlink-sp.xml (for Tomcat) if you are configuring eXo Platform IDP.

    • WEB-INF/picketlink.xml inside PLATFORM_*/standalone/deployments/idp-sig.war if you are configuring idp-sig.war.

    The following configuration is for SP, similar for IDP and idp-sig.war:

    
    <KeyProvider ClassName="org.picketlink.identity.federation.core.impl.KeyStoreKeyManager">
      <Auth Key="KeyStoreURL" Value="${gatein.sso.picketlink.keystore}"/>
      <Auth Key="KeyStorePass" Value="keystore pass"/>
      <Auth Key="SigningKeyPass" Value="key pass"/>
      <Auth Key="SigningKeyAlias" Value="secure-key"/>
      <ValidatingAlias Key="${gatein.sso.sp.host}" Value="secure-key"/>
    </KeyProvider>

    Note

    On Windows, you should use the absolute link to the keystore file, instead of using ${gatein.sso.picketlink.keystore}.

Copyright ©. All rights reserved. eXo Platform SAS
blog comments powered byDisqus