1. Data Breach
There are often multiple reasons why an Oracle database may be attacked. An attacker may see an Oracle database simply as an easy target to gain access to a companys other IT infrastructure. Unfortunately, because Oracle is a very complex product that requires an enormous amount of configuration, often gaps are created in the security model used to protect the data held within the database.
Because access to data is often at multiple levelsvia an application interface, a developer using TOAD, a DBA using SQL*Plus, and many morethere is a risk that the security controls are different at each layer and so allow access to more data at one layer than another. An attacker may choose to attack an Oracle database to steal the data or he may choose to attack an Oracle database simply to gain access to other IT infrastructure.
It is important to understand at a high level the types of attacks that can be performed on an Oracle database so that you are able to recognize them from evidence gathered. It is also imperative to understand what an incident is and what an incident response is. Following an incident, forensic analysis must take place to understand how the attackers may have breached and stolen data or done other damage to your database. Finally, its important to know how Oracle itself works at a reasonably detailed level because this will give you clues as to where evidence or artifacts can be found and used.
We have a brief discussion of the subject of chain of custody. This is the process normally used when investigating a PC as part of computer forensics. With a small system, the process is often clean and simple and involves documentation, verification, and secure storage of the artifacts (usually a complete computer or hard disk). A short discussion is also included on the issue of admissibility of evidence in court. Verifying evidence is usually done by checksumming hard disk, and this process is compared with an Oracle database. This sets the background to normal IT forensic analysis so that we can contrast it with forensic analysis of an Oracle database.
Types of Attack
Table introduces a high-level list of some types of attack that could be performed against an Oracle database. This list includes a brief description of the attack type, the danger it poses to the owner of the data in the Oracle database, and the skill level needed to try the attack. This list is by no means exhaustive and in some cases an attack type may have multiple sub-types. For instance, SQL Injection could be SQL Injection of SQL code embedded in a remote PHP web application that accesses the database or it could be SQL injection of SQL code executed in a PL/SQL package in the database. It could even be SQL injection of SQL code in a batch process where the injection must be done via an INSERT statement.
There are many possible attack types and many of them can be combined into a single attack. This makes understanding how any particular attack took place difficult. There is no set list of rules that can be easily used to identify an attack.
The location of the attacker and the database is also very important to how the attack plays out. An attacker who is located internally to the business will more than likely have access to a desktop computer, probably with applications that access the database he wants to attack and possibly with tools that would allow a direct connection to the database. Most end users in an organization will probably not have credentials for the database; at least they may not understand if they do have credentials for the database. Some applications actually log into the database directly but the user enters the credentials in the screen of an application. Internally in an organization the staff is more likely to understand the data that is processed and possibly more likely to understand the architecture and technology used, therefore making an attack easier.
An external attack is much harder. If an attacker is able to exploit a publicly facing web site that serves its data from a database, then it may be possible to effectively tunnel your way in to the database. If this were not possible, then it would be much harder for an external attacker to gain access to an internal database. The attacker would first need to be able to get onto the network of the organization and then find a way to identify and access the database.
The list of attacks in Table is not exhaustive and, as stated, an attacker could be internal or external and attacks can be combined. Factor in the multitude of operating system versions, Oracle database versions, and different types of applications, and you can see how each attack can look quite different.
Table 1-1
Database Attack Types
Attack Type | Danger | Skill Level | Description |
---|
SQL Injection | High/Low | High/Low | The danger is high or low depending on the data potentially exposed by the SQL that is attacked. The skill level is high or low depending on whether a tool can be used to perform the exploit. |
Cross-Site Scripting | High/Low | High/Low | As with SQL injection, the danger depends on where the code that is exploited is located and what it does. Also the skill level depends again on whether an attacker can simply use a tool successfully or a manual attack is needed. |
Payload Injection | High | High | The injection string must be first inserted as valid data for a trigger or later process to read it and place it into a SQL injection scenario. |
DDL injection | High/Low | High/Low | Similar to SQL Injection. |
PL/SQL Injection | High/Low | High/Low | Similar to SQL Injection. |
DML Injection | High/Low | High/Low | Similar to SQL Injection. |
Direct database access | High | Medium/High | Much harder, as the attacker needs IT skills and have to install a tool such as SQL*Plus, and would need to know at least Oracle TNS. |
Data loss | High/Low | High/Low | This depends on how and where the data is stolen. Low would be an employee simply stealing a paper report or printing a screen. High would be an attack against a web site and then working out how to target the data needed. |
Escalation of database rights | High | High | An attacker would need direct database access via a tool such as SQL*Plus or an exploit in a web site that allows SQL or PL/SQL Injection that would allow DDL to be injected. |
Access to operating system or network resources | High | High | An attacker would need elevated access to the database normally; then would need access to an account with OS or network access or would need skill to add the correct database objects. |
Audit trail changes | High | High | An attacker would need elevated access to the database normally; then would need access to the audit trails or an account that has access |