Assigning more than 10 IoT policies on identity

0

We are using AWS IoT things to represent our IoT devices. Our users are getting temp credentials using the AWS Cognito Identity Pool. We mapped the group id claim from the ID Token to the Principal, and we need a way to connect this group ID to the things in this group in the IoT policy. Based on the current solution 1 thing has 1 certificate, and the IoT policy is attached to the certificate and to the identity. With this, the thing and the identity are connected, but there is no way to check that in the IoT policy. This solution suggests a thing prefix with the group Id, or a custom policy manager that will have permissions for multiple things, is there any other way for doing this?

1개 답변
0

I recommend using AWS IoT custom authorizer to manage more complex and dynamic authorization schemas.

The authorizer lambda function can receive the JWT token, extract the necessary claims and craft an on-demand policy with the required resources whose names depends on the claims.

You can refer to this repo for an example on how to implement a custom authorizer to validate JWT tokens.

AWS
전문가
답변함 일 년 전
  • Thank you, but with this solution there are still the 10 policies per identity and 2048 characters per policy limits.

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인