Dmanager — 1 vulnerability check
noctis ships 1 vulnerability check for Dmanager, covering 1 CVE; each one has to observe the bug on the live service before it reports a finding.
← All products · Feeds on GitHub
Document Manager < 4.0 file rights vulnerability
| CVE | CVE-2010-0612 |
|---|---|
| Severity | high · CVSS 7.5 |
| Category | exposure — Exposure |
| Services | http, https |
| Detection | set_var, http_request, script, match · highest QoD 70 |
| Feed | tests/vulnerabilities/dmanager/CVE-2010-0612.yaml |
Document Manager (dmanager, "Porte Documents"), a PHP web file organiser, has a flaw in how it handles file rights in every release before 4.0; the details were never published, so no request can prove it, and this check identifies the version instead.
On the web root and the usual install paths (/dmanager, /DocManager, /docmanager) it requests php/login.php and accepts the page as Document Manager when it answers 200 and names "Document Manager" or "Porte Documents". It reads the version from that page ("version X.Y"), or else from the short php/version file, and reports a version lower than 4.0, with a lower confidence than an exploit proof.
How noctis detects it
- HTTP(S) request
GET {{dir}}/php/login.php - Parses / computes the next value with a Rhai script
- HTTP(S) request
GET {{dir}}/php/version - Parses / computes the next value with a Rhai script
- Checks
hitforruns Document Manager→ finding QoD 70: Document Manager < 4.0 file rights vulnerability (CVE-2010-0612)
References:
- https://nvd.nist.gov/vuln/detail/CVE-2010-0612
- http://secunia.com/advisories/38441
- http://freshmeat.net/projects/dmanager/releases/311735
- https://linuxfr.org/news/document-manager-sort-en-version-4
Feed source — tests/vulnerabilities/dmanager/CVE-2010-0612.yaml
# Document Manager (dmanager, "Porte Documents") before 4.0 — unspecified
# flaw related to file rights, CVE-2010-0612.
#
# Why version only (QoD 70): the CVE record says "unspecified vulnerability ...
# related to file rights", Secunia SA38441 and the 4.0 release note
# (freshmeat release 311735, LinuxFr news of 2010-02-01) name no page or
# parameter, and the project site (dmanager.org) with its tarballs is gone, so
# no request can prove the flaw. The check reads the version the application
# shows.
#
# Ported from OpenVAS/Greenbone NVT `2010/gb_document_manager_info_disc_vuln.nasl`
# (OID 1.3.6.1.4.1.25623.1.0.800478, GPL-2.0-only) and its detection
# `gb_document_manager_detect.nasl`: for /, /dmanager and the CGI dirs, GET
# <dir>/php/login.php; the page is Document Manager when it contains
# "Document Manager" or "Porte Documents"; version from "version ([0-9.]+)"
# in that reply, else from "([0-9.]+)" in the body of <dir>/php/version;
# reports version < 4.0.
# Differences from the NASL:
# - the login page must answer 200 (the NASL also read error pages);
# - the version is read first right after the product name
# ("Document Manager ... version X", same tag), so another component's
# "version N" earlier in the page (jQuery, PHP) is not taken; else the
# first "version N" as the NASL does; it needs a digit first, so
# "version ." is not read as a version;
# - the /php/version fallback must answer 200 with a short body that starts
# with the version number: the NASL took the first digits of any reply, so
# a site answering every path with a 200 page (or a 404 page) holding a
# number such as "1.1" or "2009" gave a wrong version;
# - also tries /DocManager and /docmanager; version components are capped at
# 6 digits (int() overflows on longer runs).
# The login page markup is not documented anywhere reachable; the mock pages
# are reconstructions that only carry the strings the detection relies on.
#
# CVSS: NVD carries only a CVSS v2 score (7.5, AV:N/AC:L/Au:N/C:P/I:P/A:P).
uid: 90c0976b-3f0c-44e6-87de-8c9438858fc5
name: "Document Manager < 4.0 file rights vulnerability (CVE-2010-0612)"
description: |
Document Manager (dmanager, "Porte Documents"), a PHP web file organiser,
has a flaw in how it handles file rights in every release before 4.0; the
details were never published, so no request can prove it, and this check
identifies the version instead.
On the web root and the usual install paths (/dmanager, /DocManager,
/docmanager) it requests php/login.php and accepts the page as Document
Manager when it answers 200 and names "Document Manager" or
"Porte Documents". It reads the version from that page ("version X.Y"),
or else from the short php/version file, and reports a version lower than
4.0, with a lower confidence than an exploit proof.
cves: [CVE-2010-0612]
cvss: 7.5
severity: high
category: exposure
confidence_base: 0.30
tags: [dmanager, document-manager, php, file-rights, version-check]
services: [http, https]
author: noctis
version: "1.0.0"
references:
- "https://nvd.nist.gov/vuln/detail/CVE-2010-0612"
- "http://secunia.com/advisories/38441"
- "http://freshmeat.net/projects/dmanager/releases/311735"
- "https://linuxfr.org/news/document-manager-sort-en-version-4"
steps:
- id: init-hit
action: set_var
var_name: hit
var_value: ""
- id: init-dmver
action: set_var
var_name: dmver
var_value: ""
# ── Per candidate install path (loop group) ───────────────────────────────
- id: init-login
action: set_var
var_name: login
var_value: {status: 0, body: ""}
loop:
var: dir
over: ["", "/dmanager", "/DocManager", "/docmanager"]
- id: init-vfile
action: set_var
var_name: vfile
var_value: {status: 0, body: ""}
- id: fetch-login
action: http_request
method: GET
path: "{{dir}}/php/login.php"
port: "{{port}}"
tls_insecure: true
timeout_secs: 15
condition: 'hit == ""'
store_as: login
# Product gate + version from the login page.
# "" = not Document Manager, "?" = Document Manager without a version on the
# login page, else the version.
- id: parse-login
action: script
condition: 'hit == ""'
code: |
let b = if type_of(login.body) == "string" { login.body } else { "" };
let out = "";
if login.status == 200 && (b.contains("Document Manager") || b.contains("Porte Documents")) {
out = "?";
let m = eregmatch("(?:Document Manager|Porte Documents)[^<]{0,60}?version ([0-9]{1,6}(?:\\.[0-9]{1,6})*)", b);
if !(type_of(m) == "array" && m.len() > 1) {
m = eregmatch("version ([0-9]{1,6}(?:\\.[0-9]{1,6})*)", b);
}
if type_of(m) == "array" && m.len() > 1 { out = m[1]; }
}
out
store_as: dmver
- id: fetch-version-file
action: http_request
method: GET
path: "{{dir}}/php/version"
port: "{{port}}"
tls_insecure: true
timeout_secs: 15
condition: 'hit == "" && dmver == "?"'
store_as: vfile
# Version (login page, else php/version) < 4.0, numeric per component.
- id: check-version
action: script
condition: 'hit == "" && dmver != ""'
code: |
let ver = dmver;
let how = "\"version " + dmver + "\" on " + dir + "/php/login.php";
if ver == "?" {
ver = "";
let vb = if type_of(vfile.body) == "string" { vfile.body } else { "" };
if vfile.status == 200 && vb.len() < 64 {
let m = eregmatch("^\\s*([0-9]{1,6}(?:\\.[0-9]{1,6})*)", vb);
if type_of(m) == "array" && m.len() > 1 {
ver = m[1];
how = "\"" + ver + "\" in " + dir + "/php/version";
}
}
}
let out = "";
if ver != "" {
let p = split(ver, ".");
let a = int(p[0]);
if a < 4 {
out = dir + "/php/login.php runs Document Manager " + ver + " (" + how + ")";
}
}
out
store_as: hit
# ── Finding ───────────────────────────────────────────────────────────────
- id: report
action: match
source: hit
pattern: "runs Document Manager"
on_match:
finding:
title: "Document Manager < 4.0 file rights vulnerability (CVE-2010-0612)"
description: "The site runs Document Manager (dmanager) older than 4.0. These releases have an unspecified flaw related to file rights that can expose documents to remote attackers. Detected from the version only; the details of the flaw were never published."
remediation: "Upgrade Document Manager to 4.0 or later."
confidence_delta: 0.45
qod: 70
evidence: "{{hit}}; fixed in 4.0"
stop: true