diff options
author | Nick Mathewson <nickm@torproject.org> | 2017-02-07 08:39:07 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-02-07 08:39:07 -0500 |
commit | 8936c50d83f3a90fb6bb3314b86f56f46d42d749 (patch) | |
tree | 950ced8e6dbdb50676f9b618c6f327f7c7f2ffcb /src/common/tortls.c | |
parent | da0d5ad9830b22983864660ca1c732627e119747 (diff) | |
parent | 05ec055c417c80bf7b13914fade70a72f11accc5 (diff) | |
download | tor-8936c50d83f3a90fb6bb3314b86f56f46d42d749.tar.gz tor-8936c50d83f3a90fb6bb3314b86f56f46d42d749.zip |
Merge branch 'maint-0.2.5' into maint-0.2.6
Diffstat (limited to 'src/common/tortls.c')
-rw-r--r-- | src/common/tortls.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common/tortls.c b/src/common/tortls.c index 97a82bf6e1..379f7347db 100644 --- a/src/common/tortls.c +++ b/src/common/tortls.c @@ -2739,6 +2739,10 @@ dn_indicates_v3_cert(X509_NAME *name) len = ASN1_STRING_to_UTF8(&s, str); if (len < 0) return 0; + if (len < 4) { + OPENSSL_free(s); + return 1; + } r = fast_memneq(s + len - 4, ".net", 4); OPENSSL_free(s); return r; |