-
Notifications
You must be signed in to change notification settings - Fork 185
Open
Description
I was trying to migrate an old Perl script to Ruby, which receives a string consisting of a signature and the contents concatenated. The core of the script is like this:
my $sign_key = Crypt::OpenSSL::RSA->new_public_key($key_string);
my $signature = substr($data, 0, $sign_key->size, ''); # Cut off signature of $data
die "data wasn't signed correctly!\n" unless $sign_key->verify($data, $signature);There does not appear a way to get the size of the signature from Ruby. It should just be a call to EVP_PKEY_get_size
Metadata
Metadata
Assignees
Labels
No labels