summaryrefslogtreecommitdiff
path: root/src/pluto/pkcs1.c
diff options
context:
space:
mode:
authorRene Mayrhofer <rene@mayrhofer.eu.org>2008-03-30 08:31:24 +0000
committerRene Mayrhofer <rene@mayrhofer.eu.org>2008-03-30 08:31:24 +0000
commit1c088a8b6237ec67f63c23f97a0f2dc4e99af869 (patch)
tree7fff7c8329d19bbaa910312e746a116f28fbfaf5 /src/pluto/pkcs1.c
parentbcc8f7ca7fd8e8ff6e8a4d579251458313133598 (diff)
downloadvyos-strongswan-1c088a8b6237ec67f63c23f97a0f2dc4e99af869.tar.gz
vyos-strongswan-1c088a8b6237ec67f63c23f97a0f2dc4e99af869.zip
[svn-upgrade] Integrating new upstream version, strongswan (4.1.11)
Diffstat (limited to 'src/pluto/pkcs1.c')
-rw-r--r--src/pluto/pkcs1.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/pluto/pkcs1.c b/src/pluto/pkcs1.c
index bb8afde0a..49a06a8bc 100644
--- a/src/pluto/pkcs1.c
+++ b/src/pluto/pkcs1.c
@@ -13,7 +13,7 @@
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* for more details.
*
- * RCSID $Id: pkcs1.c 3252 2007-10-06 21:24:50Z andreas $
+ * RCSID $Id: pkcs1.c 3427 2008-01-27 20:17:15Z andreas $
*/
#include <stddef.h>
@@ -442,11 +442,13 @@ RSA_encrypt(const RSA_public_key_t *key, chunk_t in)
*pos++ = 0x02;
/* pad with pseudo random bytes unequal to zero */
- get_rnd_bytes(pos, padding);
for (i = 0; i < padding; i++)
{
+ get_rnd_bytes(pos, padding);
while (!*pos)
- get_rnd_bytes(pos, 1);
+ {
+ get_rnd_bytes(pos, 1);
+ }
pos++;
}