VLC 4.0.0-dev
|
Data Structures | |
struct | http_cookie_t |
struct | vlc_http_cookie_jar_t |
Typedefs | |
typedef struct http_cookie_t | http_cookie_t |
Functions | |
static char * | cookie_get_attribute_value (const char *cookie, const char *attr) |
static bool | cookie_has_attribute (const char *cookie, const char *attr) |
static char * | cookie_get_domain (const char *cookie) |
static bool | cookie_domain_matches (const http_cookie_t *cookie, const char *host) |
static char * | cookie_get_path (const char *cookie) |
static bool | cookie_path_matches (const http_cookie_t *cookie, const char *uripath) |
static bool | cookie_should_be_sent (const http_cookie_t *cookie, bool secure, const char *host, const char *path) |
static char * | cookie_default_path (const char *request_path) |
static void | cookie_destroy (http_cookie_t *cookie) |
static http_cookie_t * | cookie_parse (const char *value, const char *host, const char *path) |
vlc_http_cookie_jar_t * | vlc_http_cookies_new (void) |
void | vlc_http_cookies_destroy (vlc_http_cookie_jar_t *p_jar) |
bool | vlc_http_cookies_store (vlc_http_cookie_jar_t *p_jar, const char *cookies, const char *host, const char *path) |
Parse a value of an incoming Set-Cookie header and append the cookie to the cookie jar if appropriate. More... | |
char * | vlc_http_cookies_fetch (vlc_http_cookie_jar_t *p_jar, bool secure, const char *host, const char *path) |
Returns a cookie value that match the given URL. More... | |
typedef struct http_cookie_t http_cookie_t |
|
static |
References strdup(), and strndup().
Referenced by cookie_parse().
|
static |
References http_cookie_t::psz_domain, http_cookie_t::psz_name, http_cookie_t::psz_path, and http_cookie_t::psz_value.
Referenced by cookie_parse(), vlc_http_cookies_destroy(), and vlc_http_cookies_store().
|
static |
References http_cookie_t::b_host_only, http_cookie_t::psz_domain, and vlc_ascii_strcasecmp().
Referenced by cookie_should_be_sent(), and vlc_http_cookies_store().
|
static |
References strndup(), and vlc_ascii_strncasecmp().
Referenced by cookie_get_domain(), and cookie_get_path().
|
static |
References cookie_get_attribute_value().
Referenced by cookie_parse().
|
static |
References cookie_get_attribute_value().
Referenced by cookie_parse().
|
static |
References vlc_ascii_strncasecmp().
Referenced by cookie_parse().
|
static |
References http_cookie_t::b_host_only, http_cookie_t::b_secure, cookie_default_path(), cookie_destroy(), cookie_get_domain(), cookie_get_path(), cookie_has_attribute(), p, http_cookie_t::psz_domain, http_cookie_t::psz_name, http_cookie_t::psz_path, http_cookie_t::psz_value, strdup(), strndup(), and unlikely.
Referenced by vlc_http_cookies_store().
|
static |
References http_cookie_t::psz_path.
Referenced by cookie_should_be_sent().
|
static |
References http_cookie_t::b_secure, cookie_domain_matches(), and cookie_path_matches().
Referenced by vlc_http_cookies_fetch().
void vlc_http_cookies_destroy | ( | vlc_http_cookie_jar_t * | p_jar | ) |
References cookie_destroy(), vlc_http_cookie_jar_t::cookies, vlc_array_clear(), vlc_array_count(), and vlc_array_item_at_index.
Referenced by vlc_player_Delete().
char * vlc_http_cookies_fetch | ( | vlc_http_cookie_jar_t * | jar, |
bool | secure, | ||
const char * | host, | ||
const char * | path | ||
) |
Returns a cookie value that match the given URL.
p_jar | a cookie jar |
p_url | the URL for which the cookies are returned |
References asprintf(), cookie_should_be_sent(), vlc_http_cookie_jar_t::cookies, vlc_http_cookie_jar_t::lock, http_cookie_t::psz_name, http_cookie_t::psz_value, vlc_array_count(), vlc_array_item_at_index, vlc_mutex_lock(), and vlc_mutex_unlock().
Referenced by vlc_http_msg_add_cookies().
vlc_http_cookie_jar_t * vlc_http_cookies_new | ( | void | ) |
References vlc_http_cookie_jar_t::cookies, vlc_http_cookie_jar_t::lock, unlikely, vlc_array_init(), and vlc_mutex_init().
Referenced by vlc_player_New().
bool vlc_http_cookies_store | ( | vlc_http_cookie_jar_t * | jar, |
const char * | cookie, | ||
const char * | host, | ||
const char * | path | ||
) |
Parse a value of an incoming Set-Cookie header and append the cookie to the cookie jar if appropriate.
jar | cookie jar object |
cookie | header field value of Set-Cookie |
References cookie_destroy(), cookie_domain_matches(), cookie_parse(), vlc_http_cookie_jar_t::cookies, vlc_http_cookie_jar_t::lock, http_cookie_t::psz_domain, http_cookie_t::psz_name, http_cookie_t::psz_path, vlc_array_append(), vlc_array_count(), vlc_array_item_at_index, vlc_array_remove(), vlc_ascii_strcasecmp(), vlc_mutex_lock(), and vlc_mutex_unlock().
Referenced by vlc_http_msg_get_cookies().