Complete the code to identify the tool used for scanning open ports.
The command 'nmap [1] 192.168.1.1' is used to scan open ports on a target.
The option -sS in nmap performs a TCP SYN scan, which is commonly used to scan open ports stealthily.
Complete the sentence to describe enumeration.
Enumeration is the process of [1] information about a target system after scanning.Enumeration involves gathering detailed information such as usernames, shares, and services after initial scanning.
Fix the error in the command to perform a UDP scan.
nmap [1] 192.168.1.1
The option -sU tells nmap to perform a UDP scan, which is different from the default TCP scans.
Fill both blanks to create a dictionary comprehension that maps services to their port numbers if the port is less than 1024.
services = { [1]: [2] for [1], [2] in service_list if [2] < 1024 }The comprehension uses service as the key and port as the value, iterating over service_list. The condition filters ports less than 1024.
Fill all three blanks to create a dictionary comprehension that maps uppercase usernames to their IPs if the IP is not empty.
user_ips = { [1]: [2] for [3], [2] in user_data.items() if [2] != '' }The comprehension maps username.upper() as the key to ip as the value, iterating over username and ip from user_data.items(). The condition filters out empty IPs.