From 64b456df594037eb695f368ab60b6149ae469194 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moise=CC=81s=20Guimara=CC=83es?= Date: Mon, 22 Dec 2014 12:07:46 -0300 Subject: [PATCH 1/2] Fixes #137 --- src/ssl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ssl.c b/src/ssl.c index faedcb02c..3655e3668 100644 --- a/src/ssl.c +++ b/src/ssl.c @@ -2026,7 +2026,7 @@ int PemToDer(const unsigned char* buff, long longSz, int type, header = BEGIN_ENC_PRIV_KEY; footer = END_ENC_PRIV_KEY; } else if (header == BEGIN_ENC_PRIV_KEY) { header = BEGIN_EC_PRIV; footer = END_EC_PRIV; - } else if (header == BEGIN_ENC_PRIV_KEY) { + } else if (header == BEGIN_EC_PRIV) { header = BEGIN_DSA_PRIV; footer = END_DSA_PRIV; } else break; From 98cefa88c4a30b44847db5e0a30c3497a1f92c99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Moise=CC=81s=20Guimara=CC=83es?= Date: Mon, 22 Dec 2014 12:17:11 -0300 Subject: [PATCH 2/2] Fixes #136 --- src/internal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/internal.c b/src/internal.c index 5a717e43e..aa959c07e 100644 --- a/src/internal.c +++ b/src/internal.c @@ -12281,7 +12281,7 @@ int DoSessionTicket(CYASSL* ssl, ERROR_OUT(MEMORY_E, done_b); #endif - if ((ret = InitSha(sha) != 0)) + if ((ret = InitSha(sha)) != 0) goto done_b; ShaUpdate(sha, ssl->arrays->clientRandom, RAN_LEN);