- 학습 관련 질문을 남겨주세요. 상세히 작성하면 더 좋아요!
- 먼저 유사한 질문이 있었는지 검색해보세요.
- 서로 예의를 지키며 존중하는 문화를 만들어가요.
- 잠깐! 인프런 서비스 운영 관련 문의는 1:1 문의하기를 이용해주세요.
- 먼저 유사한 질문이 있었는지 검색해보세요.
- 서로 예의를 지키며 존중하는 문화를 만들어가요.
- 잠깐! 인프런 서비스 운영 관련 문의는 1:1 문의하기를 이용해주세요.
안녕하세요. 스프링 시큐리티 공부중인데
아래 두가지 passwordEncoder 빈 생성 시 차이가 무엇인지, 성능 차이 또는 동작방식 차이가 있는지 궁금합니다.
감사합니다.
@Configuration
public class SecurityConfig {
@Bean
public PasswordEncoder passwordEncoder() {
return PasswordEncoderFactories.createDelegatingPasswordEncoder();
}
}
@Configuration
public class SecurityConfig {
@Value("${security.bcrypt.strength}")
private int strength;
@Bean
public PasswordEncoder passwordEncoder() {
return new BCryptPasswordEncoder(strength);
}
}