@Bean public SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
return http.csrf().disable()
.authorizeHttpRequests()
.requestMatchers("/home/normal")
.permitAll()
.and()
.authorizeHttpRequests().requestMatchers("/products/**")
.authenticated().and().formLogin().and().build();
}
how to write .csrf() ,.authorizeHttpRequests(),.formLogin() because it showing error that is deprecated and marked for removal.I m using springboot 3.2 version and spring security 6.2