[Determine Application's Log File Format] The first step is exploratory meaning the attacker observes the system. The attacker looks for action and data that are likely to be logged. The attacker may be familiar with the log format of the system.
[Manipulate Log Files] The attacker alters the log contents either directly through manipulation or forging or indirectly through injection of specially crafted input that the target software will write to the logs. This type of attack typically follows another attack and is used to try to cover the traces of the previous attack.
Use carriage return and/or line feed characters to start a new line in the log file, and then, add a fake entry. For example:
may add the following forged entry into a log file:
Different applications may require different encodings of the carriage return and line feed characters.
Insert a script into the log file such that if it is viewed using a web browser, the attacker will get a copy of the operator/administrator's cookie and will be able to gain access as that user. For example, a log file entry could contain
The script itself will be invisible to anybody viewing the logs in a web browser (unless they view the source for the page).
Nom de la faiblesse | |
---|---|
CWE-117 |
Improper Output Neutralization for Logs The product does not neutralize or incorrectly neutralizes output that is written to logs. |
CWE-75 |
Failure to Sanitize Special Elements into a Different Plane (Special Element Injection) The product does not adequately filter user-controlled input for special elements with control implications. |
CWE-150 |
Improper Neutralization of Escape, Meta, or Control Sequences The product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could be interpreted as escape, meta, or control character sequences when they are sent to a downstream component. |
Nom | Organisation | Date | Date de publication |
---|---|---|---|
CAPEC Content Team | The MITRE Corporation |
Nom | Organisation | Date | Commentaire |
---|---|---|---|
CAPEC Content Team | The MITRE Corporation | Updated References | |
CAPEC Content Team | The MITRE Corporation | Updated Related_Attack_Patterns, Related_Weaknesses | |
CAPEC Content Team | The MITRE Corporation | Updated Examples-Instances, References | |
CAPEC Content Team | The MITRE Corporation | Updated Description, Mitigations, Related_Attack_Patterns | |
CAPEC Content Team | The MITRE Corporation | Updated Related_Weaknesses | |
CAPEC Content Team | The MITRE Corporation | Updated Example_Instances, Execution_Flow, Taxonomy_Mappings |