[SCM] GNU gnutls branch, master, updated. gnutls_3_0_21-29-g8dcf133

"Nikos Mavrogiannopoulos" <[email protected]>
Newsgroups gmane.comp.encryption.gpg.gnutls.cvs
Message-ID <[email protected]>
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=8dcf133d55c6f97c1a5cb1267b1d6b463fb405f4

The branch, master has been updated
       via  8dcf133d55c6f97c1a5cb1267b1d6b463fb405f4 (commit)
      from  9eac1c562bdcf72b1cdc77026553f23aefc00f1b (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 8dcf133d55c6f97c1a5cb1267b1d6b463fb405f4
Author: Nikos Mavrogiannopoulos <[email protected]>
Date:   Fri Jul 13 17:36:19 2012 +0200

    Allow gnutls-cli to be used with tpmkey urls

-----------------------------------------------------------------------

Summary of changes:
 src/certtool-common.c |    2 +-
 src/cli.c             |   14 ++++++++++++++
 2 files changed, 15 insertions(+), 1 deletions(-)

diff --git a/src/certtool-common.c b/src/certtool-common.c
index f8c05bc..9dcca84 100644
--- a/src/certtool-common.c
+++ b/src/certtool-common.c
@@ -516,7 +516,7 @@ load_ca_private_key (common_info_st * info)
 #endif
 
 #ifdef HAVE_TROUSERS
-  if (strncmp(info->privkey, "tpmkey:", 7) == 0)
+  if (strncmp(info->ca_privkey, "tpmkey:", 7) == 0)
     return _load_tpm_privkey(info->privkey);
 #endif
 
diff --git a/src/cli.c b/src/cli.c
index 980c505..0e5f349 100644
--- a/src/cli.c
+++ b/src/cli.c
@@ -242,6 +242,20 @@ load_keys (void)
         }
       else
 #endif /* ENABLE_PKCS11 */
+#ifdef HAVE_TROUSERS
+      if (strncmp (x509_keyfile, "tpmkey:", 7) == 0)
+        {
+          ret =
+            gnutls_privkey_import_tpm_url (x509_key, x509_keyfile, NULL, NULL, 0);
+          if (ret < 0)
+            {
+              fprintf (stderr, "*** Error loading url: %s\n",
+                       gnutls_strerror (ret));
+              exit (1);
+            }
+        }
+      else
+#endif /* HAVE_TROUSERS */
         {
           ret = gnutls_load_file (x509_keyfile, &data);
           if (ret < 0)


hooks/post-receive
-- 
GNU gnutls
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.