Next

LInteger Version 0.2: A Set of C++ Libraries Providing Support for Multiple Precision Integers

Copyright (C) 1996-7 by Leonard Janke (janke@unixg.ubc.ca)

Abstract

LInteger is a set of C++ libraries designed to support the manipulation of objects representing multiple precision integers. Thanks to C++'s support for operator overloading, the use of these multiple precision integers should be nearly as easy as the use of regular ints. The core multiple precision methods were hand-coded in i386+ assembly language for high speed, and should be easily convertable into C functions. Due to the extensive use of register/constraint oriented inline assembly code, the current version of this library will only compile under GNU's g++ compiler. In addition, the libraries have only been tested under the Linux and Windows NT operating systems, although it is anticipated that there should not be any difficultly compiling under Windows '95, and that compiling under OS/2 should require only minor hacking, if any.

Included in the set of libraries are the ChainHash and PRNG abstract base classes. These two classes provide support for chain hash functions and pseudo-random number generators, respectively. An included SHA1 class provides an example of a ChainHash subclass while at the same time providing an i386+ assembly based implementation of the Secure Hash Algorithm (FIPS 180-1). Also included is a SHA1PRNG class which provides a sample PRNG subclass, while simultaneously providing an implementation of a pseudo-random generator described in FIPS 186 and based on the Secure Hash Algorithm.


Next