CVE DatabaseCVE-2025-8110
한국어 권고문 →
CVE-2025-81108.8/HIGHCISA KEVCWE-22

Gogs Git Service PutContents API Symbolic Link Handling Remote Code Execution Vulnerability Analysis and Mitigation (CVE-2025-8110)

⚡ Jump to Patch
Affected Vendors
gogs
Affected Components
gogs
Published Date
2025-12-10
CVSS v3.1
8.8
HIGH
EPSS (30d)
85.2%
FIRST.org
CISA KEV
Exploited

Executive & SecOps Summary

SECOPS ASSESSMENT
Affected Scope

All active deployments of Gogs Git service utilizing the vulnerable PutContents API.

Impact

An authenticated attacker with low privileges can exploit improper symbolic link validation to overwrite arbitrary system files, leading to Remote Code Execution (RCE).

Mitigation

Immediately upgrade Gogs to the latest patched version and restrict repository creation and write permissions for untrusted users.

Affected Products & Version Scope

All Gogs deployments lacking the security patch that validates symbolic links during PutContents API operations.

Remediation & Live Workaround Commands

PATCH & WORKAROUND

1. Official Patch & Version Upgrade Commands

Check the official Gogs repository for the latest security release and upgrade your deployment immediately using the following commands.

bash
# For Docker-based Gogs deployments, pull the latest secure image and recreate the container
docker pull gogs/gogs:latest
docker stop gogs-container
docker run -d --name gogs-container-new -p 3000:3000 -v /var/gogs:/data gogs/gogs:latest

2. Temporary Workaround & Hardening Configuration

If patching cannot be applied immediately, restrict access to the vulnerable API endpoints using a reverse proxy such as Nginx.

nginx
# Block external access to the PutContents API endpoint via Nginx
server {
    listen 80;
    server_name gogs.internal.local;

    location ~* /api/v1/repos/.*/contents/.* {
        # Restrict access to trusted internal IP ranges only
        allow 10.0.0.0/8;
        deny all;
        proxy_pass http://localhost:3000;
    }
}

3. Log Audit & IoC Verification Commands

Run the following commands to inspect Gogs logs for suspicious API calls and scan the repository directory for unauthorized symbolic links.

bash
# Search Gogs logs for PutContents API calls and potential traversal attempts
grep -Ei 'putcontents|/contents/' /var/gogs/log/gogs.log

# Scan Gogs repositories for symbolic links pointing to sensitive system directories
find /var/gogs/data/gogs-repositories/ -type l -ls | grep -E '-> /etc/|-> /home/|-> /var/'
Interactive SecOps Remediation Checklist
0/4 (0%)
Recommended Security Control & Mitigation Partner
Cloudflare Enterprise & Pro WAF
Due to active exploitation (CISA KEV) and high EPSS score, immediately upgrade Gogs to the latest patched version and audit repositories for unauthorized symbolic links.

Block Exploits Instantly with Managed Virtual Patching Rules

Can't patch production immediately? Deploy managed WAF rules at the edge to intercept RCE, SQLi, and deserialization payloads before they hit your origin server.

3-min setup · Automated Zero-Day Managed Rules
Practice Exploiting & Patching This Web Vulnerability in an Interactive Lab
Launch Hands-On Security Lab

Technical Root Cause & Exploitation Mechanics

1. Vulnerability Overview & Root Cause

This vulnerability (CVE-2025-8110) is a path traversal (CWE-22) and improper symbolic link handling flaw within the PutContents API of Gogs, an open-source Git service. The root cause lies in the application's failure to properly validate whether the target file path of a write operation is a symbolic link pointing outside the intended repository directory. By exploiting this, an attacker can write arbitrary content to any file on the host system that the Gogs process has permissions to access.

2. Exploitation Mechanics & Attack Scenario

The exploitation flow typically proceeds as follows:

  • Symlink Creation: An authenticated attacker with repository write access (PR:L) creates a symbolic link pointing to a sensitive system file (e.g., /etc/cron.d/malicious or the Gogs user's .ssh/authorized_keys) and pushes it to their repository.
  • PutContents API Invocation: The attacker triggers the PutContents API (via the web UI or API endpoint) to modify the content of the symlinked file.
  • Arbitrary File Write & RCE: Because Gogs does not resolve or validate the symlink target, it writes the attacker-controlled payload directly to the target system path. This allows the attacker to register a malicious cron job or SSH key, achieving full Remote Code Execution (RCE).

3. Infrastructure & Business Impact

With a CVSS score of 8.8 (High) and active exploitation confirmed by its inclusion in the CISA KEV catalog, this vulnerability poses an immediate threat. The high EPSS score of 0.852 indicates a very high probability of exploitation in the wild. Successful exploitation allows complete compromise of the host operating system running Gogs, potentially leading to source code theft, supply chain attacks, and lateral movement within the internal network.

Official Vendor Advisories & References

Frequently Asked SecOps Questions (CVE-2025-8110)

FAQ

Q1. How critical is CVE-2025-8110 and is it actively exploited in the wild?

CVE-2025-8110 is rated CVSS 8.8 (HIGH) with a 30-day EPSS exploitation probability of 85.2%. It is listed in the CISA Known Exploited Vulnerabilities (KEV) catalog, requiring immediate emergency remediation.

Q2. Which vendors and products are affected by CVE-2025-8110?

Primary impacted vendors include gogs across gogs. Scope summary: All Gogs deployments lacking the security patch that validates symbolic links during PutContents API operations.

Q3. What temporary mitigations or workarounds exist for CVE-2025-8110 before patching?

[Mitigation] Immediately upgrade Gogs to the latest patched version and restrict repository creation and write permissions for untrusted users. Follow the CLI remediation commands and interactive SecOps checklist on this page to restrict exposure prior to your maintenance window.

SECOPS WORKBENCH INTEGRATION

Generate an Internal Engineering Notice or CISO Report for CVE-2025-8110

Instantly format this advisory into an executive CISO summary or engineering patch ticket.

Generate Report →

🔗 Related Advisories in Similar Stack (gogs)

View Category →
SecOps Advisory Dispatch & RSS Feed

Subscribe to Daily Vulnerability Briefings & KEV Alerts

Concise morning briefings for SecOps, DevSecOps, and SRE teams covering newly exploited CVEs and mitigation priorities.

Slack / Teams / RSS Feed:
PatchKO
CVE-2025-8110 Gogs Git Service PutContents API Symbolic Link Handling Remote Code Execution Vulnerability Analysis and Mitigation (CVE-2025-8110) (CVSS 8.8) - Patch & Workaround | CVE Pulse