asn1: Make sure not to exceed buffer for binary OID

This commit is contained in:
Tobias Brunner
2014-09-09 10:56:15 +02:00
parent f80093e2ee
commit 4df9250f26
+1 -1
View File
@@ -139,7 +139,7 @@ chunk_t asn1_oid_from_string(char *str)
while (enumerator->enumerate(enumerator, &str))
{
val = strtoul(str, &end, 10);
if (end == str || pos > buf_len-4)
if (end == str || pos > buf_len-5)
{
pos = 0;
break;