15.1 Introduction to Web Vulnerabilities and Hardening Flashcards

1
Q

The cyber kill chain is an __________ designed to identify and prevent cyber intrusions.

A

The cyber kill chain is an “intelligence-driven defense framework” designed to identify and prevent cyber intrusions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

The _______ chain has been adapted to apply more directly to web server infrastructure. It includes the following stages: (5)

A

The hybrid kill chain, a derivative of Lockheed Martin’s cyber kill chain.

**Reconnaissance**: Information gathering stage against the target.

**Weaponization**: Preparation of offensive operations against specific targets using information gathered during reconnaissance.

**Delivery**: Launch of the operation. Attacks carried out based on Red Team offensive strategies.

**Exploitation**: Actively compromises adversary’s apps, servers, or network, and avert physical, logical, or administrative controls.

**Exfiltration**: Ultimate goal. The exfiltration of private, sensitive data that the target considers to be critically sensitive.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

The ________ is widely considered to represent the most prevalent security risks facing web applications today.

A

The **OWASP Top 10** is widely considered to represent the most prevalent security risks facing web applications today.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

True or False:

The OWASP Top 10 is a platform for standardizing awareness of threats in web application development security.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the purpose of the OWASP Top 10?

A

OWASP TOP 10 was created to educate a wide audience of professionals about the consequences of web application security weaknesses.

The Top 10 offers resources and best practices to software engineers, managers, designers, and organizations about how to protect against threats. Also a community.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is OWASP’s number one threat?

A

Code injection, such as SQL, LDAP, OS, and NOSQL.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How is OWASP Top 10 developed?

A

Over 500 individuals from various organizations who work on applications and API are surveyed. OWASP prioritizes the top ten threats based on prevalence data as well as exploitability, detectability and impact.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the OWASP Cheat Sheet Series and what is it used for?

A

The OWASP Cheat Sheet Series (OCSS) is designed by application security professionals to provide a collection of significant information in regards to specific application security topics.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are the current OWASP top 10 threats?

A
  1. Injection
  2. Broken Authentication
  3. Sensitive Data Exposure
  4. XML External Entities (XXE)
  5. Broken Access Controls
  6. Security Misconfigurations
  7. Cross-Site Scripting (XSS)
  8. Insecure Deserialization
  9. Using Components with Known Vulnerabilities
  10. Insufficient Logging and Monitoring
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What does URL stand for?

A

The **Uniform Resource Locator (URL)**, also referred to as the Uniform Resource Identifer (URI), is the standardized naming convention for addressing documents that are accessible over the internet, intranets (closed network within a single organization), and extranets (closed network shared across groups or organizations).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

The _______ indicates the protocol or application to use with the request, such as:

A

**Protocol**

  • HTTP Hypertext Transfer Protocol: Used for transferring webpages.
  • FTP File Transfer Protocol: Used for file transfer requests (upload and download).
  • SPDY Speedy: Google’s version of HTTP, designed to speed up web content loading.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

The _______ identifies a specific web server for the request of web resources.

A

The **Host Name** identifies a specific web server for the request of web resources.

  • Domain Name: example.com, google.com, facebook.com, etc.
  • Sub-Domain: Typically used for specific sub-sites within a larger domain. The most common subdomain is www, which stands for World Wide Web. Some domains use this as an indication of publicly accessible resources and content.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

The _______ request indicates which web application will be used to provide resources to the client.

A

The **Path** request indicates which web application will be used to provide resources to the client.

This is a directory, similar to a file or folder on your computer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What does .asp stand for and what is it?

A

(Active Server Page)

Active Server Pages, commonly referred to as ASP, is Microsoft’s solution to server-side scripting.

With Active Server Pages, the server gets a chance to alter the file before sending it to the user. So, for every request for a file with a .ASP extension, the server runs the file through a DLL called ASP.DLL, which parses the ASP commands.

If your web site is run on a UNIX box, you can still use Active Server Pages, but you need to use a third party tool to translate the ASP before it is sent to the client.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

________ are specifically formatted data that interact with back-end servers such as email and web databases.

A

**Parameters** are specifically formatted data that interact with back-end servers such as email and web databases.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Explain the different parts of a URL parameter?

http:// www.example.com /add.asp?item#3478&price=299

A

Each parameter is made up of a few different parts:

  • The question mark (?) indicates the beginning of a list of parameters.
  • Each individual parameter has a name and a value, separated by a hash (#).
  • The name of this parameter is item# and the value is 3478.
  • A URL can have multiple parameters. These will be separated by an ampersand symbol (&). For example: ?item# 3478&price=299
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

A URL is composed of many parts. Define each part of a URL:

A
  • Protocol: http. Identifies the protocol or application to use with the HTTP request.
  • Host Name: example.com. Targets a specific web server for the request of web resources.
  • Path: add.asp?. Identifies which of the host’s web applications will be used to provide resources to the client.
  • Parameters: ItemID=123&Price=999. Specifically formatted data that interacts with back-end databases, email, and web servers, for example.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

How can a URL (also know as a URI) be used as a weapon against web servers?

A

A URL can be manipulated by attackers to infiltrate these various parts of the web server architecture.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Web vulnerabilities exist because SDLC faces what challenges: (6)

A
  • Implementation costs are high.
  • Lack of support from management.
  • Lack of standardization.
  • No quality management.
  • Reactive security posture (“If it ain’t broke, don’t fix it” mentality).
  • Reliance on a false sense of security that web application firewalls provide absolute protection.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What are the 5 primary stages of web server infrastructure?

A

**Stage 1: Client**: A user who interacts with a web server using HTTP or FTP through either a web browser or file transfer software.

- **Stage 2: Firewall:** A perimeter defense used to protect the web server sitting behind it.

- **Stage 3: Web Server**: A program such as Apache, Nginx, or IIS that responds to a client’s requests for web resources.

- **Stage 4: Web Application:** The software that runs on a remote server, such as Facebook, Twitter, or Amazon.

- **Stage 5: Database**: Typically the innermost part of the web architecture, storing data such as customer names, addresses, account numbers, and credit card info.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

What is input sanitation?

A

The process of cleaning and scrubbing user input to prevent it from exploiting security holes. This is ensured by, when necessary, changing the value input by the user.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What is the input validation process?

A

**Input validation**: The testing of input supplied by a user or application, designed to prevent malformed data from entering a data information system. This is done by verifying user input meets specific criteria.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What is the SDLC process?

A

**Secure Software Deployment Cycles (SDLC)**: A software development methodology that ensures secure programming at every stage of the software development process.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What are the three most popular web servers in use today?

A
  1. Apache
  2. Nginx
  3. IIS
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

Name three ways a compromised web server can be used to perform an attack.

A
  1. A defaced webpage can contain malicious content and links to inappropriate and offensive sites, which can damage a company’s reputation.
  2. A compromised web server can be used to download malicious software (viruses, Trojans, botnets) to anyone visiting the webpage.
  3. Compromised data can be used to commit fraudulent activities, leading to loss of business or lawsuits.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

The typical web application server setup is composed of five basic components. Name and define each component.

A
  1. The client: A user who interacts with a web server using HTTP or FTP through either a web browser or file transfer software.
  2. A firewall: A perimeter defense used to protect a web server placed behind it.
  3. A web server: A program such as Apache, Nginx, or IIS that responds to a client’s requests for web resources.
  4. Web applications: The software that runs on a remote server, such as Facebook, Twitter, Amazon.
  5. Databases: Typically the inner most part of the web architecture where data is stored, such as customer names, addresses, account numbers, and credit card info.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

______ is an open-source web server alternative that runs on Unix, Linux, and Windows.

A

**Apache** is an open-source web server alternative that runs on Unix, Linux, and Windows.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

Explain Internet Information Server (IIS)

A

**Internet Information Server (IIS)** is a general-purpose web server from Microsoft that runs on Windows systems and serves HTML pages and files to web clients.

IIS has a long list of well-known published vulnerabilities. Note the Common Vulnerabilities and Exposure ID as well.

29
Q

Explain Cross-site scripting (XSS)

A

Allows remote attackers to alter a URL with a malicious script that will redirect a message or request.

30
Q

What is directory traversal

A

Allows remote attackers to view source code and determine the existence of arbitrary files via a hex-encoded %c0%ae%c0%ae string, which is the Unicode representation for “..” (dot dot).

31
Q

What is Nginx?

A

**Nginx** is an open-source, less popular, alternative to Apache that runs on Linux. Web vulnerabilities are less prevalent than on IIS or Apache.

32
Q

What are the three of the most critical Apache vulnerabilities?

A
  1. **OpenMeetings SQL Injection Vulnerability**: Allows for modification of the structure of existing queries, resulting in the exfiltration of queries made by the back-end application.
  2. **Apache Ranger Security Bypass Vulnerability**: Any characters after a wildcard symbol * are ignored, resulting in unintended behavior.
  3. **Apache HTTP Server Authentication Bypass Vulnerability**: Use of the string ap_get_basic_auth_pw() by third-party modules to bypass authentication requirements.
33
Q

What are three Nginx vulnerabilities?

A
  1. **Nginx SPDY Heap Buffer Overflow**: Allows remote attackers to craft requests that execute arbitrary code.
  2. **Nginx Root Privilege Escalation Vulnerability**: Allows local users to gain root privileges.
  3. **Remote Integer Overflow Vulnerability**: Sensitive data can be leaked with crafted requests that exploit a range filter module in certain Nginx versions.
34
Q

What is content spoofing?

A

Tricks a user into believing that certain website is legitimate. For example, a fake login page that steals your credentials after you submit them.

35
Q

What is drive-by download?

A

Triggers downloads upon visiting a webpage without the users knowledge.

36
Q

What is web cache poisoning?

A

An attack that replaces legitimate cached web pages with malicious content.

37
Q

What is clickjacking?

A

Tricks users into clicking misleading graphics that trigger an exploit. For example: A button that reads “Download” in large text.

38
Q

What are 5 client-side attacks?

A
  1. **Cross-site scripting (XSS)**: Allows attackers to inject malicious code into a website in order to intercept user sessions, vandalize websites, steal data, and control a user’s browser.
  2. **Clickjacking**: Tricks users into clicking misleading graphics that trigger an exploit. For example: A button that reads “Download” in large text.
  3. **Content spoofing**: Tricks a user into believing that a website is legitimate. For example, a fake login page that steals your credentials after you submit them.
  4. **Drive-by download**: Triggers downloads without the user’s knowledge when a webpage is visited.
  5. **Phishing**: A form of social engineering that manipulates a user into providing personal confidential information, such as user credentials and bank account information.
39
Q

True or False:

A client-side attack occurs when a user’s computer downloads malicious content from the web. Quite often, firewalls fail to prevent client-side attacks which occur behind the firewall and from within the local network.

A

True

40
Q

Explain website defacement:

A

An attack against a website that alters the appearance and information contained on a website or webpage.

41
Q

Explain HTTP response splitting (CRLF injection)

A

A type of web server vulnerability where the server does not properly sanitize input values, such as character returns (CRs) and line feeds (LFs).

42
Q

Explain parameter or URL tampering

A

An attack that manipulates parameters passed to a web server in a URL.

43
Q

What are 5 server-side attacks:

A
  1. Website defacement
  2. HTTP response splitting (CRLF injection)
  3. Web cache poisoning
  4. Parameter or URL tampering
  5. Path or directory traversal (dot-dot-slash attack)
44
Q

What is a path or directory traversal (dot-dot-slash attack)?

A

An attack that navigates into senstive files and directories by using dot-dot-slash (../) (as if navigating through directories in a terminal) in the URL.

45
Q

Name that Attack

An organization’s homepage is altered with an image of a skull and crossbones and a message that says “Animal Murderers!” Organizations that experience these types of attacks are usually seen as incompetent in the public eye, resulting in reputation damage.

A

Website defacement, often used by politically-motivated hacktivists.

46
Q

Name that Attack

An attacker controls another HTTP response after the first response, in order to mount attacks.

A

HTTP response splitting (CRLF)

47
Q

Name that Attack

A legitimately cached web page sends a user to a malicious website.

A

Web cache poisoning

48
Q

Name that Attack:

A URL was changed:

Before: http://example.com/add.asp?ItemID=123&Price=999
After: http://example.com/add.asp?ItemID=123&Price=001

A

Parameter tampering

49
Q

Name that Attack

A URL was changed to http://some_site.com.br/../../../../etc/shadow.

A

Path or directory traversal

50
Q

Name that Attack

You find a URL that contains the following code: %co%af %e0%80%a.

A

Unicode

51
Q

_____, also known as ______ and _______, index sites to help search engines find content.

A

Web crawlers, also known as spiders and spiderbots, index sites to help search engines find content.

52
Q

Name seven pieces of information that an attacker could easily find on the internet that would be useful to them.

A
  1. IP address scheme
  2. domain information
  3. port state (open/closed/filtered)
  4. email addresses,
  5. operating system banner,
  6. employee names,
  7. phone numbers.
53
Q

What is waf00f?

A

Wafw00f is an open source command-line WAF utility focused on web-based attacks that occur at the application

54
Q

Explain:

wafw00f www.example.com –a –v

A

An aggressive scan of example.com.

-a: Option for aggressive scan

v: Verbose option, echoes the query responses to the standard output (monitor).

-vv: Used to increase the verbosity of the scan’s output.

55
Q

What is WAF?

A

Web application firewalls (WAFs)

**Web application firewalls (WAFs)** are designed to defend against different types of HTTP attacks and various query types such as SQLi and XSS.

56
Q

What layer of the OSI model do WAFs operate on?

A

Layer 7: Application

57
Q

Name three ways a WAF can be implemented.

A
  1. Network-based
  2. Host-based
  3. Cloud-based
58
Q

A WAF helps protect web applications by filtering and monitoring what?

A

HTTP traffic between web applications and the internet

59
Q

True or False:

A WAF based on the **negative security model** (blacklisting) protects against known attacks, and a WAF based on the **positive security model** (whitelisting) allows preapproved traffic.

A

True

60
Q

What are the three WAF deployment strategies?

A
  1. **Network-Based WAF**
  2. **Host-Based WAF**
  3. **Cloud-Based WAF**
61
Q

What are the advantages and disadvantages to Network-Based WAF?

A
  • Typically low-latency hardware that is installed locally on-premises with a dedicated appliance.
  • Capable of large-scale deployment and configuration management.
  • Drawback is high-cost. These have initial expenses to set up, and ongoing operational costs.
62
Q

What are the advantages and disadvantages to host-based WAF

A
  • Software-based and dependent on local server resources.
  • More difficult to manage and require more staff resources.
  • Lower cost.
63
Q

What are the advantages and disadvantages to cloud-based WAF?

A
  • Low cost, subscription based, turnkey product that requires minimal resources.
  • Protects applications across a variety of hosting locations that protect against application layer attacks.
  • Cloud service providers use the most current threat intelligence to help identify and block new application security threats.
64
Q

What are the three ways WAF filters traffic?

A
  1. **Allow lists** only accepts traffic from sources that are known and trusted.
  • Less resource-intensive than deny lists.
  • May block benign traffic unintentionally.
  1. **Deny lists** uses preset signatures to block malicious web traffic.
  • Useful for public websites and web applications that receive lots of traffic from unknown IP addresses.
  • Resource-intensive due to packet filtering based on a set of specific characteristics as opposed to IP addresses.
  1. **Hybrid** uses a combination of both allow and deny lists.
65
Q

Explain Cross-site Scripting?

A

Cross-site scripting (XSS) attacks occurs when an attacker takes advantage of a web vulnerability by injecting malicious code into a web browser. The code is stored on the back-end server, typically in the form of a script, and targets subsequent visitors to that webpage.

66
Q

XSS

An end user’s browser can’t detect such attacks because of the default trust relationship it has with the source.

A

True

67
Q

What are three XSS mitigation strategies?

A
  1. Data Output Encoding: Encodes user-controlled data before its output in an HTTP response. This prevents it from being misinterpreted as active content.
  2. Data Input Filters: Filters data at the point where user input is received, based on expected or valid input criteria.
  3. Content Security Policy (CSP): Detects and mitigates specific types of attacks, including XSS and other injection attacks. (Not all browsers support CSP.)
68
Q

What are three web server hardening mitigation strategies?

A
  1. Input validation: The primary defense mechanism. The same rules apply as discussed in the parameter tampering exercise.
  2. Ensure that all files and folders on the local server have proper access controls in place through system hardening.
  3. Web developers should avoid storing private sensitive information in the web root directory.