You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 28 Next »

This document describes the procedure used to install Shibboleth Service Provider (SP) software on Windows Server and Internet Information Server (IIS), and to configure it to work with the Cornell Shibboleth Identity Provider (IdP).

Prerequisites

The IIS website must have an appropriate SSL certificate installed and SSL enabled.  Shibboleth Service Provider 3.x software supports Windows Server 2008 and later, and installers are available for both 32-bit and 64-bit systems.  Shibboleth 3.x supports the versions of the IIS web server that are provided with the supported Windows versions.

If you have any URL rewrite rules defined in IIS, make sure those rules do not apply to Shibboleth.sso path. Or you can add this rule at the top of all the other rules that will stop redirecting any request for /Shibboleth.sso

Installation Steps

  1. Install the MS Visual C++ re-distributable libraries. You need to restart the server after the installation.

    These links may break at some point, but for now the 32-bit and 64-bit run times can be found at:

    The top-level link to find them is https://visualstudio.microsoft.com/downloads/ via Other Tools.

  2. Run Shibboleth SP Windows installer

    2.1  Download the latest version of the Windows installer package from the Shibboleth download site at https://shibboleth.net/downloads/service-provider/latest/. Select either the win32/ or win64/ directory as appropriate to your 32-bit or 64-bit system. Then download .msi file.

    2.2  Run the installer package. It is recommended that you accept all defaults, as follows:

    • Accept the license agreement
    • Install to C:\opt\shibboleth-sp - This is the default location. You may change it to other location.
    • Make sure Configure IIS7 module is checked
    • Click Next, then Install, then Finish
    • Click Yes to restart your system

  3. Verify installation

    On the Administrative Tools menu, click Services. Find Shibboleth Daemon in the list and double-click it.  Verify that Service Status is Running, Startup type is Automatic, and on the Log On tab, verify that Local System is selected.

  4. Edit Configuration files

    Go to your SP installation directory(C:\opt\shibboleth-sp if you use the default) . All the SP configuration files are in the \etc\shibboleth directory.

    Update attribute-map.xml

    Save a copy of attribute-map.xml to attribute-map.xml.orig or similar. Download our sample attribute-map.xml and replace your attribute-map.xml with downloaded file. Our attribute-map.xml defines all commonly used attributes. 

    All attributes except groups are released by default to all SP. Attribute "groups" is released on demand. Submit group membership requirement when you submit shibboleth integration request form. Find all the default attributes released by Cornell IDP from Shibboleth at Cornell Page. Edit attribute-map.xml as needed.

    Update Shibboleth2.xml

    4.1 Save a copy of shibboleth2.xml to shibboleth2.xml.orig or similar. Download our sample shibboleth2.xml and replace your shibboleth2.xml with downloaded shibboleth2.xml. Open shibboleth2.xml in a text editor.
    4.2 Update the site ID and name:

    Find <ISAPI...>...<Site id="1" name="shibtest.cit.cornell.edu"/>. Change the site id to match the id assigned to your site by IIS. You can find your site id in Internet Services (IIS) Manager by clicking on "Sites". In this same location, change the site name to your DNS name. Our example defined two sites. Delete or add more as needed.

    4.3 Update the host name:

    Find <RequestMap>...<Host name="shibtest.cit.cornell.edu">. Change the name to the site name you defined in step 4.2. In our example files, we defined two hosts and specifies different authorization rules for each site and location. Please modify it to meet your site requirement. Additional resources for AccessControl: https://wiki.shibboleth.net/confluence/display/SP3/XMLAccessControl

    Keep in mind Shibboleth IDP doesn't support nested groups( for example group B is a member of group A, user C is a member of group B, IDP doesn't know user C is a member of group A) . If you have to use nested group, you need to convert nested group to dynamic group.
    If your site supports both http and https, don't forget add redirectToSSL="443" in Host element because shibboleth SP doesn't work with http connection.

    4.4 Update SP entityID:

    Find <ApplicationDefaults entityID="shibtestsites.cit.cornell.edu" ...> Change the entityID to whatever you like. EntityID is the name of your SP. Each SP should have unique name. It's better not include space or special characters in it( / or : are fine).

    4.5 Update the support contact:

    Find  < Errors supportContact ="root@localhost"  helpLocation ="/about.html" styleSheet ="/shibboleth-sp/main.css"  />  and change the email address to your application's support email address.

    Skip 4.6, 4.7 if you are configuring a production site

    4.6 Find <SSO entityID="https://shibidp.cit.cornell.edu/idp/shibboleth">. If this is test/dev site, configured it with Cornell test IDP. When configure with test IDP, replace the entityID with https://shibidp-test.cit.cornell.edu/idp/shibboleth

    4.7  Find <MetadataProvider ... url="https://shibidp.cit.cornell.edu/idp/shibboleth" ..>. This is the metadata for production IDP. Comment out this block for your test site. Then un-comment MetadataProvider for Cornell test IDP.

    4.8 Save shibboleth2.xml. Whenever you make the change to shibboleth2.xml, save the file. You can wait for the Shibboleth Daemon to pick up the changes or you can restart the Shibboleth Daemon to make the changes take effect right away.

  5. Verify the Configuration

    Go to your SP installation directory(default C:\opt\shibboleth-sp), cd to /sbin64 or /sbin directory as appropriate to your 64-bit or 32-bit system. Running the code below from the command line: 

     

    test
    shibd.exe -check

    If the last line of the output is the following message, everything is as expected:

    overall configuration is loadable, check console fornon-fatal problems

    If there is error, check log for detail. All the log files are in SP installation directory\var\log\shibboleth

  6. Install X509 Certificate

    As Shibboleth requires a certificate and key to encrypt and decrypt attribute assertions, an X509 certificate must be installed for it to work. Now that the shibboleth2.xml file has been updated, use the keygen.bat command in C:\opt\shibboleth-sp\etc\shibboleth to create new certificates with the hostname(server name) and entityID. Use the following format:

     

    keygen.bat -h idmwebserver.cit.cornell.edu -e entityID -y number of years to issue

    where the values for each are substituted accordingly

    keygen.bat -h idmwebserver.cit.cornell.edu -e shibtestsites.cit.cornell.edu -y 10

    The 10 indicates the number of years for which the certificate is issued. You may specify a different value.

  7. Generate SP metadata

    7.1 Restart IIS and the Shibboleth Daemon. The Shibboleth Daemon can be restarted using the Administrative Tools > Services navigation.

    7.2 Navigate to https://yoursiteDomain/Shibboleth.sso/Metadata and download it.
    7.3 Open your downloaded file with text editor. Make sure the entityID is the same as your defined in shibboleth2.xml. If there are multiple sites in IIS require Shibboleth authentication and you define them in shibboleth2.xml, you need to manually add consumer service url for each site in your SP's metadata.       

    For example, I get my SP's metadata from https://shibtest.cit.cornell.edu/Shibboleth.sso/Metadata,  in the metadata there should be a line like this:

    <md:AssertionConsumerService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST" Location="https://shibtest.cit.cornell.edu/Shibboleth.sso/SAML2/POST" index="1"/>

    I also have shibtest1.cit.cornell.edu defined in shibboleth2.xml, I need to add AssertionConsumerService url for shibtest1.cit.cornell.edu like this

     <md:AssertionConsumerService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST" Location="https://shibtest1.cit.cornell.edu/Shibboleth.sso/SAML2/POST" index="2"/>

    Save your metadata file. You'll need to submit your SP's metadata in shibboleth integration request form.

  8. Register Service Provider with Cornell Identity Provider

    If your site is configured with test IDP, you don't have to submit Shibboleth integration request form because test IDP supports anonymous SP. You can start testing the authentication of your site.

    For sites configured with prod IDP, submit your shibboleth integration request from https://shibrequest.cit.cornell.edu. On the second page of request form, select 'No' for question "Has the application service provider's metadata been published with InCommon?".  Use text editor open your SP's metadata, copy the content of the metadata and paste it in the request form.Once the form is submitted, Identity Management get a Remedy case. We'll configure your SP in prod IDP in 1 - 2 business day. We'll notify you when the configuration is complete.

  9. Test SP integration with IdP

    Confirm that you are able to log in with your netID and that attributes are properly released.

    1. Using a web browser, visit the /secure directory (or other protected location) of your SP.
    2. If you are prompted to log in, that means that your SP is properly integrated with Cornell IdP.
    3. After you log in, open a new tab of the same browser and point your web browser to https://<your dns name>/Shibboleth.sso/Session.  Your browser should return a status page that show you all the attributes and values released to your SP.

Need Help?

contact idmgmt@cornell.edu

 

             

 

 

 

 

 

  • No labels