1

I have a jhipster microsrvice and gateway App set up. Its a search application that I am trying to build. For this, I do not need user to be authenticated on every request.

So, for this I am trying add following line to securityConfiguration of gatewayApp.

.antMatchers("/api/**").permitAll();

but I get exception with message :

message" : "Error processing condition on org.springframework.cloud.netflix.ribbon.eureka.EurekaRibbonClientConfiguration.ribbonPing

I tried with antMatchers("fruitservicev1/api/**").permitAll(), where fruitservicev1 is the name of my service app.

I also tried to change .antMatchers("/api/").authenticated() to .antMatchers("/api/").pertmitAll(); in MicroserviceSecurityConfiguration of service App.

Still gets the same exception.

the only thing that works is : .antMatchers("fruitservicev1/api/cities").permitAll() in secturityConfiguration of gateway app.

but with this, I would have to add each url in this file. Is there any other way to do this?

1 Answers1

0

Maybe the problem comes from the order you wrote the permission in your configuration. Check this : https://stackoverflow.com/a/31792102/8800147

br.julien
  • 3,420
  • 2
  • 23
  • 44