CWE-779: Logging of Excessive Data
The product logs too much information, making log files hard to process and possibly hindering recovery efforts or forensic analysis after an attack.
How it's found
Logging of Excessive Data is typically found by tracing untrusted input from where it enters the system to the point where it is used without the check or neutralization this weakness describes, combining manual code review with dynamic testing.
While logging is a good practice in general, and very high levels of logging are appropriate for debugging stages of development, too much logging in a production environment might hinder a system administrator's ability to detect anomalous conditions. This can provide cover for an attacker while attempting to penetrate a system, clutter the audit trail for forensic analysis, or make it more difficult to debug problems in a production environment.
Consequences
- DoS: Resource Consumption (CPU), DoS: Resource Consumption (Other): Log files can become so large that they consume excessive resources, such as disk and CPU, which can hinder the performance of the system.
- Hide Activities: Logging too much information can make the log files of less use to forensics analysts and developers when trying to diagnose a problem or recover from an attack.
- Hide Activities: If system administrators are unable to effectively process log files, attempted attacks may go undetected, possibly leading to eventual system compromise.
Mitigations
- Architecture and Design: Suppress large numbers of duplicate log messages and replace them with periodic summaries. For example, syslog may include an entry that states "last message repeated X times" when recording repeated events.
- Architecture and Design: Support a maximum size for the log file that can be controlled by the administrator. If the maximum size is reached, the admin should be notified. Also, consider reducing functionality of the product. This may result in a denial-of-service to legitimate product users, but it will prevent the product from adversely impacting the entire system.
- Implementation: Adjust configurations appropriately when the product is transitioned from a debug state to production.
Where this fits in a TurboPentest engagement
This weakness is not covered by the automated black-box pentest. IntegSec pentesters cover it in a manual engagement.
Frequently asked questions
What is CWE-779?
The product logs too much information, making log files hard to process and possibly hindering recovery efforts or forensic analysis after an attack.
How do you find Logging of Excessive Data?
Logging of Excessive Data is typically found by tracing untrusted input from where it enters the system to the point where it is used without the check or neutralization this weakness describes, combining manual code review with dynamic testing.
What is the impact of CWE-779?
DoS: Resource Consumption (CPU), DoS: Resource Consumption (Other): Log files can become so large that they consume excessive resources, such as disk and CPU, which can hinder the performance of the system. Hide Activities: Logging too much information can make the log files of less use to forensics analysts and developers when trying to diagnose a problem or recover from an attack. Hide Activities: If system administrators are unable to effectively process log files, attempted attacks may go undetected, possibly leading to eventual system compromise.
Does TurboPentest test for Logging of Excessive Data?
This weakness is not covered by the automated black-box pentest. IntegSec pentesters cover it in a manual engagement.
Related CWEs
Written and reviewed by
Michel Chamberland - Founder & CEO, IntegSec
CISSP, OSCP, OSCE, CEH, GIAC, CCSK · 20+ years in offensive security
Michel has spent 20+ years on offensive security teams including IBM X-Force Red and Trustwave SpiderLabs, leading penetration tests, red team engagements, and breach response for Fortune 500 customers. He is the founder of IntegSec and the architect of TurboPentest.
Find these issues before an attacker does
TurboPentest runs an agentic AI pentest against your target and reports findings with proof, from $99 per target.
Start a pentest