🇰🇷 한글 설명
phpseclib 라이브러리에서 X.509 인증서를 검증할 때 AIA 확장 필드에 포함된 URL로 자동 연결되는 취약점이 발견되었습니다. 공격자가 조작된 인증서를 제공하면 서버가 내부 네트워크나 클라우드 메타데이터 주소로 요청을 보내게 만드는 SSRF 공격이 가능합니다.
💡 쉬운 설명
인증서를 확인하는 과정에서 서버가 공격자가 지정한 주소로 몰래 접속을 시도하는 문제입니다. 이를 통해 외부에서는 접근할 수 없는 회사의 내부 시스템이나 중요한 정보에 접근할 수 있습니다.
🇺🇸 원문 (English)
phpseclib is a PHP secure communications library. From 0.1.1 until 1.0.30, 2.0.55, and 3.0.54, when an application validates an untrusted X.509 certificate with phpseclib, X509::validateSignature() reads a URL out of that certificate's Authority Information Access (AIA) extension and connects to it. Attacker who supplies certificate fully controls host, port, and path of that connection. URL fetching is enabled by default, and no destination is blocked. An unauthenticated attacker can therefore make a validating server open connections to internal hosts and ports it should never reach, for example loopback 127.0.0.1, cloud metadata address 169.254.169.254, and internal-only services. This is a server-side request forgery (SSRF) caused by an insecure default. This vulnerability is fixed in 1.0.30, 2.0.55, and 3.0.54.
📍 영향받는 시스템
phpseclib 0.1.1 ~ 1.0.29, 2.0.54 이하, 3.0.53 이하 버전
⚔️ 공격 벡터
조작된 AIA 확장 필드를 포함한 X.509 인증서를 서버에 전달하여 SSRF 유도
🛡️ 대응 방법
phpseclib를 1.0.30, 2.0.55 또는 3.0.54 이상의 최신 버전으로 업데이트
🔧 검증 코드
출력된 버전이 취약 버전 범위(1.0.30 미만, 2.0.55 미만, 3.0.54 미만)에 해당하는지 확인
composer show phpseclib/phpseclib | grep 'versions'