3690 - Svn
💡 学习提示: 本文档介绍 3690 - Subversion SVN 的渗透测试方法,适合信息安全初学者和从业人员参考。
⚠️ 法律声明: 本文档仅供学习和授权测试使用。未经授权的系统测试可能违反法律法规。
⚠️ 法律声明: 本文档仅供学习和授权测试使用。未经授权的系统测试可能违反法律法规。
3690/tcp - 渗透测试 Subversion (SVN) 服务器
基本信息
Subversion (SVN) is a centralized version control system (Apache license) used for software versioning and revision control.
默认 port: 3690/tcp (svnserve). It can also be exposed via HTTP/HTTPS through mod_dav_svn and via svn+ssh.
Banner Grabbing
信息收集
Auth & Misconfig Hunting
svnserve.confmay allowanon-access = read(or even write). If you can list, trycheckoutto dump secrets, scripts, CI tokens.- Repositories frequently store build pipelines, deployment keys, and database credentials in versioned config files. Grep the working copy after checkout:
grep -R "password\|secret\|token" -n .. - If svn+ssh is enabled, user shells often allow restricted
svnservecommands; attemptssh user@host svnserve -twith crafted subcommands to bypass wrappers.
Bruteforcing credentials (svnserve)
sasl authentication (if enabled) and simple password files are protected only by the transport; no lockout by default. A quick Bash loop can try credentials:
Recent Vulnerabilities (practical impact)
mod_dav_svn 拒绝服务 via control characters (CVE-2024-46901)
- A user with commit rights can write a path containing control chars (e.g.
\x01,\x7f) that corrupts the repository, making later checkouts/logs fail and potentially crashingmod_dav_svnworkers. - Affects Subversion ≤ 1.14.4 when served through HTTP(S) (
mod_dav_svn). Fixed in 1.14.5. - PoC commit with
svnmucc(requires valid commit creds):
- After the commit, normal clients may crash or refuse updates until admins manually remove the revision with
svnadmin dump/filter/load.
Windows argument injection in svn client (CVE-2024-45720)
- On Windows, “best-fit” character encoding in
svn.exeallows command-line argument injection when processing specially crafted non‑ASCII paths/URLs, potentially leading to arbitrary program execution. - Affects Subversion ≤ 1.14.3 on Windows only; fixed in 1.14.4. 攻击 surface: phishing a developer to run
svnon an attacker-controlled URL/path. - Pentest angle: if you control a network share or ZIP given to a Windows dev, name a repo URL or working-copy path containing best-fit bytes that decode into
" & calc.exe & "-style injected args, then trick the victim to runsvn statusor similar on that path.
Notes for 漏洞利用 Workflow
- Check access method:
svn://(svnserve),http(s)://.../svn/(mod_dav_svn), orsvn+ssh://. - Try anonymous read first; then spray common creds. If HTTP Basic is used, reuse creds found elsewhere.
- Enumerate hooks:
hooks/pre-commit,post-commitscripts sometimes contain plaintext credentials or hostnames. - Leverage
svn:externalsto pull additional paths from other hosts; list them withsvn propget svn:externals -R .after checkout. - Version leaks: HTTP response headers from
mod_dav_svnusually show the Subversion & Apache version; compare against 1.14.5 to spot vuln targets. - If you obtain filesystem access to the repo,
svnadmin dump/svnlook author/svnlook dirs-changedallow offline analysis without credentials.