Skip to content
KitploitKITPLOIT
도구블로그
제출
도구블로그
제출

해킹, 침투 테스트 및 사이버 보안 도구를 당신의 보안 무기고에!

Kitploit은 해킹, 사이버 보안 및 침투 테스트 도구 디렉토리입니다. 최신 프로젝트 업데이트를 발견하여 취약점을 찾고, 시스템을 분석하고, 테스트를 자동화하고, 보안을 강화하세요.

··피드·문의·개인정보·© 2026 Kitploit

도구 디렉토리

카테고리

모든 카테고리 보기
Loading categories
CVE-2021-39273-CVE-2021-39274 — XeroSecurity가 Sn1per v9.0 무료 버전에서 발견한 두 가지 보안 문제 | Kitploit
도구/GitHubGitHub/nikip72/cve-2021-39273-cve-2021-39274
Privilege EscalationVulnerability AnalysisExploitationPenetration TestingMisconfiguration
GitHubnikip72/cve-2021-39273-cve-2021-39274

CVE-2021-39273-CVE-2021-39274

XeroSecurity가 Sn1per v9.0 무료 버전에서 발견한 두 가지 보안 문제

저장소 보기
115년 전아직 검토되지 않음

인기

모두 보기 →

커뮤니티에서 가장 많이 사용되는 도구를 찾아보세요.

모든 도구 탐색

도구 컬렉션을 둘러보세요

모든 도구 보기 →
공유

CVE-2021-39273

XeroSecurity Sn1per 9.0(무료 버전)에서는 애플리케이션 실행 시 안전하지 않은 권한(0777)이 설정되어, 권한이 없는 사용자가 애플리케이션, 모듈 및 구성 파일을 수정할 수 있습니다. 이로 인해 루트 권한으로 임의 코드 실행이 가능합니다.

CVE-2021-39274

XeroSecurity Sn1per 9.0(무료 버전)에서는 설치 중에 안전하지 않은 디렉터리 권한(0777)이 설정되어, 권한이 없는 사용자가 메인 애플리케이션과 애플리케이션 구성 파일을 수정할 수 있습니다. 이로 인해 루트 권한으로 임의 코드 실행이 발생합니다.

테스트 환경: Ubuntu 21.04

Sn1per 설치 지침에서:

root@kitploit:~
KALI/UBUNTU/DEBIAN/PARROT LINUX INSTALL:

git clone https://github.com/1N3/Sn1per
cd Sn1per
bash install.sh

설치

root@kitploit:~
root@snipertest:~# git clone https://github.com/1N3/Sn1per
Cloning into 'Sn1per'...
remote: Enumerating objects: 2838, done.
remote: Counting objects: 100% (13/13), done.
remote: Compressing objects: 100% (9/9), done.
remote: Total 2838 (delta 5), reused 10 (delta 4), pack-reused 2825
Receiving objects: 100% (2838/2838), 43.18 MiB | 18.76 MiB/s, done.
Resolving deltas: 100% (1950/1950), done.
root@snipertest:~# cd Sn1per/
root@snipertest:~/Sn1per# bash install.sh
                ____
    _________  /  _/___  ___  _____
   / ___/ __ \ / // __ \/ _ \/ ___/
  (__  ) / / // // /_/ /  __/ /
 /____/_/ /_/___/ .___/\___/_/
               /_/

 + -- --=[ https://xerosecurity.com
 + -- --=[ Sn1per by @xer0dayz

[>] This script will install sn1per under /usr/share/sniper. Are you sure you want to continue? (Hit Ctrl+C to exit)
y
[snip]
'/usr/share/sniper/sniper.conf' -> '/root/.sniper.conf'
Please run msfdb as a non-root user
[*] Adding start menu and desktop shortcuts...
[>] Done!
[>] To run, type 'sniper'!
root@snipertest:~/Sn1per#

CVE-2021-39274

설치 직후 설치 디렉터리의 권한은 다음과 같이 설정됩니다:

root@kitploit:~
root@snipertest:~/Sn1per# ls -ld /usr/share/sniper/
❗drwxrwxrwx❗ 10 root root 4096 Aug 16 19:19 /usr/share/sniper/

root@snipertest:~/Sn1per# ls -la /usr/share/sniper/
total 6668
drwxrwxrwx  10 root root    4096 Aug 16 19:19 .
drwxr-xr-x 222 root root   12288 Aug 16 19:41 ..
-rw-r--r--   1 root root   36518 Aug 16 18:33 CHANGELOG.md
-rw-r--r--   1 root root    1269 Aug 16 18:33 Dockerfile
-rw-r--r--   1 root root     306 Aug 16 18:33 LICENSE.md
-rw-r--r--   1 root root   11697 Aug 16 18:33 README.md
-rw-r--r--   1 root root 6491364 Aug 16 18:33 Sn1per.gif
-rw-r--r--   1 root root  159147 Aug 16 18:33 Sn1per.jpg
drwxr-xr-x   2 root root    4096 Aug 16 18:33 bin
drwxr-xr-x   2 root root    4096 Aug 16 19:41 conf
rwxr-xr-x   1 root root   11548 Aug 16 18:33 install.sh
drwxr-xr-x   9 root root    4096 Aug 16 19:42 loot
drwxr-xr-x   2 root root    4096 Aug 16 18:33 modes
drwxr-xr-x  43 root root    4096 Aug 16 19:27 plugins
drwxr-xr-x   2 root root    4096 Aug 16 18:33 pro
-rw-r--r--   1 root root     276 Aug 16 18:33 sn1per.desktop
-rw-r--r--   1 root root    4283 Aug 16 18:33 sn1per.png
-rwxr-xr-x   1 root root   28290 Aug 16 18:33 sniper
-rw-r--r--   1 root root    9752 Aug 16 18:33 sniper.conf
drwxr-xr-x   4 root root    4096 Aug 16 18:33 templates
-rwxr-xr-x   1 root root     980 Aug 16 18:33 uninstall.sh
drwxr-xr-x   2 root root    4096 Aug 16 18:33 wordlists

모든 파일의 소유자가 root이지만, 포함하는 디렉터리의 권한으로 인해 파일을 조작할 수 있으므로 스크립트 중 하나에 백도어를 배치할 수 있습니다. 또 다른, 아마도 더 은밀한 수정 방법은 구성 파일(sniper.conf)에 백도어를 배치하는 것입니다. 이 파일은 bash source 명령으로 소싱되기 때문입니다.

애플리케이션은 root로 실행되어야 하며, 이는 스크립트의 EUID 검사를 통해 보장됩니다:

root@kitploit:~
if [[ $EUID -ne 0 ]]; then
   echo "This script must be run as root"
   exit 1
fi

여기에 백도어를 배치하면 다음에 애플리케이션이 사용될 때 root 권한으로 실행됩니다.

근본 원인

설치 스크립트의 37-40행:

root@kitploit:~
mkdir -p $INSTALL_DIR 2> /dev/null
chmod 777 -Rf $INSTALL_DIR 2> /dev/null
chown root $INSTALL_DIR/sniper 2> /dev/null
chmod 4777 $INSTALL_DIR/sniper 2> /dev/null

CVE-2021-39273

CVE-2021-39274와 다른 문제

애플리케이션을 처음 실행하면 스캐너 메인 스크립트 sniper가 init 함수를 실행하여 설치 디렉터리와 그 내용에 대한 권한을 재귀적으로 변경합니다.

_CVE-2021-39274_와 마찬가지로, 실행 파일과 구성을 포함한 모든 애플리케이션 파일을 수정할 수 있고, 그 안에 백도어를 배치하여 다음에 애플리케이션이 root에 의해 사용될 때 root 권한으로 실행되게 할 수 있습니다.

근본 원인

메인 스크립트의 464-466행:

root@kitploit:~
chmod 777 -Rf $INSTALL_DIR 2> /dev/null
chown root $INSTALL_DIR/sniper 2> /dev/null
chmod 4777 $INSTALL_DIR/sniper 2> /dev/null

발견자: Nikola Pepelishev, 2021년 8월

도구 다운로드