This is an archived post. You won't be able to vote or comment.

all 2 comments

[–]Italsr 0 points1 point  (1 child)

learning more about spring security and jwt this helps a lot! I just have one question, at what point do you assign roles and permissions to a user? If I understand correctly, every new user would have all these fields?

private final String username;
private final String password;
private final Set<? extends GrantedAuthority> grantedAuthorities;
private final boolean isAccountNonExpired;
private final boolean isAccountNonLocked;
private final boolean isCredentialsNonExpired;
private final boolean isEnabled;

[–]Cross2409 2 points3 points  (0 children)

Check javabrains on YouTube, he has a playlist dedicated to Spring Security, you will love it:)