nerdexam
EC-Council

312-50V10 · Question #275

A pentester gains access to a Windows application server and needs to determine the settings of the built- in Windows firewall. Which command would be used?

The correct answer is A. Netsh firewall show config. The netsh command-line utility is the correct Windows tool for querying and configuring the built-in Windows Firewall from the command prompt.

System Hacking

Question

A pentester gains access to a Windows application server and needs to determine the settings of the built- in Windows firewall. Which command would be used?

Options

  • ANetsh firewall show config
  • BWMIC firewall show config
  • CNet firewall show config
  • DIpconfig firewall show config

How the community answered

(22 responses)
  • A
    86% (19)
  • B
    9% (2)
  • D
    5% (1)

Why each option

The netsh command-line utility is the correct Windows tool for querying and configuring the built-in Windows Firewall from the command prompt.

ANetsh firewall show configCorrect

The 'netsh firewall show config' command (or its modern equivalent 'netsh advfirewall show allprofiles') is the built-in Windows utility for displaying firewall configuration, including enabled rules, exceptions, and profiles. It is part of the Network Shell (netsh) toolset included in all modern Windows versions and provides detailed firewall state information accessible from any command prompt.

BWMIC firewall show config

WMIC (Windows Management Instrumentation Command-line) does not have a 'firewall' verb or subcommand for querying Windows Firewall settings.

CNet firewall show config

The 'net' command is used for network share and service management and has no 'firewall' subcommand.

DIpconfig firewall show config

'Ipconfig' is used to display and manage IP address configuration for network interfaces and has no firewall querying capability.

Concept tested: Windows netsh command for firewall enumeration

Source: https://learn.microsoft.com/en-us/windows-server/networking/technologies/netsh/netsh-advfirewall-firewall

Topics

#Windows firewall#netsh#firewall enumeration#post-exploitation

Community Discussion

No community discussion yet for this question.

Full 312-50V10 Practice