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

Add support for setting ID Token nonce from Unity #57

Merged
merged 3 commits into from
Sep 4, 2023

Conversation

onevcat
Copy link
Member

@onevcat onevcat commented Aug 25, 2023

This should solve #56. In this PR we added the nonce property to the login option, to allow Unity users to set a customized nonce for verifying against their server. To use it, set the IDTokenNonce value in the option and pass it to Login:

var scopes = new string[] {"profile openid"};
var option = new LoginOption();
option.IDTokenNonce = "abc123";

LineSDK.Instance.Login(scopes, option, result => {
     // handle the result
});

@onevcat
Copy link
Member Author

onevcat commented Aug 25, 2023

@plateaukao This time I also tried to implement the Android side too. Please check and review it when you have time! Thanks.

if (!Application.isPlaying) { return; }
if (!Application.isPlaying) { return; }

Choose a reason for hiding this comment

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

It seems like a typo.
Is it correct that the space is removed intentionally?

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks! Should be fixed in 835b3a7

Copy link

@daviscdev daviscdev left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you!

@onevcat onevcat merged commit fafdf5c into master Sep 4, 2023
@onevcat onevcat deleted the feature/idtoken-nonce branch September 4, 2023 01:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants