uclient: Handle memory allocation failure for url Check ptr to url after allocation to prevent null pointer dereference Signed-off-by: Tobias Schramm <tobleminer@gmail.com>
http: add support for relative location on redirect Signed-off-by: Felix Fietkau <nbd@nbd.name>
core: fix unused but set variable Signed-off-by: Felix Fietkau <nbd@openwrt.org>
core: make __uclient_get_url static Signed-off-by: Felix Fietkau <nbd@openwrt.org>
core: add proxy support Signed-off-by: Felix Fietkau <nbd@openwrt.org>
core: fix memory leak if url change fails Signed-off-by: Felix Fietkau <nbd@openwrt.org>
use const for char buffer in uclient_write We are not supposed to modify it and ustream accepts const already. Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
support for connection timeout Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
fetch: indicate an error if the connection was terminated prematurely Signed-off-by: Felix Fietkau <nbd@openwrt.org>
add uclient_disconnect() to force a disconnect without further callbacks Signed-off-by: Felix Fietkau <nbd@openwrt.org>
add support for querying local/remote address Signed-off-by: Felix Fietkau <nbd@openwrt.org>
fix specifying ports in urls Signed-off-by: Felix Fietkau <nbd@openwrt.org>
add support for passing in auth to uclient_set_url()
split setting url from connecting Signed-off-by: Felix Fietkau <nbd@openwrt.org>
pass auth_str to uclient_new() Signed-off-by: Felix Fietkau <nbd@openwrt.org>
add copyright headers Signed-off-by: Felix Fietkau <nbd@openwrt.org>
implement optional SSL certificate validation (including CN host check) Signed-off-by: Felix Fietkau <nbd@openwrt.org>
fix prefix id passing Signed-off-by: Felix Fietkau <nbd@openwrt.org>
fix positioning of the __hidden attribute Signed-off-by: Felix Fietkau <nbd@openwrt.org>
add a utility function to detect redirects and handle them Signed-off-by: Felix Fietkau <nbd@openwrt.org>