| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
@deftypefun {int} {gnutls_x509_crt_get_preferred_hash_algorithm} (gnutls_x509_crt_t @var{crt}, gnutls_digest_algorithm_t * @var{hash}, unsigned int * @var{mand}) |
| 6 |
@var{crt}: Holds the certificate |
| 7 |
|
| 8 |
@var{hash}: The result of the call with the hash algorithm used for signature |
| 9 |
|
| 10 |
@var{mand}: If non-zero it means that the algorithm MUST use this hash. May be @code{NULL} . |
| 11 |
|
| 12 |
This function will read the certificate and return the appropriate digest |
| 13 |
algorithm to use for signing with this certificate. Some certificates (i.e. |
| 14 |
DSA might not be able to sign without the preferred algorithm). |
| 15 |
|
| 16 |
@strong{Deprecated:} Please use @code{gnutls_pubkey_get_preferred_hash_algorithm()} . |
| 17 |
|
| 18 |
@strong{Returns:} the 0 if the hash algorithm is found. A negative error code is |
| 19 |
returned on error. |
| 20 |
|
| 21 |
@strong{Since:} 2.12.0 |
| 22 |
@end deftypefun |