일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
- 그리디
- Stack
- 분할정복
- 그래프 탐색
- 프로세스
- Python
- 몬티홀
- deque
- springboot
- 문제풀이
- 구현
- GC
- 정수론
- 마크다운
- 이진탐색
- 배열 돌리기1
- Markdown
- 회고
- 면접복기
- 그래프탐색
- DP
- github
- 브루트포스
- GarbageCollector
- BFS
- g1gc
- Greedy
- 백준
- 적정 스레드
- 빌더패턴
- Today
- Total
목록프로그래밍/Spring (3)
FeelingXD
멀티 포트의 필요성대부분의 경우에선 그렇지 않겠지만 서버를 여러포트로 지원해야할 때가있다. 예를들어 https 와 http 둘 모두를 지원해야한다면 두개의 경우를 생각해서 포트를 구성해야한다.코드// kotlin 코드입니다. :)package com.feelinxd.app.configimport org.apache.catalina.Contextimport org.apache.catalina.connector.Connectorimport org.apache.tomcat.util.descriptor.web.SecurityCollectionimport org.apache.tomcat.util.descriptor.web.SecurityConstraintimport org.springframework.beans...
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/b1Vz9M/btsFCwkGkJY/51odrkqoeMfjpdLGyIjyQ1/img.png)
TLDR; 스프링 부트 2.x 버전에서는 스프링 시큐리티 특정 URL 에대한 스프링 필터를 무시하기 위해 WebSecurityConfigurerAdapter 를 사용했다. 하지만 WebSecurityConfigurerAdapter 가 deprecate 되고 나서는 다음과 같이 사용한다. 기존 WebSecurityConfigurerAdapter 를 상속하는 방법은 다음과 같았다. @Configuration public class SecurityConfiguration extends WebSecurityConfigurerAdapter { @Override public void configure(WebSecurity web) { web.ignoring().antMatchers("/ignore1", "/igno..
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/xQXsD/btsFm0NGkrR/aWcRsvaLtiaIzlKKYvDV00/img.png)
🤔 - 스프링 부트3.x 버전부터 Spring-Security 설정법들이 몇가지 변경 되었습니다. 알게 된점 몇가지를 작성합니다. 1. Security http Request 을 lambda 형식으로 ! 기존 HttpSecurity 의 Request 관련 적용이 변경되었습니다. //예시코드 @Bean public SecurityFilterChain defaultFilter(HttpSecurity http) throws Exception { http .securityMatchers.requestMatchers("/api/**") .and() .authorizeHttpRequests.anyRequest().hasRole("USER") .and() .httpBasic(Customizer.withDefaults..