summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/decoding.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/decoding.c b/lib/decoding.c
index 8f6fe8a..54f0167 100644
--- a/lib/decoding.c
+++ b/lib/decoding.c
@@ -1581,6 +1581,9 @@ asn1_der_decoding_startEnd (asn1_node element, const void *ider, int ider_len,
*end = node_to_find->end;
}
+ if (*end < *start)
+ return ASN1_GENERIC_ERROR;
+
return ASN1_SUCCESS;
}