Chap 3 - Information Gathering Flashcards
nmap -sU -sT -p 1-65535 example.com
What information will she not receive?
- TCP services
- The state of the service
- UDP services
- A list of vulnerable services
A list of vulnerable services
This is a port scan, not a vulnerability scan, so Megan will not be able to determine if the services are vulnerable just from this scan. The Nmap scan will show the state of the ports, both TCP and UDP.
Tom wants to find metadata about an organization using a search engine. What tool from the following list should he use?
- ExifTool
- MetaSearch
- FOCA
- Nmap
FOCA
FOCA, or Fingerprinting Organizations with Collected Archives, is a useful tool for searching for metadata via search engines. ExifTool is used for individual files. MetaSearch was made up for this question, and although Nmap has many functions, it isn’t used for metadata searches via search engines.
ExifTool
ExifTool is a powerful, open-source software utility designed for reading, writing, and manipulating metadata across various file types, including images, audio, video, and PDFs. Developed by Phil Harvey and first released in 2003, ExifTool has become a standard tool for managing metadata due to its extensive capabilities and support for a wide range of formats.
Key Features
* Metadata Support: ExifTool handles numerous metadata formats such as EXIF, IPTC, XMP, JFIF, GeoTIFF, ICC Profile, and more. It can also process manufacturer-specific metadata from many digital cameras
* Command-Line Interface: It operates primarily through a command-line interface, allowing users to execute commands to read or modify metadata efficiently. Users can specify tags to read or write and can process multiple files at once
* Custom Tags: Users can define custom tags and manage over 23,000 tags categorized into 130 different groups. This flexibility makes it suitable for both casual users and professionals requiring detailed metadata management
* Cross-Platform Compatibility: ExifTool is platform-independent and works on Windows, macOS, and Linux systems. It is available as both a standalone command-line application and a Perl library
After running an Nmap scan of a system, Zarmeena discovers that TCP ports 139, 443, and 3389 are open. What operating system is she most likely to discover running on the system?
- Windows
- Android
- Linux
- iOS
Windows
Zarmeena knows that TCP ports 139, 443, and 3389 are all commonly used for Windows services. Although those ports could be open on a Linux, Android, or iOS device, Windows is her best bet.
Port 3389
RDP
Port 443
HTTPS (SSL over HTTP)
Port 139
NetBIOS
Charles runs an Nmap scan using the following command:
nmap -sT -sV -T2 -p 1-65535 example.com
After watching the scan run for over two hours, he realizes that he needs to optimize the scan. Which of the following is not a useful way to speed up his scan?
- Only scan via UDP to improve speed.
- Change the scan timing to 3 or faster.
- Change to a SYN scan.
- Use the default port list.
Only scan via UDP to improve speed.
Only scanning via UDP will miss any TCP services. Since the great majority of services in use today are provided as TCP services, this would not be a useful way to conduct the scan. Setting the scan to faster timing (3 or faster), changing from a TCP connect scan to a TCP SYN scan, or limiting the number of ports tested are all valid ways to speed up a scan. Charles needs to remain aware of what those changes can mean, since a fast scan may be detected or cause greater load on a network, and scanning fewer ports may miss some ports.
Karen identifies TCP ports 8080 and 8443 open on a remote system during a port scan. What tool is her best option to manually validate the services running on these ports?
- SSH
- SFTP
- Telnet
- A web browser
A web browser
Karen knows that many system administrators move services from their common service ports to alternate ports and that 8080 and 8443 are likely alternate HTTP (TCP 80) and HTTPS (TCP 443) server ports, and she will use a web browser to connect to those ports to check them. She could use Telnet for this testing, but it requires significantly more manual work to gain the same result, making it a poor second choice unless Karen doesn’t have another option.
Angela recovered a PNG image during the early intelligence‐gathering phase of a penetration test and wants to examine it for useful metadata. What tool could she most successfully use to do this?
- ExifTool
- Grep
- PsTools
- Nginx
ExifTool
ExifTool is designed to pull metadata from images and other files. Grep may be useful to search for specific text in a file, but it won’t pull the range of possible metadata from the file. PsTools is a Windows Sysinternals package that includes a variety of process‐oriented tools. Nginx is a web server, load balancer, and multipurpose application services stack.
During an Nmap scan, Casey uses the -O flag. The scan identifies the host as follows:
Running: Linux 2.6.X
OS CPE: cpe:/o:linux:linux_kernel:2.6
OS details: Linux 2.6.9 - 2.6.33
What can she determine from this information?
- The Linux distribution installed on the target
- The patch level of the installed Linux kernel
- The date the remote system was last patched
- That the system is running a Linux 2.6 kernel between .9 and .33
That the system is running a Linux 2.6 kernel between .9 and .33
OS identification in Nmap is based on a variety of response attributes. In this case, Nmap’s best guess is that the remote host is running a Linux 2.6.9–2.6.33 kernel, but it cannot be more specific. It does not specify the distribution, the patch level, or when the system was last patched.
Steve is working from an unprivileged user account that was obtained as part of a penetration test. He has discovered that the host he is on has Nmap installed, and he wants to scan other hosts in his subnet to identify potential targets as part of a pivot attempt. What Nmap flag will Steve probably have to use to successfully scan hosts from this account?
- -sV
- -u
- -oA
- -sT
-sT
The TCP connect scan is often used when an unprivileged account is the tester’s only option. Linux systems typically won’t allow an unprivileged account to have direct access to create packets, but they will allow accounts to send traffic. Steve probably won’t be able to use a TCP SYN scan, but a connect scan is likely to work. The other flags shown are for version testing (-sV) and output type selection (-oA), and -u doesn’t do anything at all.
Chris runs an Nmap scan of the 10.10.0.0/16 network that his employer uses as an internal network range for the entire organization. If he uses the -T0 flag, what issue is he likely to encounter?
- The scan will terminate when the host count reaches 0.
- The scan will not scan IP addresses in the .0 network.
- The scan will progress at a very slow speed.
- The scan will only scan for TCP services.
The scan will progress at a very slow speed.
The -T flag in Nmap is used to set scan timing. Timing settings range from 0 (paranoid) to 5 (insane). By default, it operates at 3, or normal. With timing set to a very slow speed, Chris will run his scan for a very, very long time on a /16 network.
Which of the following Nmap output formats is unlikely to be useful for a penetration tester?
- -oA
- -oS
- -oG
- -oX
-oS
The Script Kiddie output format that Nmap supports is entirely for fun—you should never have a practical need to use the -oS flag for an actual penetration test.
During an early phase of his penetration test, Mike recovers a binary executable file that he wants to quickly analyze for useful information. Which of the following will quickly give him a view of potentially useful information in the binary?
- Netcat
- strings
- Hashmod
- Eclipse
strings
The strings command parses a file for strings of text and outputs them. It is often useful for analyzing binary files, since you can quickly check for information with a single quick command‐line tool. Netcat, while often called a pentester’s Swiss Army knife, isn’t useful for this type of analysis. Eclipse is an IDE and would be useful for editing code or for managing a full decompiler in some cases.