File tree 2 files changed +1
-35
lines changed
src/main/java/org/ladocuploader/app/config
2 files changed +1
-35
lines changed Original file line number Diff line number Diff line change 1
1
package org .ladocuploader .app .config ;
2
2
3
-
4
3
import org .springframework .context .annotation .Bean ;
5
4
import org .springframework .context .annotation .Configuration ;
6
- import org .springframework .context .annotation .Profile ;
7
- import org .springframework .security .config .Customizer ;
8
5
import org .springframework .security .config .annotation .web .builders .HttpSecurity ;
9
- import org .springframework .security .config .annotation .web .configuration .EnableWebSecurity ;
10
- import org .springframework .security .config .http .SessionCreationPolicy ;
11
6
import org .springframework .security .web .SecurityFilterChain ;
12
7
13
8
@ Configuration
14
- @ EnableWebSecurity
15
- @ Profile ({"prod" })
16
9
public class SecurityConfiguration {
17
10
@ Bean
18
11
public SecurityFilterChain filterChain (HttpSecurity http ) throws Exception {
19
- http
20
- .authorizeHttpRequests ((authorize ) -> {
21
- try {
22
- authorize .anyRequest ().authenticated ();
23
- } catch (Exception e ) {
24
- throw new RuntimeException (e );
25
- }
26
- }).httpBasic (Customizer .withDefaults ());
12
+ http .httpBasic ().disable ();
27
13
return http .build ();
28
14
}
29
15
}
30
-
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments