FFmpeg  4.0
Data Structures | Functions | Variables
tls_libtls.c File Reference
#include "avformat.h"
#include "internal.h"
#include "network.h"
#include "url.h"
#include "tls.h"
#include "libavcodec/internal.h"
#include "libavutil/avutil.h"
#include "libavutil/opt.h"

Go to the source code of this file.

Data Structures

struct  TLSContext
 

Functions

static int ff_tls_close (URLContext *h)
 
static ssize_t tls_read_callback (struct tls *ctx, void *buf, size_t buflen, void *cb_arg)
 
static ssize_t tls_write_callback (struct tls *ctx, const void *buf, size_t buflen, void *cb_arg)
 
static int ff_tls_open (URLContext *h, const char *uri, int flags, AVDictionary **options)
 
static int ff_tls_read (URLContext *h, uint8_t *buf, int size)
 
static int ff_tls_write (URLContext *h, const uint8_t *buf, int size)
 
static int tls_get_file_handle (URLContext *h)
 

Variables

static const AVOption options []
 
static const AVClass tls_class
 
const URLProtocol ff_tls_protocol
 

Function Documentation

◆ ff_tls_close()

static int ff_tls_close ( URLContext h)
static

Definition at line 40 of file tls_libtls.c.

Referenced by ff_tls_open().

◆ tls_read_callback()

static ssize_t tls_read_callback ( struct tls *  ctx,
void buf,
size_t  buflen,
void cb_arg 
)
static

Definition at line 52 of file tls_libtls.c.

Referenced by ff_tls_open().

◆ tls_write_callback()

static ssize_t tls_write_callback ( struct tls *  ctx,
const void buf,
size_t  buflen,
void cb_arg 
)
static

Definition at line 63 of file tls_libtls.c.

Referenced by ff_tls_open().

◆ ff_tls_open()

static int ff_tls_open ( URLContext h,
const char *  uri,
int  flags,
AVDictionary **  options 
)
static

Definition at line 74 of file tls_libtls.c.

◆ ff_tls_read()

static int ff_tls_read ( URLContext h,
uint8_t buf,
int  size 
)
static

Definition at line 153 of file tls_libtls.c.

◆ ff_tls_write()

static int ff_tls_write ( URLContext h,
const uint8_t buf,
int  size 
)
static

Definition at line 166 of file tls_libtls.c.

◆ tls_get_file_handle()

static int tls_get_file_handle ( URLContext h)
static

Definition at line 179 of file tls_libtls.c.

Variable Documentation

◆ options

const AVOption options[]
static
Initial value:
= {
{ NULL }
}
#define NULL
Definition: coverity.c:32
#define TLS_COMMON_OPTIONS(pstruct, options_field)
Definition: tls.h:45

Definition at line 185 of file tls_libtls.c.

◆ tls_class

const AVClass tls_class
static
Initial value:
= {
.class_name = "tls",
.item_name = av_default_item_name,
.option = options,
}
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:191
static const AVOption options[]
Definition: tls_libtls.c:185

Definition at line 190 of file tls_libtls.c.

◆ ff_tls_protocol

const URLProtocol ff_tls_protocol
Initial value:
= {
.name = "tls",
.url_open2 = ff_tls_open,
.url_read = ff_tls_read,
.url_write = ff_tls_write,
.url_close = ff_tls_close,
.url_get_file_handle = tls_get_file_handle,
.priv_data_size = sizeof(TLSContext),
.priv_data_class = &tls_class,
}
#define URL_PROTOCOL_FLAG_NETWORK
Definition: url.h:34
static int ff_tls_read(URLContext *h, uint8_t *buf, int size)
Definition: tls_libtls.c:153
static int flags
Definition: log.c:55
static int tls_get_file_handle(URLContext *h)
Definition: tls_libtls.c:179
static int ff_tls_open(URLContext *h, const char *uri, int flags, AVDictionary **options)
Definition: tls_libtls.c:74
static const AVClass tls_class
Definition: tls_libtls.c:190
static int ff_tls_write(URLContext *h, const uint8_t *buf, int size)
Definition: tls_libtls.c:166
static int ff_tls_close(URLContext *h)
Definition: tls_libtls.c:40

Definition at line 197 of file tls_libtls.c.