Skip to content
OpenAdvisories
High · 7.5 Public exploit CVE-2022-30781 BIT-gitea-2022-30781EUVD-2022-4684GHSA-p5f9-c9j9-g8qxGO-2022-0450

Shell command injection in gitea

Published May 16, 2022 · Updated Aug 3, 2024 · Assigned by mitre

Description

Gitea before 1.16.7 does not escape git fetch remote.

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Alpine v3.24 gitea 1.16.7-r0 —
Alpine v3.23 gitea 1.16.7-r0 —
Alpine v3.22 gitea 1.16.7-r0 —
Alpine v3.21 gitea 1.16.7-r0 —
Alpine v3.20 gitea 1.16.7-r0 —
Show 4 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Alpine v3.19 gitea 1.16.7-r0 —
Alpine v3.18 gitea 1.16.7-r0 —
Alpine v3.17 gitea 1.16.7-r0 —
Alpine v3.16 gitea 1.16.7-r0 —

Public exploits

Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.

Third-party code, not reviewed by us. Public PoCs are sometimes fake or contain malware. Read the code first and run it only in an isolated lab, against systems you are authorised to test.

Metasploit 1 module

Exploit-DB 1

GitHub 2 repositories

Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.

Affected packages

EcosystemPackageAffectedFixedRecord
Go code.gitea.io/gitea < 1.16.7 1.16.7 GHSA-p5f9-c9j9-g8qx

References