summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSimon Josefsson <simon@josefsson.org>2008-02-18 15:22:01 +0100
committerSimon Josefsson <simon@josefsson.org>2008-02-18 15:22:01 +0100
commitb840325603be84cbc66efc99a3c75754268c6409 (patch)
treeffe201f3c401b0b942cbed233ca6dd90d0730371 /lib
parentb1a9bf3360772de026af9a9972b02229e66daac5 (diff)
downloadgnutls-b840325603be84cbc66efc99a3c75754268c6409.tar.gz
Re-add gnutls_openpgp_crt_get_id to avoid breaking ABI.
Diffstat (limited to 'lib')
-rw-r--r--lib/openpgp/pgp.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/lib/openpgp/pgp.c b/lib/openpgp/pgp.c
index d36a5c34c9..825521218e 100644
--- a/lib/openpgp/pgp.c
+++ b/lib/openpgp/pgp.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation
+ * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation
*
* Author: Timo Schulz, Nikos Mavrogiannopoulos
*
@@ -472,6 +472,24 @@ gnutls_openpgp_crt_get_key_id (gnutls_openpgp_crt_t key, gnutls_openpgp_keyid_t*
}
/**
+ * gnutls_openpgp_crt_get_id - Gets the keyID
+ * @key: the structure that contains the OpenPGP public key.
+ * @keyid: the buffer to save the keyid.
+ *
+ * Returns the 64-bit keyID of the OpenPGP key.
+ *
+ * Deprecated: Use gnutls_openpgp_crt_get_key_id() instead.
+ **/
+int
+gnutls_openpgp_crt_get_id (gnutls_openpgp_crt_t key, unsigned char keyid[8])
+{
+ gnutls_openpgp_keyid_t tmp;
+ int ret = gnutls_openpgp_crt_get_key_id (key, &tmp);
+ memcpy (keyid, tmp.keyid, sizeof (tmp.keyid));
+ return ret;
+}
+
+/**
* gnutls_openpgp_crt_get_revoked_status - Gets the revoked status of the key
* @key: the structure that contains the OpenPGP public key.
*