ssl을 적용하였는데 기존의 http로 접속될 시에 https로 강제 리다이렉트 하는 법
<security-constraint>
<web-resource-collection>
<web-resource-name>Protected Context</web-resource-name>
<url-pattern>/*</url-pattern>
</web-resource-collection>
<user-data-constraint>
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
</user-data-constraint>
</security-constraint>
톰캣 conf - web.xml 파일에 해당 태그를 추가합니다.
서버를 재시작 합니다.
이상입니다! 궁금한 점 있으시면 댓글 달아주세요!
'Backend > 서버' 카테고리의 다른 글
[JAVA / SERVER(Window)] file.delete() 에러 / file 삭제 안될 때 (0) | 2022.07.26 |
---|