我在Unity中使用facebook登录facebook . 我想使用带有认知凭据的dynamodb . 未经身份验证的凭据可以使用,但经过身份验证的凭据会显示错误

DynamoDB GetItem Error : User: arn:aws:sts::XXXXXXXXXXX:assumed-role/"my identity pool"/CognitoIdentityCredentials is not authorized to perform: dynamodb:GetItem on resource: arn:aws:dynamodb:ap-northeast-1:XXXXXXXXXX:table/"table name"

我在IAM Role中放置了Action“dynamodb:GetItem”,问题是IAM Role的条件 . 如果我在IAM角色中删除了条件,它就可以了 . 但我想增加安全条件 . 这是我的IAM角色条件

"Condition": {
            "ForAllValues:StringEquals": {
                "dynamodb:LeadingKeys": [
                    "${cognito-identity.amazonaws.com:sub}"
                ]
            }
        }

请告诉我该怎么做谢谢..