Cybersecurity news

Jessica Doner

Back to the list

Authenticated RCE via Argument Injection in Gogs (NOT FIXED)

Rapid7,

A critical vulnerability in Gogs lets authenticated users execute remote code by injecting a flag into a pull request branch name.

Vulnerabilities and patches

Overview

Rapid7 Labs found a critical vulnerabilityA flaw in software or hardware that lets an attacker do something the maker did not intend in Gogs, a popular open-sourceSoftware whose source code is publicly available for anyone to inspect, use, modify, and share self-hostedSoftware that an organization installs and runs on its own servers instead of using a vendor's cloud service Git service. This flaw allows any authenticated userA person or account that has already signed in with valid credentials to execute remote code on the serverA computer or program on a network that stores data and responds to requests from client devices by creating a pull requestA proposed set of code changes submitted to a software repository for maintainers to review and merge with a malicious branch name. The vulnerability works by injecting the --exec flag into git rebase during the merge operation. Because Gogs ships with open registration enabled by default, an unauthenticated attackerDone without logging in or holding a valid account on the target system can simply create an account and repositoryA central storage place where a software project's source code, change history, and configuration files are kept on any default-configured instance. The exploitA piece of code or technique that uses a software flaw to break into or crash a system requires no admin privilegesThe highest permission level on a computer or network, allowing full control over software and settings and no interaction with other users, allowing the attacker to operate entirely within their own account. The result is arbitrary command executionA flaw that lets an attacker run any commands or program they choose on the target machine as the Gogs server process user, giving the attacker the ability to compromise the server and read every repository on the instance.

Terms in this story

vulnerability
A flaw in software or hardware that lets an attacker do something the maker did not intend. Security advisories report a vulnerability when researchers or attackers find a coding mistake in an app or server that allows someone to break in or crash it. Security+ objective 2.3 lists the term
open-source
Software whose source code is publicly available for anyone to inspect, use, modify, and share. Most websites and apps rely on hundreds of open-source code libraries, so a single security flaw or malicious update in a popular library can affect thousands of companies at once.
self-hosted
Software that an organization installs and runs on its own servers instead of using a vendor's cloud service. Running a self-hosted password manager, code server, or chat platform gives a company full control over its data, but also means its own staff must install every security patch.
authenticated user
A person or account that has already signed in with valid credentials. Some vulnerabilities cannot be triggered by a stranger on the internet and instead require an authenticated user who already holds at least a basic account on the system.
server
A computer or program on a network that stores data and responds to requests from client devices. Online stores, email systems, and multiplayer games all run on servers in data centers or the cloud, making unpatched servers a primary target for intruders.
pull request
A proposed set of code changes submitted to a software repository for maintainers to review and merge. In open-source security news, attackers sometimes submit a normal-looking pull request that hides a backdoor or exploits the project's automated test pipeline.
unauthenticated attacker
Done without logging in or holding a valid account on the target system. An unauthenticated flaw is especially urgent in the news because any stranger on the internet can trigger it without needing a username or password first.
repository
A central storage place where a software project's source code, change history, and configuration files are kept. Software teams collaborate by pushing code to a shared repository, and attackers scan public repositories for accidentally committed API keys or try to poison popular projects.
exploit
A piece of code or technique that uses a software flaw to break into or crash a system. Finding a vulnerability is only the discovery of a weakness, whereas an exploit is the working code or sequence of inputs that triggers that weakness in practice. Security+ objective 2.4 lists the term
admin privileges
The highest permission level on a computer or network, allowing full control over software and settings. Attackers try to steal accounts with administrative privileges because those accounts can turn off antivirus tools, read any file, and install malware across the network.
privileges
The level of authority an account or process has to change settings, read files, or run commands. Ordinary user accounts run with limited privileges so a single mistake cannot break the operating system, whereas administrator privileges allow installing drivers and viewing all files.
arbitrary command execution
A flaw that lets an attacker run any commands or program they choose on the target machine. When an advisory warns that a bug allows arbitrary code execution, an attacker who triggers the flaw can install malware, read files, or take over the program's account.

This page is a short description made for this site. The article itself, with its author's name and its own link, is on the Rapid7 website. Cite the article, not this page.

Read the full article on Rapid7 (opens in a new tab)

Course connections

Each line below connects this story to a Security+ objective (a skill on CompTIA's Security+ exam, a common first cybersecurity certification), a CYBR 101 week, or a cybersecurity job, and quotes the words that made the connection.

How a story is connected to the course, and every objective, week and job role

Same story at other outlets

Related