使用SMAL与Gitlab集成时遇到的AWS SSO问题

0

【以下的问题经过翻译处理】 你好, 我在使用AWS SSO,并将其身份来源设置为AWS SSO(而不是AD或外部来源)时遇到了问题。 我遇到了集成问题,gitlab端的配置已经正确设置(并使用Gitlab上相同配置,设置IDP Okta就工作正常)。 我的想法是将AWS SSO用作IdP,Gitlab用作SP。

Gitlab配置如下:

gitlab_rails['omniauth_enabled'] = true
gitlab_rails['omniauth_auto_link_user'] = ['saml']
gitlab_rails['omniauth_external_providers'] = ['saml']
gitlab_rails['omniauth_sync_profile_from_provider'] = ['saml']
gitlab_rails['omniauth_allow_single_sign_on'] = ['saml']
gitlab_rails['omniauth_block_auto_created_users'] = false
gitlab_rails['omniauth_auto_link_saml_user'] = false
gitlab_rails['omniauth_providers'] = [
  {
    name: "saml",
    label: "Saml Provider",
    args: {
      assertion_consumer_service_url: "http://gitlab.domain/users/auth/saml/callback",
      idp_sso_target_url: "https://portal.sso.eu-west-1.amazonaws.com/saml/assertion/{assertion_id}",
      issuer: "https://portal.sso.eu-west-1.amazonaws.com/saml/assertion/{assertion_id}",
      name_identifier_format: "urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress",
      idp_cert_fingerprint: "{fingerprint_cert}"
    }
  }
]

在AWS SSO中的配置如下: AWS SSO mappings[图片链接]

设置的用户是和我一个管理员组的。

但我收到以下错误: AWS SSO Error[图片链接]

我只看到了这个SAML请求,但是我找不到SAML响应。当我用这个Cookie返回gitlab时,我又收到了这样的消息: Could not authenticate you from SAML because "Saml response missing".

Gitlab需要的断言是:

Field	Supported keys
Email (required)	email, mail
Full Name	name
First Name	first_name, firstname, firstName
Last Name	last_name, lastname, lastName

祝好

profile picture
专家
已提问 5 个月前26 查看次数
1 回答
0

【以下的回答经过翻译处理】 大家好,还是我(自问自答了属于)

最终,在AWS SSO中运行正确的配置为:

Attribute APP	Attributte SSO	Format

Subject ${user:email} emailAddress name ${user:name} basic last_name ${user:familyName} basic first_name ${user:givenName} basic email ${user:email} basic

祝好!

profile picture
专家
已回答 5 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则