This site is the archived OWASP Foundation Wiki and is no longer accepting Account Requests.
To view the new OWASP Foundation website, please visit https://owasp.org

Difference between revisions of "Testing: Information Gathering"

From OWASP
Jump to: navigation, search
 
(35 intermediate revisions by 7 users not shown)
Line 1: Line 1:
[[http://www.owasp.org/index.php/OWASP_Testing_Guide_v2_Table_of_Contents#Web_Application_Penetration_Testing Up]]<br>
+
{{Template:OWASP Testing Guide v4}}
{{Template:OWASP Testing Guide v2}}
 
  
=== Information Gathering ===
+
''' 4.2 Information Gathering '''
 
----
 
----
The  first phase in security assessment is focused on collecting all the information about a target application.
 
Information Gathering is a necessary step of a penetration test.<br>
 
This task can be carried out by using many different ways.<br>
 
Using public tools (search engines), scanners, sending simple HTTP requests, or specially crafted requests, it is possible to force the application leak information by sending back error messages revealing the versions and technologies used by the application.<br>
 
  
Often it is possible to gather information by receiving a response from the application which, as a consequence of default bad configuration in the application server or web server, could reveal vulnerabilities in configuration or bad server management.
+
The  first phase in security assessment is focused on collecting as much information as possible about a target application.
 +
Information Gathering is the most critical step of an application security test. The security test should endeavour to test as much of the code base as possible. Thus mapping all possible paths through the code to facilitate thorough testing is paramount.
  
[[Application Discovery AoC|4.2.1 Application Fingerprint]]
+
This task can be carried out in many different ways.
  
Application fingerprint is the first step fot the Information Gathering process knowing the version and type of a running web server allows testers to determine known vulnerabilities and the appropriate exploits to use during testing.  
+
By using public tools (search engines), scanners, sending simple HTTP requests, or specially crafted requests, it is possible to force the application to leak information, e.g., disclosing error messages or revealing the versions and technologies used.<br>
  
[[Application Discovery AoC|4.2.2 Application Discovery]]
 
  
 +
[[Testing for Application Discovery (OWASP-IG-005)|4.2.5 Application Discovery  (OWASP-IG-005)]] [rename to "Enumerate applications on webserver"]<br>
 
Application discovery is an activity oriented to the identification of the web applications hosted on a web server/application server.<br>
 
Application discovery is an activity oriented to the identification of the web applications hosted on a web server/application server.<br>
This analysis is important because many times there is not a direct link connecting the main application backend so, a discovery analysis would be useful to reveal details such as, web-apps used for administrative purposes, old versions of files or artifacts (such as scripts not properly deleted after their usage while crafted during the test/development phase or as the result of maintenance).
+
This analysis is important because often there is not a direct link connecting the main application backend. Discovery analysis can be useful to reveal details such as web applications used for administrative purposes. In addition, it can reveal old versions of files or artifacts such as undeleted, obsolete scripts, crafted during the test/development phase or as the result of maintenance.
  
[[Spidering and googling AoC|4.2.3 Spidering and googling]]
+
[[Testing: Spiders, Robots, and Crawlers  (OWASP-IG-001)|4.2.1 Spiders, Robots and Crawlers (OWASP-IG-001)]] [rename to "Review webserver metafiles" ]
 +
This phase of the Information Gathering process consists of browsing and capturing resources related to the application being tested.
  
This phase of the Information Gathering process consists in browsing and capturing resources related to the application being tested. Search engines, such as Google, can be used to discover issues related to the web application structure or error pages produced by the application usually found because exposed to the public domain.
+
[[Testing: Review webpage comments and metadata  (OWASP-IG-00x)|4.2.x Review webpage comments and metadata(OWASP-IG-00x)]]
 +
Review the webpage metadata, HTML, JavaScript comments for sensitive information and disabled links/scripts.  
  
[[Testing for Error Code|4.2.4 Analysis of error code]]
+
[[Testing: Identify application entry points (OWASP-IG-003)|4.2.3 Identify application entry points  (OWASP-IG-003)]]<br>
 +
Enumerating the application and its attack surface is a key precursor before any attack should commence. This section will help you identify and map out every area within the application that should be investigated once your enumeration and mapping phase has been completed.
  
Web applications may divulge information during a penetration test which is not intended to be seen by an end user. Information (such as error codes)can inform the tester about technologies and products being used by the application.<br>
+
[[Testing: Identify application exit/handover points (OWASP-IG-00x)|4.2.x Identify application exit/handover points  (OWASP-IG-00x)]]<br>
Such error codes, can be easy to exploit without using any particular skill due to bad error handling strategy.
+
Identify the functional exit points of the application and points where the application hands over to another application that may, or may not, be within scope of testing (e.g. handover to a payment gateway).  
  
[[Infrastructure configuration management testing AoC|4.2.5 Infrastructure configuration management testing]]
+
[[Testing: Map paths through the application (OWASP-IG-00x)|4.2.x Map paths through the application (OWASP-IG-00x)]]<br>
 +
Enumerating the application and its attack surface is a key precursor before any attack should commence. This section will help you identify and map out every area within the application that should be investigated once your enumeration and mapping phase has been completed.
  
Often analysis of the infrastructure and topology architecture can reveal a lot of information about a web application such as source code, HTTP methods permitted, administrative functionalities, authentication methods and infrastructural configurations.<BR>
+
[[Testing for Web Server Fingerprint (OWASP-IG-00x)|4.2.x Testing Web Server Fingerprint  (OWASP-IG-00x)]]<br>
For those reasons focusing only on the web application could not be an exhaustive test, considering the fact that those information collected during the security assessment, could not be as exhaustive as those possibly gathered performing a wider test comprehensive of an infrastructure analysis.
+
Application fingerprint is the first step of the Information Gathering process; knowing the version and type of a running web server allows testers to determine known vulnerabilities and the appropriate exploits to use during testing.
  
[[SSL/TLS Testing AoC|4.2.5.1 SSL/TLS Testing]]
+
[[Testing for Web Application Fingerprint (OWASP-IG-004)|4.2.4 Testing Web Application Fingerprint  (OWASP-IG-004)]]<br>
 +
Application fingerprint is the first step of the Information Gathering process; knowing the version and type of a running web server allows testers to determine known vulnerabilities and the appropriate exploits to use during testing.
  
SSL and TLS are two protocols which provide, with the support of the cryptography, a secure channel for the communications to protect the confidentiality & authentication of the information and a secure channel.<br>
+
[[Testing for Error Codes (OWASP-IG-006)|4.2.6 Analysis of Error Codes  (OWASP-IG-006)]]<br>
Considering the importance of those security implementations it is important to verify the presence of a strong cipher algorithm used and proper implementation has been performed.
+
During a penetration test, web applications may divulge information that is not intended to be seen by an end user. Information such as error codes can inform the tester about technologies and products being used by the application.<br>
 +
In many cases, error codes can be easily invoked without the need for specialist skills or tools, due to bad exception handling design and coding.  
  
[[DB Listener Testing AoC|4.2.5.2 DB Listener Testing]]
+
[[Testing: Search engine discovery/reconnaissance (OWASP-IG-002)|4.2.2 Search Engine Discovery/Reconnaissance  (OWASP-IG-002)]]<br>
 +
Search engines, such as Google, can be used to discover issues related to the web application structure or error pages produced by the application that have been publicly exposed.
  
During the configuration of a database server many DB administrators do not consider the importance of the lack of security of the DB Listener component. It could reveal sensible data as well as configuration settings or database instances running.<br>
+
Clearly, focusing only on the web application will not be an exhaustive test. It cannot be as comprehensive as the information possibly gathered by performing a broader infrastructure analysis.
The collection of those information could provide some useful hints needed to compromise the reservedness, integrity and availability of the data stored.<br>
 
An accurate security analysis over DB listener configuration matters permits to acquire those information.
 
 
 
[[Application configuration management testing AoC|4.2.6 Application configuration management testing]]
 
 
 
The web applications hide some information which usually are not considered during the development or the configuration of the application itself.<br>
 
Those data can be discovered in the source code, in the log files or in the default error codes of the web servers so a correct approach on this topic is fundamental during a security assessment.
 
 
 
[[File extensions handling AoC|4.2.6.1 File extensions handling]]
 
 
 
Observing the file extensions present in a web server or a web-app, it is possible to identify the technologies which compose the target application (for example jsp and asp extensions in a server-side architecture) and sometimes additional systems connected to the application.
 
 
 
[[Old file testing AoC|4.2.6.2 Old, backup and unreferenced files]]
 
 
 
Redundant files which could be present on a web server (such as old, backup and renamed files), which are freely readable and downloadable are a big source of information leakage. It is necessary to verify the presence of these files because they may contain parts of source code, installation paths as well as passwords for applications and/or databases.
 
 
 
 
 
 
 
{{Category:OWASP Testing Project AoC}}
 

Latest revision as of 05:27, 8 November 2012

This article is part of the new OWASP Testing Guide v4.
Back to the OWASP Testing Guide v4 ToC: https://www.owasp.org/index.php/OWASP_Testing_Guide_v4_Table_of_Contents Back to the OWASP Testing Guide Project: https://www.owasp.org/index.php/OWASP_Testing_Project


4.2 Information Gathering


The first phase in security assessment is focused on collecting as much information as possible about a target application. Information Gathering is the most critical step of an application security test. The security test should endeavour to test as much of the code base as possible. Thus mapping all possible paths through the code to facilitate thorough testing is paramount.

This task can be carried out in many different ways.

By using public tools (search engines), scanners, sending simple HTTP requests, or specially crafted requests, it is possible to force the application to leak information, e.g., disclosing error messages or revealing the versions and technologies used.


4.2.5 Application Discovery (OWASP-IG-005) [rename to "Enumerate applications on webserver"]
Application discovery is an activity oriented to the identification of the web applications hosted on a web server/application server.
This analysis is important because often there is not a direct link connecting the main application backend. Discovery analysis can be useful to reveal details such as web applications used for administrative purposes. In addition, it can reveal old versions of files or artifacts such as undeleted, obsolete scripts, crafted during the test/development phase or as the result of maintenance.

4.2.1 Spiders, Robots and Crawlers (OWASP-IG-001) [rename to "Review webserver metafiles" ] This phase of the Information Gathering process consists of browsing and capturing resources related to the application being tested.

4.2.x Review webpage comments and metadata(OWASP-IG-00x) Review the webpage metadata, HTML, JavaScript comments for sensitive information and disabled links/scripts.

4.2.3 Identify application entry points (OWASP-IG-003)
Enumerating the application and its attack surface is a key precursor before any attack should commence. This section will help you identify and map out every area within the application that should be investigated once your enumeration and mapping phase has been completed.

4.2.x Identify application exit/handover points (OWASP-IG-00x)
Identify the functional exit points of the application and points where the application hands over to another application that may, or may not, be within scope of testing (e.g. handover to a payment gateway).

4.2.x Map paths through the application (OWASP-IG-00x)
Enumerating the application and its attack surface is a key precursor before any attack should commence. This section will help you identify and map out every area within the application that should be investigated once your enumeration and mapping phase has been completed.

4.2.x Testing Web Server Fingerprint (OWASP-IG-00x)
Application fingerprint is the first step of the Information Gathering process; knowing the version and type of a running web server allows testers to determine known vulnerabilities and the appropriate exploits to use during testing.

4.2.4 Testing Web Application Fingerprint (OWASP-IG-004)
Application fingerprint is the first step of the Information Gathering process; knowing the version and type of a running web server allows testers to determine known vulnerabilities and the appropriate exploits to use during testing.

4.2.6 Analysis of Error Codes (OWASP-IG-006)
During a penetration test, web applications may divulge information that is not intended to be seen by an end user. Information such as error codes can inform the tester about technologies and products being used by the application.
In many cases, error codes can be easily invoked without the need for specialist skills or tools, due to bad exception handling design and coding.

4.2.2 Search Engine Discovery/Reconnaissance (OWASP-IG-002)
Search engines, such as Google, can be used to discover issues related to the web application structure or error pages produced by the application that have been publicly exposed.

Clearly, focusing only on the web application will not be an exhaustive test. It cannot be as comprehensive as the information possibly gathered by performing a broader infrastructure analysis.