使用ACS的ADF的CAS SSO

时间:2018-09-19 21:37:13

标签: tomcat7 single-sign-on alfresco cas

我正在使用ADF 2.4.0,ACS 2.4.0,Apereo CAS 5.2.4和Tomcat 7

我的ADF使用ACS并在Tomcat7服务器上运行,我想将CAS用作我的SSO。

我正在使用login component文档中的SSO登录-隐式流程,配置了我的app.config.json,构建了我的应用程序,并将/ dist文件夹放入了Tomcat。我可以访问https://localhost/dist,然后选择登录按钮,登录sso屏幕出现,然后将我重定向到CAS登录页面,输入我的凭据,出现consent,并且在允许时,它会将我重定向到adf屏幕,并且当我尝试访问文档库时,它将再次将我重定向到登录sso屏幕。

我的app.config.json文件

{
    "$schema": "../node_modules/@alfresco/adf-core/app.config.schema.json",
    "ecmHost": "http://{hostname}{:port}",
    "bpmHost": "http://{hostname}{:port}",
    "providers" : "ECM",
    "authType" :"OAUTH",
    "oauth2": {
      "host": "https://localhost/cas/oidc",
      "clientId": "clientid",
      "scope": "openid profile",
      "secret": "clientSecret",
      "implicitFlow": true,
      "silentLogin": false,
      "redirectUri": "/dist",
      "redirectUriLogout": "/logout"
    },
    "application": {
        "name": "Alfresco ADF Appplication"
    }
}

我的hubnet_client-00015.json(CAS服务)

{
  "@class" : "org.apereo.cas.services.OidcRegisteredService",
  "clientId": "clientid",
  "clientSecret": "clientSecret",
  "serviceId" : "^https://localhost/dist",
  "name" : "hubnet_client",
  "id" : "00015",
  "attributeReleasePolicy": {
      "@class": "org.apereo.cas.services.ReturnAllAttributeReleasePolicy"
  },
  "scopes": [ "java.util.HashSet", [ "profile"]],
  "supportedResponseTypes": [ "java.util.HashSet", ["id_token token"]],
  "supportedGrantTypes": [ "java.util.HashSet", ["client_credentials"]]
}

0 个答案:

没有答案