Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
e122b12c
Commit
e122b12c
authored
Nov 23, 2016
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
build: Drop gcrypt support
GnuTLS in combination with gcrypt has been deprecated since 2010.
parent
bf2f748f
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
4 additions
and
46 deletions
+4
-46
configure
configure
+2
-6
hlsenc.c
libavformat/hlsenc.c
+2
-7
rtmpdh.c
libavformat/rtmpdh.c
+0
-18
rtmpdh.h
libavformat/rtmpdh.h
+0
-5
tls_gnutls.c
libavformat/tls_gnutls.c
+0
-10
No files found.
configure
View file @
e122b12c
...
...
@@ -1700,7 +1700,6 @@ CONFIG_EXTRA="
flacdsp
fmtconvert
g722dsp
gcrypt
gmp
golomb
gplv3
...
...
@@ -2387,7 +2386,7 @@ xcbgrab_indev_deps="libxcb"
# protocols
ffrtmpcrypt_protocol_deps
=
"!librtmp_protocol"
ffrtmpcrypt_protocol_deps_any
=
"g
crypt g
mp openssl"
ffrtmpcrypt_protocol_deps_any
=
"gmp openssl"
ffrtmpcrypt_protocol_select
=
"tcp_protocol"
ffrtmphttp_protocol_deps
=
"!librtmp_protocol"
ffrtmphttp_protocol_select
=
"http_protocol"
...
...
@@ -4717,10 +4716,7 @@ enabled openssl && { { check_pkg_config openssl openssl/ssl.h OPENSSL_
check_lib openssl/ssl.h SSL_library_init
-lssl
-lcrypto
-lws2_32
-lgdi32
||
die
"ERROR: openssl not found"
;
}
if
enabled gnutls
;
then
{
check_lib gmp.h mpz_export
-lgmp
&&
enable
gmp
;
}
||
{
check_lib gcrypt.h gcry_mpi_new
-lgcrypt
&&
enable
gcrypt
;
}
fi
enabled gnutls
&&
check_lib gmp.h mpz_export
-lgmp
&&
enable
gmp
# libdc1394 check
if
enabled libdc1394
;
then
...
...
libavformat/hlsenc.c
View file @
e122b12c
...
...
@@ -24,9 +24,7 @@
#include <config.h>
#if CONFIG_GCRYPT
#include <gcrypt.h>
#elif CONFIG_OPENSSL
#if CONFIG_OPENSSL
#include <openssl/rand.h>
#endif
...
...
@@ -86,10 +84,7 @@ typedef struct HLSContext {
static
int
randomize
(
uint8_t
*
buf
,
int
len
)
{
#if CONFIG_GCRYPT
gcry_randomize
(
buf
,
len
,
GCRY_VERY_STRONG_RANDOM
);
return
0
;
#elif CONFIG_OPENSSL
#if CONFIG_OPENSSL
if
(
RAND_bytes
(
buf
,
len
))
return
0
;
return
AVERROR
(
EIO
);
...
...
libavformat/rtmpdh.c
View file @
e122b12c
...
...
@@ -107,24 +107,6 @@ static int bn_modexp(FFBigNum bn, FFBigNum y, FFBigNum q, FFBigNum p)
mpz_powm
(
bn
,
y
,
q
,
p
);
return
0
;
}
#elif CONFIG_GCRYPT
#define bn_new(bn) bn = gcry_mpi_new(1)
#define bn_free(bn) gcry_mpi_release(bn)
#define bn_set_word(bn, w) gcry_mpi_set_ui(bn, w)
#define bn_cmp(a, b) gcry_mpi_cmp(a, b)
#define bn_copy(to, from) gcry_mpi_set(to, from)
#define bn_sub_word(bn, w) gcry_mpi_sub_ui(bn, bn, w)
#define bn_cmp_1(bn) gcry_mpi_cmp_ui(bn, 1)
#define bn_num_bytes(bn) (gcry_mpi_get_nbits(bn) + 7) / 8
#define bn_bn2bin(bn, buf, len) gcry_mpi_print(GCRYMPI_FMT_USG, buf, len, NULL, bn)
#define bn_bin2bn(bn, buf, len) gcry_mpi_scan(&bn, GCRYMPI_FMT_USG, buf, len, NULL)
#define bn_hex2bn(bn, buf, ret) ret = (gcry_mpi_scan(&bn, GCRYMPI_FMT_HEX, buf, 0, 0) == 0)
#define bn_random(bn, num_bits) gcry_mpi_randomize(bn, num_bits, GCRY_WEAK_RANDOM)
static
int
bn_modexp
(
FFBigNum
bn
,
FFBigNum
y
,
FFBigNum
q
,
FFBigNum
p
)
{
gcry_mpi_powm
(
bn
,
y
,
q
,
p
);
return
0
;
}
#elif CONFIG_OPENSSL
#define bn_new(bn) bn = BN_new()
#define bn_free(bn) BN_free(bn)
...
...
libavformat/rtmpdh.h
View file @
e122b12c
...
...
@@ -30,11 +30,6 @@
#include <gmp.h>
typedef
mpz_ptr
FFBigNum
;
#elif CONFIG_GCRYPT
#include <gcrypt.h>
typedef
gcry_mpi_t
FFBigNum
;
#elif CONFIG_OPENSSL
#include <openssl/bn.h>
#include <openssl/dh.h>
...
...
libavformat/tls_gnutls.c
View file @
e122b12c
...
...
@@ -35,12 +35,6 @@
#include "libavutil/opt.h"
#include "libavutil/parseutils.h"
#if HAVE_THREADS && GNUTLS_VERSION_NUMBER <= 0x020b00
#include <gcrypt.h>
#include "libavutil/thread.h"
GCRY_THREAD_OPTION_PTHREAD_IMPL
;
#endif
typedef
struct
TLSContext
{
const
AVClass
*
class
;
TLSShared
tls_shared
;
...
...
@@ -52,10 +46,6 @@ typedef struct TLSContext {
void
ff_gnutls_init
(
void
)
{
avpriv_lock_avformat
();
#if HAVE_THREADS && GNUTLS_VERSION_NUMBER < 0x020b00
if
(
gcry_control
(
GCRYCTL_ANY_INITIALIZATION_P
)
==
0
)
gcry_control
(
GCRYCTL_SET_THREAD_CBS
,
&
gcry_threads_pthread
);
#endif
gnutls_global_init
();
avpriv_unlock_avformat
();
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment