[Forgot Password]
Login  Register Subscribe

30389

 
 

423868

 
 

244625

 
 

909

 
 

193379

 
 

277

Paid content will be excluded from the download.


Download | Alert*
CWE
view XML

Incorrect Type Conversion or Cast

ID: 704Date: (C)2012-05-14   (M)2022-10-10
Type: weaknessStatus: INCOMPLETE
Abstraction Type: Class





Description

The software does not correctly convert an object, resource or structure from one type to a different type.

Applicable Platforms
Language: Often
Language: C
Language: Often
Language: C++
Language Class: All

Time Of Introduction

  • Architecture and Design
  • Implementation

Common Consequences

ScopeTechnical ImpactNotes
Other
 
Other
 
 

Detection Methods
None

Potential Mitigations
None

Relationships

Related CWETypeViewChain
CWE-704 ChildOf CWE-885 Category CWE-888  

Demonstrative Examples
None

White Box Definitions
None

Black Box Definitions
None

Taxynomy Mappings

TaxynomyIdNameFit
CERT C Secure Coding EXP05-C
 
Do not cast away a const qualification
 
 
CERT C Secure Coding MSC31-C
 
Ensure that return values are compared against the proper type
 
 
CERT C Secure Coding STR34-C
 
Cast characters to unsigned types before converting to larger integer sizes
 
 
CERT C Secure Coding STR37-C
 
Arguments to character handling functions must be representable as an unsigned char
 
 
CERT C++ Secure Coding STR34-CPP
 
Cast characters to unsigned types before converting to larger integer sizes
 
 
CERT C++ Secure Coding STR37-CPP
 
Arguments to character handling functions must be representable as an unsigned char
 
 
CERT C++ Secure Coding MSC31-CPP
 
Ensure that return values are compared against the proper type
 
 

References:
None

CVE    184
CVE-2011-1460
CVE-2011-1200
CVE-2011-1441
CVE-2011-0483
...

© SecPod Technologies