1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
From: =?utf-8?q?Ferenc_W=C3=A1gner?= <wferi@niif.hu>
Date: Sat, 30 Jan 2016 23:11:00 +0100
Subject: loadX509PEM: fix potential reading past unterminated buffer
---
xsec/enc/XSECCryptoX509.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/xsec/enc/XSECCryptoX509.cpp b/xsec/enc/XSECCryptoX509.cpp
index f87f746..2682e70 100644
--- a/xsec/enc/XSECCryptoX509.cpp
+++ b/xsec/enc/XSECCryptoX509.cpp
@@ -46,7 +46,7 @@ void XSECCryptoX509::loadX509PEM(const char * buf, unsigned int len) {
b = b1;
}
- const char *p = strstr(buf, "-----BEGIN CERTIFICATE-----");
+ const char *p = strstr(b, "-----BEGIN CERTIFICATE-----");
if (p == NULL) {
|