[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[SCM] GNU gnutls branch, gnutls_3_0_x, updated. gnutls_3_0_1-83-gceb4f32
From: |
Simon Josefsson |
Subject: |
[SCM] GNU gnutls branch, gnutls_3_0_x, updated. gnutls_3_0_1-83-gceb4f32 |
Date: |
Tue, 06 Sep 2011 10:11:41 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU gnutls".
http://git.savannah.gnu.org/cgit/gnutls.git/commit/?id=ceb4f32c9417ab44a2df831c306d7329eb5a1fce
The branch, gnutls_3_0_x has been updated
via ceb4f32c9417ab44a2df831c306d7329eb5a1fce (commit)
from 80aaf33d85be24708d11c2f9f3bdada0cab49065 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit ceb4f32c9417ab44a2df831c306d7329eb5a1fce
Author: Simon Josefsson <address@hidden>
Date: Tue Sep 6 12:09:03 2011 +0200
libgnutls: Allow CA importing of 0 certificates to succeed.
Reported by Jonathan Nieder <address@hidden> in
<http://bugs.debian.org/640639>.
-----------------------------------------------------------------------
Summary of changes:
NEWS | 4 ++++
lib/x509/x509.c | 4 +++-
tests/parse_ca.c | 9 ++++++++-
3 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/NEWS b/NEWS
index 4d787a3..419bb85 100644
--- a/NEWS
+++ b/NEWS
@@ -2,6 +2,10 @@ GnuTLS NEWS -- History of user-visible changes.
-*- outline -*-
Copyright (C) 2000-2011 Free Software Foundation, Inc.
See the end for copying conditions.
+** libgnutls: Allow CA importing of 0 certificates to succeed.
+Reported by Jonathan Nieder <address@hidden> in
+<http://bugs.debian.org/640639>.
+
* Version 3.0.2 (released 2011-09-01)
** libgnutls: OpenPGP certificate type is not enabled
diff --git a/lib/x509/x509.c b/lib/x509/x509.c
index 606d44f..9d85384 100644
--- a/lib/x509/x509.c
+++ b/lib/x509/x509.c
@@ -3219,7 +3219,9 @@ gnutls_x509_crt_list_import (gnutls_x509_crt_t * certs,
if (ptr == NULL)
{
gnutls_assert ();
- return GNUTLS_E_BASE64_DECODING_ERROR;
+ *cert_max = 0;
+ /* no certificate found, likely empty file or garbage input */
+ return 0;
}
count = 0;
diff --git a/tests/parse_ca.c b/tests/parse_ca.c
index 9f81887..42d9eb3 100644
--- a/tests/parse_ca.c
+++ b/tests/parse_ca.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2007, 2010 Free Software Foundation, Inc.
+ * Copyright (C) 2007, 2010, 2011 Free Software Foundation, Inc.
*
* Author: Simon Josefsson
*
@@ -72,6 +72,13 @@ doit (void)
if (rc != 2)
fail ("import ca failed: %d\n", rc);
+ ca.data = (unsigned char*) "";
+ ca.size = 0;
+
+ rc = gnutls_certificate_set_x509_trust_mem (cred, &ca, GNUTLS_X509_FMT_PEM);
+ if (rc != 0)
+ fail ("import ca failed: %d\n", rc);
+
gnutls_certificate_free_credentials (cred);
gnutls_global_deinit ();
hooks/post-receive
--
GNU gnutls
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [SCM] GNU gnutls branch, gnutls_3_0_x, updated. gnutls_3_0_1-83-gceb4f32,
Simon Josefsson <=