安装环境:Ubuntu 14.04
在看本教程前建议先熟悉Shibboleth的官方Wiki,官方Wiki见参考链接。
- 安装Apache服务器
sudo apt-get install apache2
- 配置Apache服务器
- 配置https连接(非必需,可以跳过)
- 加载ssl模块
- 创建证书
- 配置Apache到Tomcat的Ajp连接
- 配置https连接(非必需,可以跳过)
- 安装Shibboleth SP
sudo apt-get install libapache2-mod-shib2
a2enmod shib2 #启用Apache对应的模块
SP的配置目录 /etc/shibboleth
SP的日志目录 /var/log/shibboleth
4. 配置Shibboleth SP
1. 创建证书(sp和idp沟通用)shib-keygen -f -e your-entity-id -h hostname
2. 配置shibboleth2.xml,主要是如下三句话
- <ApplicationDefaults entityID="https://exm.sp.com/shibboleth" REMOTE_USER="eppn">
主要修改entityID为你的entityID,exm.sp.com - <SSO entityID="https://idp.testshib.org/idp/shibboleth">SAML2 SAML1</SSO>
修改为对应的IDP地址 - <MetadataProvider type="XML" uri="http://www.testshib.org/metadata/testshib-providers.xml" backingFilePath="testshib-two-idp-metadata.xml" reloadInterval="180000"/>
同样修改为IDP的对应地址
修改完配置后/etc/init.d/shibd restart
,重启服务。
- 使用TESTSHIB测试安装(可选)
TESTSHIB地址
参考链接: