nerdexam
CompTIA

CAS-001 · Question #99

An administrator is unable to connect to a server via VNC. Upon investigating the host firewall configuration, the administrator sees the following lines: - A INPUT -m state --state NEW -m tcp -p…

The correct answer is B. A line needs to be added. VNC uses TCP port 5900 (or 5901+) by default. Reviewing the existing firewall rules: port 3389 (RDP) is denied, port 22 (SSH) is denied, port 10000 is accepted, port 80 is denied, and there is an inbound ACCEPT for source port 3389 (which is misconfigured but irrelevant to…

Enterprise Security

Question

An administrator is unable to connect to a server via VNC. Upon investigating the host firewall configuration, the administrator sees the following lines:

  • A INPUT -m state --state NEW -m tcp -p tcp --dport 3389 -j DENY
  • A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j DENY
  • A INPUT -m state --state NEW -m tcp -p tcp --dport 10000 -j ACCEPT
  • A INPUT -m state --state NEW -m tcp -p tcp --dport 80 -j DENY
  • A INPUT -m state --state NEW -m tcp -p tcp --sport 3389 -j ACCEPT

Which of the following should occur to allow VNC access to the server?

Options

  • ADENY needs to be changed to ACCEPT on one line.
  • BA line needs to be added.
  • CA line needs to be removed.
  • DFix the typo in one line.

How the community answered

(54 responses)
  • A
    22% (12)
  • B
    59% (32)
  • C
    13% (7)
  • D
    6% (3)

Explanation

VNC uses TCP port 5900 (or 5901+) by default. Reviewing the existing firewall rules: port 3389 (RDP) is denied, port 22 (SSH) is denied, port 10000 is accepted, port 80 is denied, and there is an inbound ACCEPT for source port 3389 (which is misconfigured but irrelevant to VNC). There is no rule that permits inbound traffic on port 5900 (VNC). Since the implicit default policy denies unmatched traffic, VNC connections are silently dropped. The fix is to add a new rule: '-A INPUT -m state --state NEW -m tcp -p tcp --dport 5900 -j ACCEPT'. No existing rule needs to be changed (A is wrong), removed (C is wrong), or typo-corrected (D is wrong)-the VNC port rule simply does not exist yet.

Topics

#iptables#firewall rules#VNC#port access control

Community Discussion

No community discussion yet for this question.

Full CAS-001 Practice