557
This code logs suspicious multiple login attempts.
Example Language: PHP (Bad)
function login($userName,$password){
if(authenticate($userName,$password)){
return True;
}
else{
incrementLoginAttempts($userName);
if(recentLoginAttempts($userName) > 5){
writeLog("Failed login attempt by User: " . $userName . " at " + date('r') );
}
}
}
This code only logs failed login attempts when a certain limit is reached. If an attacker knows this
limit, they can stop their attack from being discovered by avoiding the limit.
Observed Examples
Reference Description
CVE-2004-2227 Web browser's filename selection dialog only shows the beginning portion
of long filenames, which can trick users into launching executables with
dangerous extensions.
https://www.cve.org/CVERecord?id=CVE-2004-2227
CVE-2003-0412 application server does not log complete URI of a long request (truncation).
https://www.cve.org/CVERecord?id=CVE-2003-0412
CVE-1999-1029 Login attempts are not recorded if the user disconnects before the maximum
number of tries.
https://www.cve.org/CVERecord?id=CVE-1999-1029
CVE-2002-0725 Attacker performs malicious actions on a hard link to a file, obscuring the real
target file.
https://www.cve.org/CVERecord?id=CVE-2002-0725
CVE-1999-1055 Product does not warn user when document contains certain dangerous
functions or macros.
https://www.cve.org/CVERecord?id=CVE-1999-1055
MemberOf Relationships
This MemberOf relationships table shows additional CWE Catgeories and Views that reference this
weakness as a member. This information is often useful in understanding where a weakness fits
within the context of external information sources.
Nature Type ID Name Page
MemberOf 997 SFP Secondary Cluster: Information Loss 888 2418
MemberOf 1416 Comprehensive Categorization: Resource Lifecycle
Management
1400 2545
Taxonomy Mappings
Mapped Taxonomy Name Node ID Fit Mapped Node Name
PLOVER Information loss or omission
Related Attack Patterns
CAPEC-ID Attack Pattern Name
81 Web Server Logs Tampering
CWE-222: Truncation of Security-relevant Information
CWE Version 4.14
CWE-222: Truncation of Security-relevant Information
CWE-222: Truncation of Security-relevant Information