struct vlc_http_conn * vlc_h2_conn_create(void *ctx, struct vlc_tls *)
Definition: h2conn.c:877
vlc_tls_client_t * vlc_tls_ClientCreate(vlc_object_t *obj)
Allocates TLS client-side credentials.
Definition: tls.c:93
struct vlc_http_stream * vlc_h1_request(void *ctx, const char *hostname, unsigned port, bool proxy, const struct vlc_http_msg *req, bool idempotent, bool has_data, struct vlc_http_conn **restrict connp)
Sends an HTTP/1.x request through a new connection.
Definition: h1conn.c:357
static struct vlc_http_msg * vlc_http_mgr_reuse(struct vlc_http_mgr *mgr, const char *host, unsigned port, const struct vlc_http_msg *req, bool payload)
Definition: connmgr.c:125
#define unlikely(p)
Predicted false condition.
Definition: vlc_common.h:227
Definition: messages.c:54
struct vlc_logger * logger
Definition: vlc_objects.h:45
struct vlc_http_mgr * vlc_http_mgr_create(vlc_object_t *obj, struct vlc_http_cookie_jar_t *jar)
Creates an HTTP connection manager.
Definition: connmgr.c:290
struct vlc_http_conn * vlc_h1_conn_create(void *ctx, struct vlc_tls *, bool proxy)
Definition: h1conn.c:340
vlc_tls_t * vlc_https_connect(vlc_tls_client_t *creds, const char *name, unsigned port, bool *restrict two)
Definition: connmgr.c:59
Transport layer socket.
Definition: vlc_tls.h:65
static void vlc_http_mgr_release(struct vlc_http_mgr *mgr, struct vlc_http_conn *conn)
Definition: connmgr.c:115
void vlc_UrlClean(vlc_url_t *restrict url)
Definition: url.c:598
char * vlc_getProxyUrl(const char *url)
Determines the network proxy server to use (if any).
Definition: specific.c:342
bool vlc_http_port_blocked(unsigned port)
Definition: ports.c:106
vlc_tls_t * vlc_tls_SocketOpenTLS(vlc_tls_client_t *creds, const char *name, unsigned port, const char *service, const char *const *alpn, char **alp)
Initiates a TLS session over TCP.
Definition: tls.c:217
static struct vlc_http_stream * vlc_http_stream_open(struct vlc_http_conn *conn, const struct vlc_http_msg *m, bool has_data)
Definition: conn.h:48
@ VLC_MSG_ERR
Error.
Definition: vlc_messages.h:48
static struct vlc_http_msg * vlc_https_request(struct vlc_http_mgr *mgr, const char *host, unsigned port, const struct vlc_http_msg *req, bool idempotent, bool payload)
Definition: connmgr.c:146
int asprintf(char **, const char *,...)
struct vlc_http_cookie_jar_t * jar
Definition: connmgr.c:104
struct vlc_http_stream * payload
Definition: message.c:69
void vlc_tls_ClientDelete(vlc_tls_client_t *crd)
Releases TLS client-side credentials.
Definition: tls.c:122
char * psz_host
Definition: vlc_url.h:150
vlc_object_t * obj
Definition: connmgr.c:102
struct vlc_http_msg * vlc_http_msg_get_initial(struct vlc_http_stream *s)
Definition: message.c:276
int vlc_UrlParse(vlc_url_t *url, const char *str)
Parses an URI or IRI.
Definition: url.c:558
void vlc_vaLog(struct vlc_logger *const *loggerp, int type, const char *typename, const char *module, const char *file, unsigned line, const char *func, const char *format, va_list args)
Definition: messages.c:85
void vlc_http_mgr_destroy(struct vlc_http_mgr *mgr)
Destroys an HTTP connection manager.
Definition: connmgr.c:305
static void vlc_tls_Close(vlc_tls_t *session)
Closes a connection and its underlying resources.
Definition: vlc_tls.h:397
HTTP stream.
Definition: message.h:366
struct vlc_http_conn * conn
Definition: connmgr.c:105
Definition: httpcookies.c:265
void vlc_http_err(void *ctx, const char *fmt,...)
Definition: connmgr.c:37
Definition: vlc_url.h:145
VLC object common members.
Definition: vlc_objects.h:43
struct vlc_http_cookie_jar_t * vlc_http_mgr_get_jar(struct vlc_http_mgr *mgr)
Definition: connmgr.c:285
struct vlc_logger * logger
Definition: connmgr.c:101
static void vlc_http_conn_release(struct vlc_http_conn *conn)
Definition: conn.h:54
unsigned i_port
Definition: vlc_url.h:151
struct vlc_tls * tls
Definition: conn.h:44
const char name[16]
Definition: httpd.c:1268
vlc_tls_client_t * creds
Definition: connmgr.c:103
TLS client-side credentials.
Definition: vlc_tls.h:140
static struct vlc_http_conn * vlc_http_mgr_find(struct vlc_http_mgr *mgr, const char *host, unsigned port)
Definition: connmgr.c:108
static char * vlc_http_proxy_find(const char *hostname, unsigned port, bool secure)
Definition: connmgr.c:79
static struct vlc_http_msg * vlc_http_request(struct vlc_http_mgr *mgr, const char *host, unsigned port, const struct vlc_http_msg *req, bool idempotent, bool payload)
Definition: connmgr.c:216
#define likely(p)
Predicted true condition.
Definition: vlc_common.h:218
@ VLC_MSG_DBG
Debug.
Definition: vlc_messages.h:50
struct vlc_tls * vlc_https_connect_proxy(void *ctx, struct vlc_tls_client *creds, const char *name, unsigned port, bool *restrict two, const char *proxy)
Definition: tunnel.c:134
void vlc_http_dbg(void *ctx, const char *fmt,...)
Definition: connmgr.c:48
struct vlc_http_msg * vlc_http_mgr_request(struct vlc_http_mgr *mgr, bool https, const char *host, unsigned port, const struct vlc_http_msg *m, bool idempotent, bool payload)
Sends an HTTP request.
Definition: connmgr.c:273