diff options
author | Adriaan de Jong <dejong@fox-it.com> | 2012-02-14 11:11:26 +0100 |
---|---|---|
committer | David Sommerseth <davids@redhat.com> | 2012-03-30 22:56:47 +0200 |
commit | 8e5613c2a8545a67cab2734569a8f088100d731b (patch) | |
tree | 42a77658488bad5ef3b2494d532d269ebfdb2bfb /src/openvpn/ssl_verify_backend.h | |
parent | 025f30d7c6434aaf0ab4af3744f76aaf8c0b71d6 (diff) | |
download | openvpn-8e5613c2a8545a67cab2734569a8f088100d731b.tar.gz openvpn-8e5613c2a8545a67cab2734569a8f088100d731b.tar.xz openvpn-8e5613c2a8545a67cab2734569a8f088100d731b.zip |
Migrated x509_get_sha1_hash to use the garbage collector
Signed-off-by: Adriaan de Jong <dejong@fox-it.com>
Acked-by: James Yonan <james@openvpn.net>
Acked-by: David Sommerseth <davids@redhat.com>
Signed-off-by: David Sommerseth <davids@redhat.com>
Diffstat (limited to 'src/openvpn/ssl_verify_backend.h')
-rw-r--r-- | src/openvpn/ssl_verify_backend.h | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/openvpn/ssl_verify_backend.h b/src/openvpn/ssl_verify_backend.h index ab44f95..1658cc0 100644 --- a/src/openvpn/ssl_verify_backend.h +++ b/src/openvpn/ssl_verify_backend.h @@ -89,20 +89,12 @@ char *x509_get_subject (openvpn_x509_cert_t *cert, struct gc_arena *gc); /* Retrieve the certificate's SHA1 hash. * - * The returned string must be freed with \c verify_free_sha1_hash() - * * @param cert Certificate to retrieve the hash from. + * @param gc Garbage collection arena to use when allocating string. * * @return a string containing the SHA1 hash of the certificate */ -unsigned char *x509_get_sha1_hash (openvpn_x509_cert_t *cert); - -/* - * Free a hash as returned by \c verify_get_hash() - * - * @param hash The subject to be freed. - */ -void x509_free_sha1_hash (unsigned char *hash); +unsigned char *x509_get_sha1_hash (openvpn_x509_cert_t *cert, struct gc_arena *gc); /* * Retrieve the certificate's username from the specified field. |