0

I have to call a third party service with a Oauth2 token. I don't need to authenticate/authorize my incoming requests. I have added below jars in my Spring Boot 2 application.

  1. spring-security-oauth2:2.3.5.RELEASE
  2. spring-cloud-starter-security:2.1.5.RELEASE

This works fine but the problem is whenever I start my server, it generates a default user password and intercepts my requests. This throws HTTP 401 to all incoming requests. I had to write an adapter to permit all incoming requests. Is there any other way to bypass this. Is there any way to prevent spring security getting triggered for all incoming requests?

Arun
  • 3,701
  • 5
  • 32
  • 43
  • I blv you can find your answer in this SO question if you can differentiate your login url. https://stackoverflow.com/questions/30366405/how-to-disable-spring-security-for-particular-url – nabster May 11 '20 at 17:27
  • @nabster I did that in my application but how can I add the jars and configure spring not to intercept my incoming requests without a custom adapter – Arun May 11 '20 at 17:31

0 Answers0