ODIC Custom Claim using sts:AssumeRoleWithWebIdentity condition

0

Given the following JWT Payload:

{
  "iss": "https://use.us.auth0.com/",
  "sub": "auth0|633c9a79c4920862610fa",
  "aud": "some-aud",
  "iat": 1664984891,
  "exp": 1665071291,
  "azp": "kWfeLjcWoT1ToQKmyYZQft7liE",
  "scope": "aws:0123456789012"
}

is a trust policy such as this one not valid? I only want to issue a token if the scope matches

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Effect": "Allow",
            "Principal": {
                "Federated": "arn:aws:iam::123456789012:oidc-provider/user.us.auth0.com/"
            },
            "Action": "sts:AssumeRoleWithWebIdentity",
            "Condition": {
                "StringEquals": {
                    "johnnorton.us.auth0.com/:aud": "some-aud",
                    "johnnorton.us.auth0.com/:scope": "aws:0123456789012"
                }
            }
        }
    ]
}

However this condition does not seem to be validated. Are all claims available in trust policies?

沒有答案

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南