summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2011-01-15 19:17:24 +0100
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2011-01-15 19:17:24 +0100
commitb2d19eb2fa0cf5b40f91d004c6153bc8f06e644b (patch)
tree4e81f3a27724f2836f833bea39f3d5f8dfbb1897
parent59b6fb0c5390de21670e9e24c07275291ec7f270 (diff)
downloadgnutls-b2d19eb2fa0cf5b40f91d004c6153bc8f06e644b.tar.gz
Deprecated gnutls_x509_crq_sign2() and gnutls_x509_crq_sign() in
favor for gnutls_x509_crq_privkey_sign().
-rw-r--r--NEWS2
-rw-r--r--lib/includes/gnutls/compat.h8
-rw-r--r--lib/includes/gnutls/x509.h5
-rw-r--r--lib/x509/crq.c6
4 files changed, 14 insertions, 7 deletions
diff --git a/NEWS b/NEWS
index 844e76764e..f19ecb5184 100644
--- a/NEWS
+++ b/NEWS
@@ -30,6 +30,8 @@ gnutls_pubkey_import_privkey: ADDED
gnutls_pubkey_verify_data: ADDED
gnutls_privkey_sign_hash2: ADDED
gnutls_privkey_sign_data2: ADDED (in place of gnutls_privkey_sign_data)
+gnutls_x509_crq_sign2: DEPRECATED
+gnutls_x509_crq_sign: DEPRECATED
gnutls_x509_privkey_sign_data: DEPRECATED
gnutls_x509_privkey_sign_hash: DEPRECATED
gnutls_x509_privkey_verify_data: DEPRECATED
diff --git a/lib/includes/gnutls/compat.h b/lib/includes/gnutls/compat.h
index befae6f1ed..f698af8ef0 100644
--- a/lib/includes/gnutls/compat.h
+++ b/lib/includes/gnutls/compat.h
@@ -271,6 +271,14 @@ gnutls_sign_callback_get (gnutls_session_t session, void **userdata)
* hash,
unsigned int *mand)
_GNUTLS_GCC_ATTR_DEPRECATED;
+ /* gnutls_x509_crq_privkey_sign() */
+ int gnutls_x509_crq_sign2 (gnutls_x509_crq_t crq,
+ gnutls_x509_privkey_t key,
+ gnutls_digest_algorithm_t dig,
+ unsigned int flags)
+ _GNUTLS_GCC_ATTR_DEPRECATED;
+ int gnutls_x509_crq_sign (gnutls_x509_crq_t crq, gnutls_x509_privkey_t key)
+ _GNUTLS_GCC_ATTR_DEPRECATED;
#endif /* _GNUTLS_COMPAT_H */
diff --git a/lib/includes/gnutls/x509.h b/lib/includes/gnutls/x509.h
index 579bb91605..e6866ed540 100644
--- a/lib/includes/gnutls/x509.h
+++ b/lib/includes/gnutls/x509.h
@@ -741,11 +741,6 @@ extern "C"
int gnutls_x509_crq_get_version (gnutls_x509_crq_t crq);
int gnutls_x509_crq_set_key (gnutls_x509_crq_t crq,
gnutls_x509_privkey_t key);
- int gnutls_x509_crq_sign2 (gnutls_x509_crq_t crq,
- gnutls_x509_privkey_t key,
- gnutls_digest_algorithm_t dig,
- unsigned int flags);
- int gnutls_x509_crq_sign (gnutls_x509_crq_t crq, gnutls_x509_privkey_t key);
int gnutls_x509_crq_set_challenge_password (gnutls_x509_crq_t crq,
const char *pass);
diff --git a/lib/x509/crq.c b/lib/x509/crq.c
index 577d7e2c3c..e96facb4e9 100644
--- a/lib/x509/crq.c
+++ b/lib/x509/crq.c
@@ -1003,6 +1003,8 @@ gnutls_x509_crq_set_challenge_password (gnutls_x509_crq_t crq,
* the digest algorithm to use with the specified public key
* algorithm.
*
+ * Deprecated: Use gnutls_x509_crq_privkey_sign() instead.
+ *
* Returns: %GNUTLS_E_SUCCESS on success, otherwise an error.
* %GNUTLS_E_ASN1_VALUE_NOT_FOUND is returned if you didn't set all
* information in the certificate request (e.g., the version using
@@ -1051,7 +1053,7 @@ fail:
return result;
}
-/**
+/*-
* gnutls_x509_crq_sign:
* @crq: should contain a #gnutls_x509_crq_t structure
* @key: holds a private key
@@ -1061,7 +1063,7 @@ fail:
*
* Returns: On success, %GNUTLS_E_SUCCESS is returned, otherwise a
* negative error value.
- **/
+ -*/
int
gnutls_x509_crq_sign (gnutls_x509_crq_t crq, gnutls_x509_privkey_t key)
{