Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

auth.AwsCredentialsProvider - Using AWS SSO profile? #335

Closed
cgddrd-gardin opened this issue Feb 24, 2022 · 2 comments
Closed

auth.AwsCredentialsProvider - Using AWS SSO profile? #335

cgddrd-gardin opened this issue Feb 24, 2022 · 2 comments
Labels
CRT/SDK feature-request A feature should be added or improved. p3 This is a minor priority issue

Comments

@cgddrd-gardin
Copy link

Hi,

I'm hoping that there's a way of using awscrt.auth.AwsCredentialsProvider to authenticate a Python app that communicates with IoT Core/Shadow Service using an AWS SSO profile, rather that requiring a sytatic set of IAM credentials (access key/secret pair) in an ~/.aws/credentials file.

Is this possible?

Many thanks.

@bretambrose
Copy link
Contributor

The aws-c-* libraries don't implement an SSO-based credentials provider yet, so you can't do that directly. However, you should be able to use the standard AWS SDK for python SSO provider implementation and wrap that in a delegate provider that defers to the Python SDK provider: https://github.com/awslabs/aws-crt-python/blob/main/awscrt/auth.py#L282.

@broglep-work
Copy link

in case somebody else stumbles upon this, here is an implementation of a credentials provider that delegates to standard AWS SDK. It should be reasonably solid, but is not really battle tested:

https://gist.github.com/broglep-work/1835d8c9465e83d177097f467d82df17

@jmklix jmklix added the feature-request A feature should be added or improved. label Feb 16, 2023
@jmklix jmklix added the CRT/SDK label Mar 27, 2023
@yasminetalby yasminetalby added the p3 This is a minor priority issue label Jun 26, 2023
@jmklix jmklix closed this as completed May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CRT/SDK feature-request A feature should be added or improved. p3 This is a minor priority issue
Projects
None yet
Development

No branches or pull requests

5 participants