feat(client): add optional dest_app_name to auth request JWT#34
Open
fadedsky wants to merge 1 commit intoduosecurity:mainfrom
Open
feat(client): add optional dest_app_name to auth request JWT#34fadedsky wants to merge 1 commit intoduosecurity:mainfrom
fadedsky wants to merge 1 commit intoduosecurity:mainfrom
Conversation
- Extend create_auth_url with optional dest_app_name for Duo OIDC request.payload.dest_app_name - Include dest_app_name in the signed request JWT only when provided - Add unit test coverage for the authorization URI JWT payload
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This change extends
Client.create_auth_urlwith an optionaldest_app_nameparameter. When provided and truthy,
dest_app_nameis included in the signedauthorization
requestJWT payload asdest_app_name, matching Duo’s OIDCAuth API field for a user-facing destination application name.
Motivation and Context
Duo documents
dest_app_nameas an optional field in the authorization requestJWT payload. Our Duo Admin expressed that it was a nice touch when they were looking
at logs that included it.
Reference: https://duo.com/docs/oauthapi#authorization-request
How Has This Been Tested?
Added/updated unit coverage in tests/test_create_auth.py to assert the
generated authorization URI’s
requestJWT includesdest_app_namewhenpassed to
create_auth_url.Also tested it on one of dev apps and our Duo Admin confirmed that the dest_app_name
was showing.
Types of Changes