1

I want to allow anonymous access to my index page, which means the URL will be either localhost:8080/MyProject/ or localhost:8080/MyProject/index.xhtml. I have read through this but the case is different with mine. I tried to configure it like this:<>

http.authorizeRequests().antMatchers("/javax.faces.resource/**", "/", "/index.xhtml").permitAll().anyRequest().authenticated();

With the statement above, the URL localhost:8080/MyProject/index.xhtml will allow anonymous access but localhost:8080/MyProject/ will still denied the access. Help?

Newbie
  • 1,584
  • 9
  • 33
  • 72

1 Answers1

0

Try this:

.antMatchers("/*").permitAll() or .antMatchers("/MyProject/*").permitAll()