summaryrefslogtreecommitdiffstats
path: root/src/crypto
diff options
context:
space:
mode:
authorMichael Brown2007-02-01 03:20:35 +0100
committerMichael Brown2007-02-01 03:20:35 +0100
commit5c3837e0ed91277ca05b0efd08459076a3661528 (patch)
treecb32cc9aed11d10653b369fe1dac758a7d920a3c /src/crypto
parentAdd dummy setiv method (diff)
downloadipxe-5c3837e0ed91277ca05b0efd08459076a3661528.tar.gz
ipxe-5c3837e0ed91277ca05b0efd08459076a3661528.tar.xz
ipxe-5c3837e0ed91277ca05b0efd08459076a3661528.zip
Quick hacks to get it working
Diffstat (limited to 'src/crypto')
-rw-r--r--src/crypto/axtls/rsa.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/crypto/axtls/rsa.c b/src/crypto/axtls/rsa.c
index 60b36891..69db9ae7 100644
--- a/src/crypto/axtls/rsa.c
+++ b/src/crypto/axtls/rsa.c
@@ -273,7 +273,10 @@ int RSA_encrypt(RSA_CTX *ctx, const uint8_t *in_data, uint16_t in_len,
else /* randomize the encryption padding with non-zero bytes */
{
out_data[1] = 2;
+ memset(&out_data[2], 0x01, num_pads_needed);
+#if 0
get_random_NZ(num_pads_needed, &out_data[2]);
+#endif
}
out_data[2+num_pads_needed] = 0;
@@ -287,6 +290,8 @@ int RSA_encrypt(RSA_CTX *ctx, const uint8_t *in_data, uint16_t in_len,
return byte_size;
}
+#if 0
+
/**
* Take a signature and decrypt it.
*/
@@ -328,4 +333,6 @@ bigint *RSA_sign_verify(BI_CTX *ctx, const uint8_t *sig, int sig_len,
return bir;
}
+#endif
+
#endif /* CONFIG_SSL_CERT_VERIFICATION */