3
votes

I have a Jax-RS application that uses spring for the component wiring and spring security for the authentication and authorization part. I have been trying to configure spring security with OAuth2 and JWT tokens but there is not any good sample to follow. The only one that I was able to find is this one: https://github.com/spring-projects/spring-security-oauth but it doesn't really shed any light on how the authentication part is done, for example how to obtain a token or how to send it (cookies or header) Is anyone aware of any good example on this specific setup?

Best.

1
You have progressed ? - Stephane
@StephaneEybert yes, I was able to make this working, I have already answered my own question ;) please checkout the gist.github.com/maxsap/da154f99a2dbb414471a for more info, I think all the configuration classes required are in there. - maxsap

1 Answers

1
votes

I haven't found any good examples other that the ones mentioned in the original post. I have successfully managed to get this working. For anyone interested I have created this gist. I would like to create a full project when I find some spare time