Citrix NFuse — 1 vulnerability check
noctis ships 1 vulnerability check for Citrix NFuse, covering 1 CVE; each one has to observe the bug on the live service before it reports a finding.
← All products · Feeds on GitHub
Citrix NFuse NFuse_Application parameter cross-site scripting
| CVE | CVE-2002-0504 |
|---|---|
| Severity | high · CVSS 7.5 |
| Category | xss — XSS |
| Services | http, https |
| Detection | script, set_var, http_request, match · highest QoD 75 |
| Feed | tests/vulnerabilities/citrix-nfuse/CVE-2002-0504.yaml |
Citrix NFuse 1.6 and earlier, the web portal that publishes MetaFrame applications, returns the error for an unknown application named in the NFuse_Application parameter of launch.asp or launch.jsp without HTML encoding, so a crafted link runs attacker script in the browser of a portal user who follows it, in the context of the portal site.
Under the web root, /NFuse, /nfuse and /Citrix/NFuse, this check requests launch.asp and launch.jsp with an application name made of a script element carrying a random marker. The flaw is confirmed when the page returns that script element unescaped, and a random page of the same directory, given the same parameter, answers without it (which rules out servers that echo any URL).
How noctis detects it
- Parses / computes the next value with a Rhai script
- HTTP(S) request
GET {{v.d}}/{{v.page}}.{{v.ext}}?NFuse_Application={{sc.p}} - Parses / computes the next value with a Rhai script
- HTTP(S) request
GET {{v.d}}/{{sc.ctl}}.{{v.ext}}?NFuse_Application={{sc.p}} - Parses / computes the next value with a Rhai script
- Checks
hitfor/launch\.(asp|jsp)\?NFuse_Application=→ finding QoD 75: Citrix NFuse NFuse_Application parameter cross-site scripting (CVE-2002-0504)
References:
- https://nvd.nist.gov/vuln/detail/CVE-2002-0504
- http://www.securityfocus.com/bid/4372
- https://www.exploit-db.com/exploits/21355
Feed source — tests/vulnerabilities/citrix-nfuse/CVE-2002-0504.yaml
# Citrix NFuse — NFuse_Application parameter reflected cross-site scripting (CVE-2002-0504).
#
# Citrix NFuse 1.6 and earlier (application portal for MetaFrame, ASP or JSP pages
# on the customer's web server) prints the error returned by getLastError() for
# the NFuse_Application parameter of launch.asp / launch.jsp without HTML
# encoding, so a script element passed as the application name comes back
# verbatim (BID 4372, EDB-21355: launch.jsp?NFuse_Application=<script>...).
#
# Detection (QoD 75): launch.asp and launch.jsp are requested under the web root
# (the NFuse 1.x default), /NFuse, /nfuse and /Citrix/NFuse with
# NFuse_Application=<script>alert(/noctis<random>/)</script>. The flaw is
# confirmed when the reply carries the script element verbatim and a random
# page of the same directory and extension, given the same query, answers
# (not 429/5xx, no transport error) without it — servers that echo any URL raw,
# or whose control request fails, are not reported.
#
# Ported from OpenVAS/Greenbone NVT `pre2008/citrix_xss.nasl`
# (OID 1.3.6.1.4.1.25623.1.0.14626, GPL-2.0-only): /launch.jsp and /launch.asp
# at the web root with the static `>alert(document.cookie);</script>` value,
# skipped when the host reflects XSS generically. Differences: random marker in
# a complete script element (the advisory payload), three more install
# directories, and the generic reflection control is done per directory with
# the same query instead of host-wide.
# CVSS: NVD carries only a CVSS v2 score (7.5).
uid: b904626b-c1aa-4b16-b4d2-e0e0b7377db2
name: "Citrix NFuse NFuse_Application parameter cross-site scripting (CVE-2002-0504)"
description: |
Citrix NFuse 1.6 and earlier, the web portal that publishes MetaFrame
applications, returns the error for an unknown application named in the
NFuse_Application parameter of launch.asp or launch.jsp without HTML
encoding, so a crafted link runs attacker script in the browser of a portal
user who follows it, in the context of the portal site.
Under the web root, /NFuse, /nfuse and /Citrix/NFuse, this check requests
launch.asp and launch.jsp with an application name made of a script element
carrying a random marker. The flaw is confirmed when the page returns that
script element unescaped, and a random page of the same directory, given the
same parameter, answers without it (which rules out servers that echo any
URL).
cves: [CVE-2002-0504]
cvss: 7.5
severity: high
category: xss
confidence_base: 0.30
tags: [citrix, nfuse, metaframe, portal, asp, jsp, xss, reflected]
services: [http, https]
author: noctis
version: "1.0.0"
references:
- "https://nvd.nist.gov/vuln/detail/CVE-2002-0504"
- "http://www.securityfocus.com/bid/4372"
- "https://www.exploit-db.com/exploits/21355"
steps:
- id: gen-marker
action: script
code: |
let tok = "noctis" + rand_int(10000000, 99999999);
#{ tok: tok,
want: "<script>alert(/" + tok + "/)</script>",
p: "%3Cscript%3Ealert%28%2F" + tok + "%2F%29%3C%2Fscript%3E",
ctl: "noctis" + rand_hex(6) }
store_as: sc
- id: init-hit
action: set_var
var_name: hit
var_value: ""
# ── Per install dir × page (loop group) ───────────────────────────────────
- id: init-r
action: set_var
var_name: r
var_value: {status: 0, body: ""}
loop:
var: v
over:
- {d: "", page: "launch", ext: "asp"}
- {d: "", page: "launch", ext: "jsp"}
- {d: "/NFuse", page: "launch", ext: "asp"}
- {d: "/NFuse", page: "launch", ext: "jsp"}
- {d: "/nfuse", page: "launch", ext: "asp"}
- {d: "/nfuse", page: "launch", ext: "jsp"}
- {d: "/Citrix/NFuse", page: "launch", ext: "asp"}
- {d: "/Citrix/NFuse", page: "launch", ext: "jsp"}
- id: init-c
action: set_var
var_name: c
var_value: {status: 0, body: ""}
- id: probe
action: http_request
method: GET
path: "{{v.d}}/{{v.page}}.{{v.ext}}?NFuse_Application={{sc.p}}"
port: "{{port}}"
tls_insecure: true
follow_redirects: false
timeout_secs: 5
condition: 'hit == ""'
store_as: r
- id: check-probe
action: script
condition: 'hit == ""'
code: |
let b = if type_of(r.body) == "string" { r.body } else { "" };
r.status >= 200 && b.contains(sc.want)
store_as: reflected
# Generic-reflection control: same query on a random page of the directory.
- id: control
action: http_request
method: GET
path: "{{v.d}}/{{sc.ctl}}.{{v.ext}}?NFuse_Application={{sc.p}}"
port: "{{port}}"
tls_insecure: true
follow_redirects: false
timeout_secs: 5
condition: 'hit == "" && reflected'
store_as: c
- id: check
action: script
condition: 'hit == ""'
code: |
let cb = if type_of(c.body) == "string" { c.body } else { "" };
let ok = c.status > 0 && c.status != 429 && c.status < 500;
if reflected && ok && !cb.contains(sc.want) { v.d + "/" + v.page + "." + v.ext + "?NFuse_Application=" } else { "" }
store_as: hit
# ── Finding ───────────────────────────────────────────────────────────────
- id: report
action: match
source: hit
pattern: "/launch\\.(asp|jsp)\\?NFuse_Application="
condition: 'hit != ""'
on_match:
finding:
title: "Citrix NFuse NFuse_Application parameter cross-site scripting (CVE-2002-0504)"
description: "Citrix NFuse returned a script element passed as the NFuse_Application parameter without HTML encoding: a crafted link runs attacker script in the browser of a portal user who follows it, in the context of the NFuse site, and can steal the user's session cookie."
remediation: "Upgrade Citrix NFuse to a release later than 1.6 (NFuse Classic / Web Interface), which HTML-encodes the launch error message, or remove the NFuse 1.x pages: the product is no longer supported."
confidence_delta: 0.50
qod: 75
evidence: "{{hit}} returned {{sc.want}} unescaped (HTTP {{r.status}}); a random page of the same directory did not reflect it"
stop: true