What you may be missing is the "data padding" stuff, which makes
the encrypted payload somewhat longer than just what you pass off
to the encoding routine. IIRC it throws an 8-sided die and prepends
to the messate either
01
02 02
03 03 03
...
08 08 08 08 08 08 08 08
also there may be some length fields or something -- consider the
fact that the message "0" will ALWAYS encrypt as "0" while the
message "1" will ALWAYS encrypt as "1" (!) so you REALLY DO want
to mix in some (at-end-ignorable) randomness. If nothing else,
to prevent computing the cyphertext of all possible 64 bit
messages into a decrypt dictionary. This is a brute force
technique to be sure, but it is doable...
Jesse Hammons wrote:
Jesse Hammons wrote:
So to clarify: If I generate a 65-bit key, will I be able to use that
65-bit key to sign any 64-bit value?
Yes, but
Actually, I have found the answer to be "no" :-)
a 65 bit key won't be very secure AT ALL, it will be
very easy to factor a modulus that small.
Security is not my goal. This is more of a theoretical exercise that
happens to have a practical application for me.
Bottom line: asymmetrical
(public-key) encryption has a fairly large "minimum block size" that
actually increases as key size increases.
Indeed. I have found experimentally that:
* The minimum signable data quantity in OpenSSL is 1 byte
* The minimum size RSA key that can be used to sign 1 byte is 89 bits
* A signature created using a 64-bit RSA key would create a number 64
bits long, BUT:
- This is not possible to do in OpenSSL because the maximum signable
quantity for a 64
bit RSA key is only a few bits, and OpenSSL input/output is done on
byte boundaries
Do those number sound right?
Thanks,
-Jesse
______________________________________________________________________
OpenSSL Project http://www.openssl.org
User Support Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]
--
"An Internet-connected Windows machine is tantamount to
a toddler carrying a baggie of $100 bills down a city street..."
Charles B (Ben) Cranston
mailto: [EMAIL PROTECTED]
http://www.wam.umd.edu/~zben
______________________________________________________________________
OpenSSL Project http://www.openssl.org
User Support Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]