Migrate Spring Security configuration for Spring Security 6

I have this Spring Security code which I want to configure for Spring Security 6:

public void configure(final HttpSecurity http) throws Exception {

    http.authorizeRequests()
        .antMatchers(permittedAntMatchers())
        .permitAll();

    http.authorizeRequests().antMatchers("/**").authenticated();

    .....

    http.exceptionHandling()....;
  }

I get error for Cannot resolve method 'antMatchers' in 'ExpressionInterceptUrlRegistry'. Do you know how I can migrate this project properly?



Comments

Popular posts from this blog

I get wrong characters when retreiving the message body of an email using TIdIMAP4.UIDRetrieveTextPeek2()

How to drop the all the 1's in a correlation matrix

Today Walkin 14th-Sept