You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-04 22:03:09 +02:00
avformat/tls_openssl: make generating fingerprints optional
This commit is contained in:
@ -216,11 +216,13 @@ int ff_ssl_read_key_cert(char *key_url, char *cert_url, char *key_buf, size_t ke
|
|||||||
snprintf(cert_buf, cert_sz, "%s", cert_tem);
|
snprintf(cert_buf, cert_sz, "%s", cert_tem);
|
||||||
|
|
||||||
/* Generate fingerprint. */
|
/* Generate fingerprint. */
|
||||||
*fingerprint = generate_fingerprint(cert);
|
if (fingerprint) {
|
||||||
if (!*fingerprint) {
|
*fingerprint = generate_fingerprint(cert);
|
||||||
av_log(NULL, AV_LOG_ERROR, "TLS: Failed to generate fingerprint from %s\n", cert_url);
|
if (!*fingerprint) {
|
||||||
ret = AVERROR(EIO);
|
av_log(NULL, AV_LOG_ERROR, "TLS: Failed to generate fingerprint from %s\n", cert_url);
|
||||||
goto end;
|
ret = AVERROR(EIO);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
end:
|
end:
|
||||||
@ -371,9 +373,11 @@ static int openssl_gen_certificate(EVP_PKEY *pkey, X509 **cert, char **fingerpri
|
|||||||
goto einval_end;
|
goto einval_end;
|
||||||
}
|
}
|
||||||
|
|
||||||
*fingerprint = generate_fingerprint(*cert);
|
if (fingerprint) {
|
||||||
if (!*fingerprint) {
|
*fingerprint = generate_fingerprint(*cert);
|
||||||
goto enomem_end;
|
if (!*fingerprint) {
|
||||||
|
goto enomem_end;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
goto end;
|
goto end;
|
||||||
|
Reference in New Issue
Block a user