Загрузка...

Git Push to RCE Inside CVE-2026-3854

**This single Git push could have taken down GitHub.** A crafted `git push --push-option` with hidden characters, and within minutes, an attacker with write access to any repo could execute arbitrary code on GitHub’s servers. That’s the reality of CVE-2026-3854—a critical 8.7 CVSS vulnerability discovered by Wiz researchers in March 2026. In this video, we break down the entire attack chain: metadata injection, environment rewriting, and sandbox escape that led to full RCE on GitHub.com and GitHub Enterprise Server. Watch until the end to see how GitHub patched it in under two hours and what GHES admins must check today.

**🔐 The Vulnerability Snapshot**
CVE-2026-3854 earned a CVSS score of 8.7 (High) due to its ease of exploitation and massive impact. Reported by Wiz via Bug Bounty on March 4, 2026, GitHub confirmed the issue in just 40 minutes and deployed a patch on GitHub.com in under two hours. The flaw affected all GitHub platforms: github.com, GitHub Enterprise Cloud, and GitHub Enterprise Server (GHES). With basic write access to any repository—including one you create yourself—an attacker could push a malicious option that triggers arbitrary code execution on the server processing the push. For GHES, that meant full server compromise and theft of secrets. For github.com’s shared infrastructure, it risked cross-tenant data exposure affecting millions of repositories.

**🔍 Root Cause: Metadata Injection**
The vulnerability lies in how GitHub’s internal services handle Git push options. Git allows users to pass custom strings via `--push-option` flags. GitHub’s backend then passes this metadata between internal services using a structured format with specific delimiters. The bug? The code failed to sanitize user input against those internal delimiters. By embedding the delimiter characters directly into a push option, an attacker could “break out” of the user data field. The parser then misinterpreted the injected string as trusted internal configuration parameters. This is a classic injection flaw, but in a context most developers never think about.

**⚙️ Attack Chain: From Input to Execution**
The Wiz research team demonstrated a multi-step injection exploit.
1. **Flag Injection:** Craft a push option containing newline-like or delimiter characters to add malicious configuration fields.
2. **Environment Rewriting:** Inject `rails_env` to force the backend process into a non-production Rails environment with relaxed security controls. Then overwrite `custom_hooks_dir` to redirect the server to load Git hooks from an attacker-controlled path instead of the legitimate directory.
3. **Path Traversal in Hooks:** Exploit `repo_pre_receive_hooks` combined with path traversal to point execution flow toward malicious scripts.
4. **Sandbox Escape:** Chaining these overwrites allows execution to break out of the restricted hook execution environment, achieving full RCE on the host.

This isn’t just theoretical—GitHub confirmed all instances of the abnormal code paths during the investigation matched Wiz researcher activity. On github.com’s shared node architecture, code execution on one node could potentially access millions of public and private repositories. On self-hosted GHES, the attacker would gain complete control over the appliance and all stored source code.

**🛡️ Remediation & Patch Analysis**
GitHub immediately implemented two mitigations:
- **Input Sanitization:** Stricter filtering of user-supplied push options to neutralize internal delimiters.
- **Code Path Removal:** Engineers removed the unnecessary code paths that were exploitable in non-production Rails environments. These paths existed due to a deployment model migration where old exclusion logic was not maintained.

Patching timeline:
- GitHub.com / Cloud: Patched automatically on March 4, 2026.
- GHES Versions: Manual updates required to versions 3.14.25+, 3.15.20+, 3.16.16+, 3.17.13+, 3.18.7+, 3.19.4+, or 3.20.0+.

For GHES admins, GitHub recommended auditing `/var/log/github-audit.log` for any push options containing semicolons (`;`) as a potential indicator of injection attempts.

**💡 What This Means for Developers and Security Teams**
This case highlights that even the most trusted infrastructure components—like Git’s push mechanics—can become attack vectors. It’s a reminder that input sanitization must extend beyond the application layer into internal metadata handling. And for organizations running GHES, staying current with patches is not negotiable.

**🔔 Turn on notifications** so you never miss a breakdown of the next major CVE.

#CVE20263854 #GitPush #RCE #GitHubSecurity #GitHubVulnerability #WizResearch #BugBounty #Infosec #CyberSecurity #GitHubEnterprise #GHES #GitHooks #InputInjection #SandboxEscape #ExploitChain #VulnerabilityResearch #PatchManagement #SecurityAnalysis #DevSecOps #ZeroDay #CriticalVulnerability

Видео Git Push to RCE Inside CVE-2026-3854 канала SecureTechIn
Яндекс.Метрика
Все заметки Новая заметка Страницу в заметки
Страницу в закладки Мои закладки
На информационно-развлекательном портале SALDA.WS применяются cookie-файлы. Нажимая кнопку Принять, вы подтверждаете свое согласие на их использование.
О CookiesНапомнить позжеПринять