Mark Webb asked: > I have a program that creates a fixed format file. The file > gets created by a > client process and verified by the server process. In order > to parse the > file, I need to know the size of each field. The digital > signatures that I > am creating vary in the 92-96 character range. Is there a > theoretical > maximum size of a digital signature?
For RSA, the signature will be the same size as the modulus (commonly referred to as n), because the signature calculation is mod n. For example, if you generate an RSA key pair with a 512-bit modulus, the private key will generate signatures of size 512 bits or 64 octets. If you generate an RSA key pair with a 1024-bit modulus, the private key will generate signatures of size 1024 bits or 128 octets. Because some big number libraries "think" in terms of signed integers, some big number libraries insert a leading octet with the value 0 if the most significant bit of a big integer is on. So I would always allocate a few extra bytes for the buffer to hold the signature. Frank > -----Original Message----- > From: Mark W. Webb [mailto:[EMAIL PROTECTED]] > Sent: Monday, February 25, 2002 10:27 AM > To: [EMAIL PROTECTED] > Subject: max size of digital signature > > > I have a program that creates a fixed format file. The file > gets created by a > client process and verified by the server process. In order > to parse the > file, I need to know the size of each field. The digital > signatures that I > am creating vary in the 92-96 character range. Is there a > theoretical > maximum size of a digital signature? > > thank you. > -- > Mark Webb > Software Engineer > Dolphin Technology > 1300B Floyd Ave > Rome, NY 13440 > > Phone: (315) 334-4892 x222 > Fax: (315) 339-4846 > Email: [EMAIL PROTECTED] > ______________________________________________________________________ > OpenSSL Project http://www.openssl.org > Development Mailing List [EMAIL PROTECTED] > Automated List Manager [EMAIL PROTECTED] > ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]
