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

[SRA] Add identity resolver for bearer authentication scheme #3562

Merged
merged 8 commits into from
Dec 12, 2024

Conversation

dscpinheiro
Copy link
Contributor

@dscpinheiro dscpinheiro commented Nov 30, 2024

Description

Updates the IdentityResolverConfiguration to resolve the bearer authentication scheme (i.e. the smithy.api#httpBearerAuth trait). I also had to modify other existing components (such as the bearer token signer) since their implementation is different than SigV4 / SigV4A credentials.

Motivation and Context

DOTNET-7652

Testing

  • Dry-run: DRY_RUN-53687653-2c3c-4b33-9fa5-1ac8868e497a
  • Ran a local application specifying a profile using SSO (note: while testing I noticed we're not including the Smithy project DLL in the Core .nupkg file - will address that in a separate PR).

Types of changes

  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My code follows the code style of this project
  • I have read the README document
  • I have added tests to cover my changes
  • All new and existing tests passed

License

  • I confirm that this pull request can be released under the Apache 2 license

@dscpinheiro dscpinheiro force-pushed the dspin/DOTNET-7652-sso-auth-scheme branch from 29eda94 to a7f126e Compare December 1, 2024 23:53
@dscpinheiro dscpinheiro requested a review from normj December 4, 2024 20:42
* Update signer to accept BaseIdentity instead of ImmutableCredentials
* Use ClientException instead of ServiceException in
  FallbackCredentialsFactory replacement
* Update blocking call to use .GetAwaiter().GetResult()
@dscpinheiro dscpinheiro requested a review from normj December 7, 2024 00:50
Copy link
Member

@normj normj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the AbstractAWSSigner we need to get rid of the abstract Sign operation that takes in a access and secret key so we are always dealing with the BaseIdentity. I created a PR to this PR that does that work and I'm currently running the dry run. Assuming the dry run is successful and @muhammad-othman approves my PR we can merge that PR into this PR and then I'll approve this PR so we can merge it.

#3575

@muhammad-othman muhammad-othman merged commit 69556ab into sra-identity-auth Dec 12, 2024
1 check passed
@muhammad-othman muhammad-othman deleted the dspin/DOTNET-7652-sso-auth-scheme branch December 12, 2024 12:21
muhammad-othman pushed a commit that referenced this pull request Dec 19, 2024
* feat: Add bearer token authentication scheme

* refactor: Address PR feedback

* refactor: Address PR comments

* Update signer to accept BaseIdentity instead of ImmutableCredentials
* Use ClientException instead of ServiceException in
  FallbackCredentialsFactory replacement
* Update blocking call to use .GetAwaiter().GetResult()

* fix: Update S3Express handler for signer signature change

* fix: Update AWSToken to use correct base class

* fix: Update comment for blocking call

* fix: Add blocking call in pipeline handler

* Remove abstract Sign override that uses access and secret key. (#3575)

---------

Co-authored-by: Norm Johanson <[email protected]>
muhammad-othman pushed a commit that referenced this pull request Jan 3, 2025
* feat: Add bearer token authentication scheme

* refactor: Address PR feedback

* refactor: Address PR comments

* Update signer to accept BaseIdentity instead of ImmutableCredentials
* Use ClientException instead of ServiceException in
  FallbackCredentialsFactory replacement
* Update blocking call to use .GetAwaiter().GetResult()

* fix: Update S3Express handler for signer signature change

* fix: Update AWSToken to use correct base class

* fix: Update comment for blocking call

* fix: Add blocking call in pipeline handler

* Remove abstract Sign override that uses access and secret key. (#3575)

---------

Co-authored-by: Norm Johanson <[email protected]>
dscpinheiro added a commit that referenced this pull request Jan 12, 2025
* feat: Add bearer token authentication scheme

* refactor: Address PR feedback

* refactor: Address PR comments

* Update signer to accept BaseIdentity instead of ImmutableCredentials
* Use ClientException instead of ServiceException in
  FallbackCredentialsFactory replacement
* Update blocking call to use .GetAwaiter().GetResult()

* fix: Update S3Express handler for signer signature change

* fix: Update AWSToken to use correct base class

* fix: Update comment for blocking call

* fix: Add blocking call in pipeline handler

* Remove abstract Sign override that uses access and secret key. (#3575)

---------

Co-authored-by: Norm Johanson <[email protected]>
dscpinheiro added a commit that referenced this pull request Jan 29, 2025
* feat: Add bearer token authentication scheme

* refactor: Address PR feedback

* refactor: Address PR comments

* Update signer to accept BaseIdentity instead of ImmutableCredentials
* Use ClientException instead of ServiceException in
  FallbackCredentialsFactory replacement
* Update blocking call to use .GetAwaiter().GetResult()

* fix: Update S3Express handler for signer signature change

* fix: Update AWSToken to use correct base class

* fix: Update comment for blocking call

* fix: Add blocking call in pipeline handler

* Remove abstract Sign override that uses access and secret key. (#3575)

---------

Co-authored-by: Norm Johanson <[email protected]>
dscpinheiro added a commit that referenced this pull request Feb 15, 2025
* feat: Add bearer token authentication scheme

* refactor: Address PR feedback

* refactor: Address PR comments

* Update signer to accept BaseIdentity instead of ImmutableCredentials
* Use ClientException instead of ServiceException in
  FallbackCredentialsFactory replacement
* Update blocking call to use .GetAwaiter().GetResult()

* fix: Update S3Express handler for signer signature change

* fix: Update AWSToken to use correct base class

* fix: Update comment for blocking call

* fix: Add blocking call in pipeline handler

* Remove abstract Sign override that uses access and secret key. (#3575)

---------

Co-authored-by: Norm Johanson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants