I had various problems with OpenSSO Express 7 and Glassfish V3 Prelude. Your luck may vary here.
If you are deploying OpenSSO on Glassfish, don’t forget to change the following JVM settings:
- -client to -server
- -Xmx512m to -Xmx1024m
- I had various problems logging in and getting redirected to the login page. Try adding -Dcom.iplanet.am.cookie.c66Encode=true to your JVM settings
Next, deploy OpenSSO. I normally deploy to /opensso, but that’s just me.
After deploying configure OpenSSO. I normally pick Custom configuration, and for the purpose of this Demo, I install both the configuration and user information into the inbuilt data store. Finish configuration and log in.
Next head to Create Hosted Identity Provider. Leave all the settings default except change the signing key to Test. Give your Circle of Trust a name. Under attribute mapping, I normally enter cn=cn. We can add other settings, and it’s better to have a SAML assertion with something in it (since SimpleSAMLphp will reject empty assertions).
Install SimpleSAMLphp as a SP. Once set up you should be able to go to:
And have your SP metadata.
In OpenSSO click Register Remote Identity Provider. Enter the URL above in the box for the metadata URL in OpenSSO. Select the circle of trust to add this to. Click configure.
Next go to:
And copy that XML. Head to:
And paste the OpenSSO IDP metadata into that box and click Parse.
Take the result and copy into:
You’ll have to change the top line from:
'http://webserver/opensso' => array (
$metadata['http://webserver/opensso'] = array (
And don’t forget to change the comma at the end of the block you just pasted into a semicolon. Save saml20-idp-remote.php.
Head back to OpenSSO. Click the Test Federation Connectivity link. Select your circle of trust. Click Start Test. You can use the username “demo” and the password “changeit”.
The test should work correctly. If it does you’ve got SAML connectivity between an OpenSSO IDP and a SimpleSAMLphp SP.
Some things could go wrong though, so we need to think about what’s happening here:
- Is the OpenSSO IDP configured correctly?
- Is the SimpleSAMLphp SP configured correctly?
- Does the OpenSSO IDP trust the SimpleSAMLphp SP?
- Does the SimpleSAMLphp SP trust the OpenSSO IDP?
The problem is one of those four things. Good luck.