projects
/
platform
/
upstream
/
libtasn1.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b32eae0
)
More precise length check in _asn1_get_indefinite_length_string().
author
Nikos Mavrogiannopoulos
<nmav@gnutls.org>
Fri, 16 May 2014 06:08:02 +0000
(08:08 +0200)
committer
Nikos Mavrogiannopoulos
<nmav@redhat.com>
Fri, 16 May 2014 06:55:08 +0000
(08:55 +0200)
lib/decoding.c
patch
|
blob
|
history
diff --git
a/lib/decoding.c
b/lib/decoding.c
index
813afc0
..
0e5077f
100644
(file)
--- a/
lib/decoding.c
+++ b/
lib/decoding.c
@@
-772,7
+772,7
@@
_asn1_get_indefinite_length_string (const unsigned char *der, int *len)
while (1)
{
- if (
(*len) < counter
)
+ if (
counter+1 >= *len
)
return ASN1_DER_ERROR;
if ((der[counter] == 0) && (der[counter + 1] == 0))