Philips In.Sight — 1 vulnerability check
noctis ships 1 vulnerability check for Philips In.Sight, covering 1 CVE; each one has to observe the bug on the live service before it reports a finding.
← All products · Feeds on GitHub
Philips In.Sight Camera Hard-Coded Telnet Credentials
| CVE | CVE-2015-2882 |
|---|---|
| Severity | critical · CVSS 9.8 |
| Category | default-credentials — Default credentials |
| Services | telnet |
| Detection | script, set_var, tcp_open, sleep, tcp_send, tcp_close, match · highest QoD 97 |
| Feed | tests/vulnerabilities/philips-insight/CVE-2015-2882.yaml |
Philips In.Sight B120/37 wireless video baby monitors ship a Telnet console with hard-coded accounts (CVE-2015-2882). The check requires the "insight login" greeting, then logs in as root (password b120root, then insightr), admin (password /ADMIN/) and mg3500 (password merlin). A login is confirmed when the shell computes the sum of two random numbers sent in an `echo` command, and only when a random password for the same user is refused. When the sum is not printed but a shell prompt came back, the login is reported with a lower confidence.
How noctis detects it
- Parses / computes the next value with a Rhai script
- Opens a persistent TCP/TLS socket
- Sends
…on the open socket - Parses / computes the next value with a Rhai script
- Sends
{{acct.user}}on the open socket - Sends
…on the open socket - Parses / computes the next value with a Rhai script
- Sends
{{acct.pass}}on the open socket - Sends
echo NOCTIS$(({{proof.a}}+{{proof.b}}))U$(id -u)Zon the open socket - Sends
…on the open socket - Parses / computes the next value with a Rhai script
- Sends
…on the open socket - Parses / computes the next value with a Rhai script
- Parses / computes the next value with a Rhai script
- … and 15 more steps — see the feed source below
References:
- https://nvd.nist.gov/vuln/detail/CVE-2015-2882
- https://www.rapid7.com/blog/post/2015/09/02/iotsec-disclosure-10-new-vulns-for-several-video-baby-monitors/
Feed source — tests/vulnerabilities/philips-insight/CVE-2015-2882.yaml
# Philips In.Sight B120/37 baby monitor camera — hard-coded Telnet accounts
# (CVE-2015-2882).
#
# Credit: detection logic adapted from the OpenVAS/Greenbone NVT
# 2016/sw_philips_insight_default_telnet_credentials.nasl
# (OID 1.3.6.1.4.1.25623.1.0.111096, GPL-2.0-only): require "insight login"
# in the Telnet greeting, then for each of root:b120root, root:insightr,
# admin:/ADMIN/ and mg3500:merlin send the user, require "Password:", send
# the password, run `cat /etc/passwd` and report on a passwd line.
# Accounts from the Rapid7 IoTSec disclosure (R7-2015-12, Sep 2015).
#
# Deviations from the NASL (stronger detection, documented in the PR):
# * Proof: instead of `cat /etc/passwd` (whose "root:x:0:0" text a banner
# or a fake shell can carry, and which reads a system file), the shell
# must evaluate `echo NOCTIS$((a+b))U$(id -u)Z` with two random integers
# and print the sum, which never appears in what we send (QoD 97).
# * Accept-any-password guard: after a successful login, a second login
# with the same user and a random password is made; when it also reaches
# the shell (honeypot, broken login), the feed reports nothing. QoD 97
# needs login(1) to actually reject it ("Login incorrect" or a new
# "insight login:" prompt); when the control gives no clear answer
# (refused, very slow), the arithmetic proof is reported at QoD 75.
# * Prompt-only fallback (QoD 75): the login reached a "#"/"$" shell prompt
# but the echo output was not captured, and the random password was
# rejected.
# * Slow devices: a greeting, "Password:" prompt or shell output that
# misses the first 500 ms read window is read again after a pause (the
# NASL gives up on the account instead).
# * The NASL's greeting test is unanchored ("insight login" also matches
# e.g. "hindsight login:"); the gate here requires a word boundary.
#
# Nothing is changed on the device: only `echo` and `id -u` run. At most one
# wrong-password login (the control) is made, and only after a hard-coded
# login already worked. category: default-credentials so operators can
# exclude credential logins.
uid: 3644bf0f-2406-41cf-b08c-bbd84a15e008
name: "Philips In.Sight Camera Hard-Coded Telnet Credentials"
description: |
Philips In.Sight B120/37 wireless video baby monitors ship a Telnet console
with hard-coded accounts (CVE-2015-2882). The check requires the
"insight login" greeting, then logs in as root (password b120root, then
insightr), admin (password /ADMIN/) and mg3500 (password merlin). A login
is confirmed when the shell computes the sum of two random numbers sent in
an `echo` command, and only when a random password for the same user is
refused. When the sum is not printed but a shell prompt came back, the
login is reported with a lower confidence.
cves: [CVE-2015-2882]
cvss: 9.8
severity: critical
category: default-credentials
confidence_base: 0.30
tags: [philips, insight, baby-monitor, ip-camera, iot, telnet, default-credentials, hardcoded-credentials, intrusive]
services: [telnet]
author: noctis
version: "1.0.0"
references:
- "https://nvd.nist.gov/vuln/detail/CVE-2015-2882"
- "https://www.rapid7.com/blog/post/2015/09/02/iotsec-disclosure-10-new-vulns-for-several-video-baby-monitors/"
steps:
# Random control password and the shell arithmetic proof.
- id: gen-proof
action: script
store_as: proof
code: |
let a = rand_int(100000, 999999);
let b = rand_int(100000, 999999);
#{ a: "" + a, b: "" + b, marker: "NOCTIS" + (a + b), ctl_pw: "noctis" + rand_str(14) }
# ------------------------------------------- one iteration per account
# The whole group below runs once per pair; a finding (stop: true) ends it.
- id: init-gate
action: set_var
loop:
over:
- {user: "root", pass: "b120root"}
- {user: "root", pass: "insightr"}
- {user: "admin", pass: "/ADMIN/"}
- {user: "mg3500", pass: "merlin"}
var: acct
var_name: gate
var_value: false
- id: init-shell
action: set_var
var_name: shell
var_value: false
- id: init-proof-ok
action: set_var
var_name: proof_ok
var_value: false
- id: init-ctl-ok
action: set_var
var_name: ctl_ok
var_value: false
- id: init-ctl-rej
action: set_var
var_name: ctl_rej
var_value: false
- id: init-late
action: set_var
var_name: late
var_value: {response: ""}
- id: init-user-late
action: set_var
var_name: r_user_late
var_value: {response: ""}
- id: init-tail-late
action: set_var
var_name: r_tail_late
var_value: {response: ""}
- id: init-out
action: set_var
var_name: tn_out
var_value: ""
- id: init-ctl-late
action: set_var
var_name: c_late
var_value: {response: ""}
- id: init-ctl-out
action: set_var
var_name: ctl_out
var_value: ""
- id: open
action: tcp_open
handle: tn
port: "{{port}}"
read_banner: true
timeout_secs: 10
store_as: conn
# No "login:" in the first read: wait and read again (a zero-byte write
# only triggers the read).
- id: late-banner-wait
action: sleep
condition: "conn.connected == true && (type_of(conn.banner) != \"string\" || strstr(tolower(conn.banner), \"login:\") == \"\")"
duration_ms: 2000
- id: late-banner
action: tcp_send
handle: tn
condition: "conn.connected == true && (type_of(conn.banner) != \"string\" || strstr(tolower(conn.banner), \"login:\") == \"\")"
send: ""
timeout_secs: 10
store_as: late
# Product gate: the monitor's BusyBox telnetd greets with "insight login:"
# (anchored, so "hindsight login:" does not pass).
- id: gate-check
action: script
condition: "conn.connected == true"
store_as: gate
code: |
let g = "";
if type_of(conn.banner) == "string" { g += conn.banner; }
if type_of(late.response) == "string" { g += late.response; }
ereg("(^|[^a-z0-9])insight login", tolower(g))
- id: send-user
action: tcp_send
handle: tn
condition: "gate == true"
send: "{{acct.user}}\r\n"
timeout_secs: 10
store_as: r_user
# "Password:" not in the first read (slow device): wait and read again.
- id: late-password-wait
action: sleep
condition: "gate == true && (type_of(r_user.response) != \"string\" || strstr(tolower(r_user.response), \"password\") == \"\")"
duration_ms: 2000
- id: late-password
action: tcp_send
handle: tn
condition: "gate == true && (type_of(r_user.response) != \"string\" || strstr(tolower(r_user.response), \"password\") == \"\")"
send: ""
timeout_secs: 10
store_as: r_user_late
# Like the NASL, the password is only sent once "Password" was asked for.
- id: password-prompt
action: script
condition: "gate == true"
store_as: gate
code: |
let p = "";
if type_of(r_user.response) == "string" { p += r_user.response; }
if type_of(r_user_late.response) == "string" { p += r_user_late.response; }
strstr(tolower(p), "password") != ""
- id: send-pass
action: tcp_send
handle: tn
condition: "gate == true"
send: "{{acct.pass}}\r\n"
timeout_secs: 10
store_as: r_pass
- id: send-echo
action: tcp_send
handle: tn
condition: "gate == true"
send: "echo NOCTIS$(({{proof.a}}+{{proof.b}}))U$(id -u)Z\r\n"
timeout_secs: 10
store_as: r_echo
- id: wait-output
action: sleep
condition: "gate == true"
duration_ms: 1000
# Zero-byte write: read whatever the shell printed after the last read.
- id: flush
action: tcp_send
handle: tn
condition: "gate == true"
send: ""
# Drain read: usually nothing is left, and a read waits up to
# timeout_secs for a first byte — keep it short.
timeout_secs: 3
store_as: r_tail
- id: collect
action: script
condition: "gate == true"
store_as: tn_out
code: |
let out = "";
for r in [r_pass, r_echo, r_tail] {
if type_of(r.response) == "string" { out += r.response + "\n"; }
}
out
# Neither the sum nor a rejection yet (slow login): wait longer, read again.
- id: late-output-wait
action: sleep
condition: "gate == true && strstr(tn_out, proof.marker) == \"\" && strstr(tolower(tn_out), \"incorrect\") == \"\""
duration_ms: 2500
- id: late-output
action: tcp_send
handle: tn
condition: "gate == true && strstr(tn_out, proof.marker) == \"\" && strstr(tolower(tn_out), \"incorrect\") == \"\""
send: ""
timeout_secs: 10
store_as: r_tail_late
- id: collect-late
action: script
condition: "gate == true && type_of(r_tail_late.response) == \"string\""
store_as: tn_out
code: |
tn_out + r_tail_late.response
- id: close
action: tcp_close
handle: tn
- id: check-proof
action: script
condition: "gate == true"
store_as: proof_ok
code: |
strstr(tn_out, proof.marker) != ""
# Prompt-only evidence: a line ending in an ash "#" / "$" prompt, and no
# login failure or new login / password prompt after the password.
- id: check-shell
action: script
condition: "gate == true"
store_as: shell
code: |
let o = tolower(tn_out);
ereg("(?m)[#$]\\s*$", tn_out) && strstr(o, "incorrect") == "" && strstr(o, "login:") == "" && strstr(o, "password") == ""
# ---------------------------------- control: same user, random password
- id: ctl-open
action: tcp_open
handle: ctl
port: "{{port}}"
condition: "shell == true || proof_ok == true"
read_banner: true
timeout_secs: 10
store_as: ctl_conn
- id: ctl-late-wait
action: sleep
condition: "(shell == true || proof_ok == true) && ctl_conn.connected == true && (type_of(ctl_conn.banner) != \"string\" || strstr(tolower(ctl_conn.banner), \"login:\") == \"\")"
duration_ms: 2000
- id: ctl-late
action: tcp_send
handle: ctl
condition: "(shell == true || proof_ok == true) && ctl_conn.connected == true && (type_of(ctl_conn.banner) != \"string\" || strstr(tolower(ctl_conn.banner), \"login:\") == \"\")"
send: ""
timeout_secs: 10
- id: ctl-user
action: tcp_send
handle: ctl
condition: "shell == true || proof_ok == true"
send: "{{acct.user}}\r\n"
timeout_secs: 10
store_as: c_user
- id: ctl-pass
action: tcp_send
handle: ctl
condition: "shell == true || proof_ok == true"
send: "{{proof.ctl_pw}}\r\n"
timeout_secs: 10
store_as: c_pass
- id: ctl-echo
action: tcp_send
handle: ctl
condition: "shell == true || proof_ok == true"
send: "echo NOCTIS$(({{proof.a}}+{{proof.b}}))U$(id -u)Z\r\n"
timeout_secs: 10
store_as: c_echo
- id: ctl-wait-output
action: sleep
condition: "shell == true || proof_ok == true"
duration_ms: 1000
- id: ctl-flush
action: tcp_send
handle: ctl
condition: "shell == true || proof_ok == true"
send: ""
# Drain read: usually nothing is left, and a read waits up to
# timeout_secs for a first byte — keep it short.
timeout_secs: 3
store_as: c_tail
- id: ctl-collect
action: script
condition: "shell == true || proof_ok == true"
store_as: ctl_out
code: |
let out = "";
for r in [c_pass, c_echo, c_tail] {
if type_of(r.response) == "string" { out += r.response + "\n"; }
}
out
# Neither a shell nor a rejection yet: login(1) answers a wrong password
# only after its failure delay (about 3 s). Wait and read again.
- id: ctl-late-output-wait
action: sleep
condition: "(shell == true || proof_ok == true) && strstr(ctl_out, proof.marker) == \"\" && strstr(tolower(ctl_out), \"incorrect\") == \"\" && strstr(tolower(ctl_out), \"login:\") == \"\""
duration_ms: 3000
- id: ctl-late-output
action: tcp_send
handle: ctl
condition: "(shell == true || proof_ok == true) && strstr(ctl_out, proof.marker) == \"\" && strstr(tolower(ctl_out), \"incorrect\") == \"\" && strstr(tolower(ctl_out), \"login:\") == \"\""
send: ""
timeout_secs: 10
store_as: c_late
- id: ctl-close
action: tcp_close
handle: ctl
- id: ctl-collect-late
action: script
condition: "(shell == true || proof_ok == true) && type_of(c_late.response) == \"string\""
store_as: ctl_out
code: |
ctl_out + c_late.response
# The random password reached a shell: honeypot / broken login, no finding.
# Same prompt test as check-shell, so a NOEVAL-style accept-any login that
# only shows a prompt is suppressed as well.
- id: ctl-check
action: script
condition: "shell == true || proof_ok == true"
store_as: ctl_ok
code: |
let o = tolower(ctl_out);
strstr(ctl_out, proof.marker) != "" || (ereg("(?m)[#$]\\s*$", ctl_out) && strstr(o, "incorrect") == "" && strstr(o, "login:") == "" && strstr(o, "password") == "")
# Fail-closed: the random password counts as rejected only when login said
# so ("Login incorrect", or a new "insight login:" prompt after the password).
- id: ctl-rejected
action: script
condition: "(shell == true || proof_ok == true) && ctl_ok == false"
store_as: ctl_rej
code: |
let o = tolower(ctl_out);
strstr(o, "incorrect") != "" || strstr(o, "insight login:") != ""
# ------------------------------------------------------------- findings
- id: finding-shell
action: match
source: tn_out
pattern: "NOCTIS[0-9]+"
condition: "proof_ok == true && ctl_rej == true"
on_match:
finding:
title: "Philips In.Sight camera hard-coded Telnet account {{acct.user}}:{{acct.pass}}"
description: "The Telnet console of the Philips In.Sight camera logged in the account '{{acct.user}}' with its hard-coded password '{{acct.pass}}', and its shell evaluated an arithmetic `echo` sent by the scanner, while a random password was rejected (CVE-2015-2882)."
remediation: "The hard-coded accounts cannot be changed by the owner. Block Telnet (TCP/23) to the monitor at the network edge and on the local network, keep the monitor on an isolated segment, and replace devices for which the vendor provides no firmware removing these accounts."
confidence_delta: 0.65
qod: 97
evidence: "Telnet login {{acct.user}}:{{acct.pass}} accepted, shell printed {{proof.marker}} for `echo NOCTIS$(({{proof.a}}+{{proof.b}}))` (random password rejected). Output: {{tn_out}}"
stop: true
# The shell proof worked but the control login gave no clear answer
# (refused connection, connection limit, very slow login): still a login
# with a hard-coded password, reported at a lower QoD.
- id: finding-shell-control-unknown
action: match
source: tn_out
pattern: "NOCTIS[0-9]+"
condition: "proof_ok == true && ctl_ok == false && ctl_rej == false"
on_match:
finding:
title: "Philips In.Sight camera hard-coded Telnet account {{acct.user}}:{{acct.pass}}"
description: "The Telnet console of the Philips In.Sight camera logged in the account '{{acct.user}}' with its hard-coded password '{{acct.pass}}' and its shell evaluated an arithmetic `echo` sent by the scanner. A second login with a random password gave no clear answer, so a login that accepts any password could not be ruled out (CVE-2015-2882)."
remediation: "The hard-coded accounts cannot be changed by the owner. Block Telnet (TCP/23) to the monitor at the network edge and on the local network, keep the monitor on an isolated segment, and replace devices for which the vendor provides no firmware removing these accounts."
confidence_delta: 0.50
qod: 75
evidence: "Telnet login {{acct.user}}:{{acct.pass}} accepted, shell printed {{proof.marker}} for `echo NOCTIS$(({{proof.a}}+{{proof.b}}))`; random-password control inconclusive. Output: {{tn_out}}"
stop: true
- id: finding-prompt
action: match
source: tn_out
pattern: "[#$]"
condition: "proof_ok == false && shell == true && ctl_rej == true"
on_match:
finding:
title: "Philips In.Sight camera hard-coded Telnet account {{acct.user}}:{{acct.pass}}"
description: "The Telnet console of the Philips In.Sight camera logged in the account '{{acct.user}}' with its hard-coded password '{{acct.pass}}' and showed a shell prompt, while a random password was rejected. The output of the arithmetic `echo` was not captured (CVE-2015-2882)."
remediation: "The hard-coded accounts cannot be changed by the owner. Block Telnet (TCP/23) to the monitor at the network edge and on the local network, keep the monitor on an isolated segment, and replace devices for which the vendor provides no firmware removing these accounts."
confidence_delta: 0.50
qod: 75
evidence: "Telnet login {{acct.user}}:{{acct.pass}} accepted, shell prompt shown (random password rejected): {{tn_out}}"
stop: true