<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet href="/static/style.xsl" type="text/xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <id>https://vulnerability.circl.lu/rss/recent/all/10</id>
  <title>Most recent entries from all</title>
  <updated>2026-09-29T22:33:47.467807+00:00</updated>
  <author>
    <name>Vulnerability-Lookup</name>
    <email>info@circl.lu</email>
  </author>
  <link href="https://vulnerability.circl.lu" rel="alternate"/>
  <generator uri="https://lkiesow.github.io/python-feedgen" version="1.0.0">python-feedgen</generator>
  <subtitle>Contains only the most 10 recent entries.</subtitle>
  <entry>
    <id>https://vulnerability.circl.lu/vuln/ghsa-r275-fr43-pm7q</id>
    <title>GHSA-r275-fr43-pm7q — simple-git has blockUnsafeOperationsPlugin bypass via case-insensitive protocol.allow config key enables RCE</title>
    <updated>2026-09-29T22:33:47.470300+00:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml"><p><strong>Affected:</strong> npm: simple-git</p>
<p>### Summary</p>
<p>The `blockUnsafeOperationsPlugin` in `simple-git` fails to block git protocol
override arguments when the config key is passed in uppercase or mixed case.
An attacker who controls arguments passed to git operations can enable the
`ext::` protocol by passing `-c PROTOCOL.ALLOW=always`, which executes an
arbitrary OS command on the host machine.</p>
<p>---</p>
<p>### Details</p>
<p>The `preventProtocolOverride` function in
`simple-git/src/lib/plugins/block-unsafe-operations-plugin.ts` (line 24)
checks whether a `-c` argument configures `protocol.allow` using this regex:</p>
<p>```ts
if (!/^\s*protocol(.[a-z]+)?.allow/.test(next)) {
   return;
}
```</p>
<p>This regex is case-sensitive. Git treats config key names
case-insensitively — it normalises them to lowercase internally.
As a result, passing `PROTOCOL.ALLOW=always`, `Protocol.Allow=always`,
or any mixed-case variant is not matched by the regex, the check
returns without throwing, and git is spawned with the unsafe argument.</p>
<p>**Verification that git normalises the key:**</p>
<p>```bash
$ git -c PROTOCOL.ALLOW=always config --list | grep protocol
protocol.allow=always
```</p>
<p>**The fix is a single character — add the `/i` flag:**</p>
<p>```ts
// Before (vulnerable):
if (!/^\s*protocol(.[a-z]+)?.allow/.test(next)) {</p>
<p>// After (fixed):
if (!/^\s*protocol(.[a-z]+)?.allow/i.test(next)) {
```</p>
<p>---</p>
<p>## poc.js</p>
<p>```js
/**
 * Proof of Concept — simple-git preventProtocolOverride Case-Sensitivity Bypass
 *
 * CVE-2022-25912 was fixed in simple-git@3.15.0 by adding…</p></div>
    </content>
    <link href="https://vulnerability.circl.lu/vuln/ghsa-r275-fr43-pm7q"/>
  </entry>
</feed>
