search menu icon-carat-right cmu-wordmark

As-if Infinitely Ranged Integer Model

Technical Note
In this report, the authors present the as-if infinitely ranged (AIR) integer model, which eliminates integer overflow and integer truncation in C and C++ code.
Publisher

Software Engineering Institute

CMU/SEI Report Number
CMU/SEI-2009-TN-023

Abstract

Integer overflow and wraparound are major causes of software vulnerabilities in the C and C++ programming languages. In this paper we present the as-if infinitely ranged (AIR) integer model, which provides a largely automated mechanism for eliminating integer overflow and integer truncation. The AIR integer model either produces a value equivalent to one that would have been obtained using infinitely ranged integers or results in a runtime constraint violation. Unlike previous integer models, AIR integers do not require precise traps, and consequently do not break or inhibit most existing optimizations.

Prototype
GCC 4.5.0

Cite This Technical Note

Keaton, D., Plum, T., Seacord, R., Svoboda, D., Volkovitsky, A., & Wilson, T. (2009, July 1). As-if Infinitely Ranged Integer Model. (Technical Note CMU/SEI-2009-TN-023). Retrieved May 21, 2024, from https://insights.sei.cmu.edu/library/as-if-infinitely-ranged-integer-model/.

@techreport{keaton_2009,
author={Keaton, David and Plum, Thomas and Seacord, Robert and Svoboda, David and Volkovitsky, Alex and Wilson, Timothy},
title={As-if Infinitely Ranged Integer Model},
month={Jul},
year={2009},
number={CMU/SEI-2009-TN-023},
howpublished={Carnegie Mellon University, Software Engineering Institute's Digital Library},
url={https://insights.sei.cmu.edu/library/as-if-infinitely-ranged-integer-model/},
note={Accessed: 2024-May-21}
}

Keaton, David, Thomas Plum, Robert Seacord, David Svoboda, Alex Volkovitsky, and Timothy Wilson. "As-if Infinitely Ranged Integer Model." (CMU/SEI-2009-TN-023). Carnegie Mellon University, Software Engineering Institute's Digital Library. Software Engineering Institute, July 1, 2009. https://insights.sei.cmu.edu/library/as-if-infinitely-ranged-integer-model/.

D. Keaton, T. Plum, R. Seacord, D. Svoboda, A. Volkovitsky, and T. Wilson, "As-if Infinitely Ranged Integer Model," Carnegie Mellon University, Software Engineering Institute's Digital Library. Software Engineering Institute, Technical Note CMU/SEI-2009-TN-023, 1-Jul-2009 [Online]. Available: https://insights.sei.cmu.edu/library/as-if-infinitely-ranged-integer-model/. [Accessed: 21-May-2024].

Keaton, David, Thomas Plum, Robert Seacord, David Svoboda, Alex Volkovitsky, and Timothy Wilson. "As-if Infinitely Ranged Integer Model." (Technical Note CMU/SEI-2009-TN-023). Carnegie Mellon University, Software Engineering Institute's Digital Library, Software Engineering Institute, 1 Jul. 2009. https://insights.sei.cmu.edu/library/as-if-infinitely-ranged-integer-model/. Accessed 21 May. 2024.

Keaton, David; Plum, Thomas; Seacord, Robert; Svoboda, David; Volkovitsky, Alex; & Wilson, Timothy. As-if Infinitely Ranged Integer Model. CMU/SEI-2009-TN-023. Software Engineering Institute. 2009. https://insights.sei.cmu.edu/library/as-if-infinitely-ranged-integer-model/