@Bean public PasswordEncoder passwordEncoder() { return PasswordEncoderFactories.createDelegatingPasswordEncoder(); }PasswordEncoder 빈 주입return new BCryptPasswordEncoder(); -> return PasswordEncoderFactories.createDelegatingPasswordEncoder();으로 변경하였다.Password Storage :: Spring SecuritySpring Security’s PasswordEncoder interface is used to perform a one-way transformation of a password to let the..
JwtAuthenticationFilter 라고UsernamePasswordAuthenticationFilter.class 이전에//로그인전 UserPasswordAuthenticationFilter 를 통해 인증을 받도록 설정 .addFilterBefore(jwtAuthenticationFilter(), UsernamePasswordAuthenticationFilter.class);항상 해당 필터를 거치도록 설정을 하였다.초기@Slf4j public class JwtAuthenticationFilter extends UsernamePasswordAuthenticationFilter { @Autowired private PasswordEncoder passwordEncoder; /** * authenti..
package org.example.알고리즘.행렬의덧셈; import java.util.Arrays; /**/ class Solution { public static void main(String[] args) { Solution solution = new Solution(); System.out.println(Arrays.deepToString(solution.solution(new int[][]{{1, 2}, {2, 3}}, new int[][]{{3, 4}, {5, 6}}))); } public int[][] solution(int[][] arr1, int[][] arr2) { ArrayClass arrayClass1 = new ArrayClass(arr1); ArrayClass arrayClass..
도입컨트롤러 테스트 코드 작성시 illegalStateException 을 던졌다.하지만, 응답으로 badRequest.. internalServerError 등으로 응답을 받으려고해봤는데 도무지 받아지지 않았다.// when + then doThrow(new IllegalStateException("cart product delete is failed")) .when(cartService) .removeCart(mock);org.springframework.web.util.NestedServletException: Request processing failed; nested exception is java.lang.IllegalStateException: cart product delete is fai..