Skip to content

Commit

Permalink
Remove commented code
Browse files Browse the repository at this point in the history
  • Loading branch information
ramveer93 committed Oct 19, 2020
1 parent 1b05da2 commit 081bcc5
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,17 +44,18 @@ public AuthenticationManager authenticationManagerBean() throws Exception {
@Override
protected void configure(HttpSecurity http) throws Exception {
http.csrf().disable().authorizeRequests()
.antMatchers("/v1/**").permitAll()
// .antMatchers("/v1/**").permitAll()
// .antMatchers("/api").permitAll()
.antMatchers("/swagger-ui.html").permitAll()
.antMatchers("/v1/token").permitAll()
.antMatchers("/v1/addUser").permitAll()
.antMatchers("/css/**").permitAll()
.antMatchers("/js/**").permitAll()
.antMatchers("/favicon.ico").permitAll()

//TODO : uncomment below line if you want to authenticate
// .antMatchers("/v1/**").hasIpAddress(ip)
//.anyRequest().authenticated().and().exceptionHandling()
.anyRequest().authenticated().and().exceptionHandling()
.and().sessionManagement().sessionCreationPolicy(SessionCreationPolicy.STATELESS);
http.addFilterBefore(jwtFilter, UsernamePasswordAuthenticationFilter.class);
}
Expand Down

0 comments on commit 081bcc5

Please sign in to comment.