-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Add Support GenerateOneTimeTokenRequestResolver #16297
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
714b2c4
to
6d330d7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR! I've provided feedback inline.
* @param username username | ||
* @param expiresIn one-time token expiration time (seconds) | ||
*/ | ||
public GenerateOneTimeTokenRequest(String username, int expiresIn) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change expiresIn to a Duration
...ingframework/security/web/authentication/ott/DefaultGenerateOneTimeTokenRequestResolver.java
Outdated
Show resolved
Hide resolved
|
||
private static final int DEFAULT_EXPIRES_IN = 300; | ||
|
||
private int expiresIn = DEFAULT_EXPIRES_IN; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change this to a Duration
...ingframework/security/web/authentication/ott/DefaultGenerateOneTimeTokenRequestResolver.java
Outdated
Show resolved
Hide resolved
...amework/security/config/annotation/web/configurers/ott/OneTimeTokenLoginConfigurerTests.java
Show resolved
Hide resolved
...c/main/java/org/springframework/security/authentication/ott/GenerateOneTimeTokenRequest.java
Outdated
Show resolved
Hide resolved
private final String username; | ||
|
||
private final int expiresIn; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change this to a Duration
...c/main/java/org/springframework/security/authentication/ott/GenerateOneTimeTokenRequest.java
Outdated
Show resolved
Hide resolved
...c/main/java/org/springframework/security/authentication/ott/GenerateOneTimeTokenRequest.java
Outdated
Show resolved
Hide resolved
6d330d7
to
dedf366
Compare
@rwinch thanks for feedback, all your comments have been resolved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sorry I missed one more thing. Can you please document the changes and ensure to add a link in the What's New section to those changes?
a5cdaae
to
0dba7d6
Compare
Closes spring-projectsgh-16291 Signed-off-by: Max Batischev <mblancer@mail.ru>
0dba7d6
to
a879f76
Compare
Added documentation, @rwinch done :) |
Thanks for the PR and your quick attention to changes! This is now merged into main 😄 |
Closes gh-16291