Closed
Bug 174006
Opened 22 years ago
Closed 22 years ago
flawfinder warnings in MAPI
Categories
(MailNews Core :: Simple MAPI, defect)
Tracking
(Not tracked)
VERIFIED
INVALID
People
(Reporter: morse, Assigned: rdayal)
References
Details
Heikki ran flawfinder (http://www.dwheeler.com/flawfinder) on Mozilla 1.0.1 branch. flawfinder found 19 warnings in MAPI code (3818-3836). Go through that list and for each warning: * If it is false positive, comment here why it is not an issue * If it is a real issue, make patch for it here and let's get them checked in In addition to checking the branch, also check the trunk. 3818) mailnews/mapi/old/hook/mapihook.cpp:1115 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3819) mailnews/mapi/old/hook/mapihook.cpp:1117 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3820) mailnews/mapi/old/hook/mapihook.cpp:1119 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3821) mailnews/mapi/old/hook/mapihook.cpp:1121 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3822) mailnews/mapi/old/lib/nsstrseq.cpp:119 [4] (buffer) strcpy: does not check for buffer overflows. Consider using strncpy or strlcpy. 3823) mailnews/mapi/old/mapi32/mapi32.cpp:924 [4] (buffer) strcpy: does not check for buffer overflows. Consider using strncpy or strlcpy. 3824) mailnews/mapi/old/mapi32/mapi32.cpp:963 [4] (buffer) strcpy: does not check for buffer overflows. Consider using strncpy or strlcpy. 3825) mailnews/mapi/old/mapi32/mapi32.cpp:1049 [4] (buffer) strcpy: does not check for buffer overflows. Consider using strncpy or strlcpy. 3826) mailnews/mapi/old/mapi32/mapi32.cpp:2079 [4] (buffer) strcpy: does not check for buffer overflows. Consider using strncpy or strlcpy. 3827) mailnews/mapi/old/mapi32/mapiutl.cpp:73 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3828) mailnews/mapi/old/mapi32/mapiutl.cpp:75 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3829) mailnews/mapi/old/mapi32/mapiutl.cpp:158 [3] (random) srand: This function is not sufficiently random for security-related functions such as key and nonce creation. use a more secure technique for acquiring random values. 3830) mailnews/mapi/old/mapi32/mapiutl.cpp:349 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3831) mailnews/mapi/old/mapi32/mapiutl.cpp:351 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3832) mailnews/mapi/old/mapi32/mapiutl.cpp:353 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3833) mailnews/mapi/old/mapi32/mapiutl.cpp:355 [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once.. Check environment variables carefully before using them. 3834) mailnews/mapi/old/mapi32/xpapi.cpp:78 [4] (race) access: this usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition. Set up the correct permissions (e.g., using setuid()) and try to open the file directly. 3835) mailnews/mapi/old/mapi32/xpapi.cpp:82 [4] (race) access: this usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition. Set up the correct permissions (e.g., using setuid()) and try to open the file directly. 3836) mailnews/mapi/old/mapi32/xpapi.h:127 [4] (race) access: this usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition. Set up the correct permissions (e.g., using setuid()) and try to open the file directly.
Assignee | ||
Comment 1•22 years ago
|
||
All the 19 warnings noted here is in obsolete MAPI code, this code is in dir mapi/old and is not used in Mozilla at all. This code existed in Mozilla even before MAPI implementation started in Mozilla, none of these files are used.
Reporter | ||
Comment 2•22 years ago
|
||
Closing out as invalid per comment #1. I should have caught the fact that the /old/ was in the path name before filing this report.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → INVALID
QA Contact: yulian → stephend
Updated•20 years ago
|
Product: MailNews → Core
Updated•16 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•