RE: PKINIT for gsissh
Ali Gholami <[email protected]>
| Newsgroups | gmane.comp.encryption.kerberos.heimdal.general |
|---|---|
| Message-ID | <[email protected]> |
-----Original Message----- From: Ali Gholami ([email protected]) Sent: den 4 oktober 2011 11:36 To: Love Hörnquist Åstrand Cc: <[email protected]> Subject: RE: PKINIT for gsissh Hi Love, > I noticed there is a two pointer comparison in hx509/crypto.c where the execution point goes and error occurs afterwards: > > if (indata.data != data->data) > der_free_octet_string(&indata); > if (ret <= 0) { > > ret = HX509_CMS_FAILED_CREATE_SIGATURE; > hx509_set_error_string(context, 0, ret, > "RSA private encrypt failed: %d", ret); > return ret; > } > > The memory traces show there is always two different values for indata.data and data->data and ret is set to -2 before line " ret = HX509_CMS_FAILED_CREATE_SIGATURE". Do you know the reason for this comparison in the if condition? if you use hcrypto (not openssl), its that your key is smaller then digest size before or after adding padding. You have tiny rsa keys ? Well, when I debug it, I see "indata.length = 83" and "sig->data" which I think is the "rsa" size equal to 64. My question was the purpose of this if clause: "if (indata.data != data->data)". Ali