🇰🇷 한글 설명
Perl용 Rex 1.16.1 이하 버전에서 rsync 전송 시 SSH 호스트 키 확인을 강제로 비활성화(StrictHostKeyChecking=no)하도록 하드코딩되어 있습니다. 이로 인해 공격자가 중간에서 연결을 가로챌 경우, 사용자가 인지하지 못한 채 비밀번호나 파일 데이터가 유출될 수 있습니다.
💡 쉬운 설명
파일을 원격으로 보낼 때 상대방이 진짜인지 확인하는 보안 절차가 꺼져 있는 상태입니다. 이 때문에 가짜 서버가 중간에 끼어들어도 컴퓨터가 이를 알아채지 못하고 비밀번호나 파일을 넘겨줄 수 있습니다.
🇺🇸 원문 (English)
Rex versions through 1.16.1 for Perl accept an unknown SSH host key for remote rsync transfers because sync hardcodes StrictHostKeyChecking=no.
Every remote branch of sync builds its ssh command with that option, for password authentication, for private-key authentication and for the fallback. The ssh options a caller sets through set_openssh_opt reach the OpenSSH transport but not this command, so there is no configuration that restores host key checking for the transfer.
An attacker who can redirect the connection before the real host key is known presents their own and the transfer proceeds: under password authentication sync sends the connection password to that server, an upload writes the selected local files to it, and a download writes what it returns to the local destination.
📍 영향받는 시스템
Rex (Perl) versions up to 1.16.1
⚔️ 공격 벡터
Man-in-the-Middle (MitM)을 통한 SSH 연결 가로채기 및 호스트 키 위조
🛡️ 대응 방법
Rex를 1.16.1보다 높은 버전으로 업데이트하거나, SSH 설정에서 호스트 키 확인이 강제되도록 수정해야 합니다.
🔧 검증 코드
출력된 버전 번호가 1.16.1 이하이면 취약한 버전입니다.
perl -e 'use Rex; print $Rex::VERSION . "\n"' 2>/dev/null || echo 'Rex not installed'