본문으로 바로가기

DBeaver 에서 MSSql접속시 아래와 같은 에러가 발생할때 조치 방법

encrypt" 속성이 "true"(으)로 설정되고 "trustServerCertificate" 속성이 "false"(으)로 설정되었지만 드라이버가 SSL(Secure Sockets Layer) 암호화를 사용하여 SQL Server에 대한 보안 연결을 설정할 수 없습니다.
오류: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target. ClientConnectionId:526cb3f4-5e2f-404c-bc59-ca5cbe0884b1 PKIX path building failed:

sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target PKIX path building failed:
sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target unable to find valid certification path to requested target unable to find valid certification path to requested target

위와 같은 에러는 드라이버 설정에서 서버를 신뢰하지 않으며 통신 데이터를 암호화를 하겠다는 기본 설정 때문에 발생하는 것으로 ( trustServerCertificate: false, encrypt:true) 검색엔진의 검색결과에   encrypt를 false로하는 방법이 많이 검색되지만 이는 적절하지 않은 방법이라고 생각된다.

 

보통 개발이나 운영 시 접속하는 DB서버는 VPN이나 방화벽 또는 접근제어 솔루션을 통과하여 IP기반으로 접속하기 때문에 신뢰할 수 있는 서버로 판단 할 수 있으므로 통신 데이터의 암호화를 비활성화 하는 방법보다는 서버를 신뢰하는 것으로 하는 것이 더 좋다.(IP/도메인 변조에 대응하기 위해서는 서버의 인증서를 기반으로 하는 것이 보안을 보다 강화하는 방법이 될 것이다.)

 

해당 커넥션을 선택 후 F4키를 눌러 편집모드 팝업창을 띄운 후 Driver properties 탭에서 trustServerCertificate 값을 true 로 설정하면 원활하게 접속됨을 확인 할 수 있다.