project/uclient.git
9 years agoadd uclient_disconnect() to force a disconnect without further callbacks
Felix Fietkau [Sun, 4 May 2014 17:54:22 +0000 (19:54 +0200)]
add uclient_disconnect() to force a disconnect without further callbacks

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: write output data to a file
Felix Fietkau [Sun, 4 May 2014 17:05:02 +0000 (19:05 +0200)]
example: write output data to a file

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: create only one request
Felix Fietkau [Sun, 4 May 2014 16:34:40 +0000 (18:34 +0200)]
example: create only one request

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: update usage info
Felix Fietkau [Sun, 4 May 2014 12:30:18 +0000 (14:30 +0200)]
example: update usage info

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: add quiet flag similar to wget
Felix Fietkau [Sun, 4 May 2014 12:24:23 +0000 (14:24 +0200)]
example: add quiet flag similar to wget

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexpose struct uclient_url
Felix Fietkau [Sun, 4 May 2014 12:21:11 +0000 (14:21 +0200)]
expose struct uclient_url

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: change -c to --ca-certificate to match wget
Felix Fietkau [Sun, 4 May 2014 12:15:40 +0000 (14:15 +0200)]
example: change -c to --ca-certificate to match wget

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: change -C to --no-check-certificate to match wget
Felix Fietkau [Sun, 4 May 2014 12:11:40 +0000 (14:11 +0200)]
example: change -C to --no-check-certificate to match wget

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agoexample: make ustream-ssl optional (load via dlopen)
Felix Fietkau [Sun, 4 May 2014 11:59:45 +0000 (13:59 +0200)]
example: make ustream-ssl optional (load via dlopen)

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agohttp: make ustream_ssl optional, only use provided ssl context
Felix Fietkau [Sun, 4 May 2014 11:34:40 +0000 (13:34 +0200)]
http: make ustream_ssl optional, only use provided ssl context

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
9 years agohttp: get address at initial connect time
Felix Fietkau [Wed, 30 Apr 2014 12:50:21 +0000 (14:50 +0200)]
http: get address at initial connect time

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for querying local/remote address
Felix Fietkau [Mon, 7 Apr 2014 19:11:58 +0000 (21:11 +0200)]
add support for querying local/remote address

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoignore empty writes
Felix Fietkau [Thu, 3 Apr 2014 09:52:52 +0000 (11:52 +0200)]
ignore empty writes

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for 204 (no content)
Felix Fietkau [Sat, 29 Mar 2014 22:31:54 +0000 (23:31 +0100)]
add support for 204 (no content)

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agofix arguments to uclient_http_reset_headers
Felix Fietkau [Sat, 29 Mar 2014 22:29:38 +0000 (23:29 +0100)]
fix arguments to uclient_http_reset_headers

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agofix specifying ports in urls
Felix Fietkau [Sat, 29 Mar 2014 19:25:30 +0000 (20:25 +0100)]
fix specifying ports in urls

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoavoid sending duplicate headers
Felix Fietkau [Sat, 29 Mar 2014 19:17:57 +0000 (20:17 +0100)]
avoid sending duplicate headers

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoproperly terminate POST requests
Felix Fietkau [Sat, 29 Mar 2014 19:17:46 +0000 (20:17 +0100)]
properly terminate POST requests

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for passing in auth to uclient_set_url()
Felix Fietkau [Sat, 29 Mar 2014 13:52:12 +0000 (14:52 +0100)]
add support for passing in auth to uclient_set_url()

10 years agosplit setting url from connecting
Felix Fietkau [Sat, 29 Mar 2014 13:49:59 +0000 (14:49 +0100)]
split setting url from connecting

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agopass auth_str to uclient_new()
Felix Fietkau [Wed, 26 Mar 2014 19:55:18 +0000 (20:55 +0100)]
pass auth_str to uclient_new()

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd copyright headers
Felix Fietkau [Tue, 25 Mar 2014 20:35:47 +0000 (21:35 +0100)]
add copyright headers

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoimplement optional SSL certificate validation (including CN host check)
Felix Fietkau [Tue, 25 Mar 2014 14:39:58 +0000 (15:39 +0100)]
implement optional SSL certificate validation (including CN host check)

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agofix prefix id passing
Felix Fietkau [Tue, 25 Mar 2014 09:14:57 +0000 (10:14 +0100)]
fix prefix id passing

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agofix connect error handling
Felix Fietkau [Tue, 25 Mar 2014 09:11:36 +0000 (10:11 +0100)]
fix connect error handling

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for passing in an external ustream_ssl context
Felix Fietkau [Mon, 24 Mar 2014 13:25:14 +0000 (14:25 +0100)]
add support for passing in an external ustream_ssl context

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agomove nc to struct uclient_http
Felix Fietkau [Sun, 23 Mar 2014 00:11:15 +0000 (01:11 +0100)]
move nc to struct uclient_http

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agomove ssl_ctx to struct uclient_http
Felix Fietkau [Sun, 23 Mar 2014 00:09:20 +0000 (01:09 +0100)]
move ssl_ctx to struct uclient_http

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agofix positioning of the __hidden attribute
Felix Fietkau [Sun, 23 Mar 2014 00:01:40 +0000 (01:01 +0100)]
fix positioning of the __hidden attribute

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agouse the redirect function in the example code
Felix Fietkau [Sat, 22 Mar 2014 23:29:31 +0000 (00:29 +0100)]
use the redirect function in the example code

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd a utility function to detect redirects and handle them
Felix Fietkau [Sat, 22 Mar 2014 23:29:18 +0000 (00:29 +0100)]
add a utility function to detect redirects and handle them

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd missing prototype for uclient_backend_set_error
Felix Fietkau [Sat, 22 Mar 2014 18:29:12 +0000 (19:29 +0100)]
add missing prototype for uclient_backend_set_error

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agomake uclient_backend_http visible to allow the client to test for it
Felix Fietkau [Sat, 22 Mar 2014 17:31:41 +0000 (18:31 +0100)]
make uclient_backend_http visible to allow the client to test for it

the struct is still opaque, it is only used for pointer tests

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoparse the http response code
Felix Fietkau [Sat, 22 Mar 2014 17:30:09 +0000 (18:30 +0100)]
parse the http response code

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agocheck for length > 0 before calling ustream_write
Felix Fietkau [Sat, 22 Mar 2014 17:21:01 +0000 (18:21 +0100)]
check for length > 0 before calling ustream_write

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoimplement digest support
Felix Fietkau [Sat, 22 Mar 2014 16:22:14 +0000 (17:22 +0100)]
implement digest support

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agopass the initial / from uclient core to the proto handler
Felix Fietkau [Sat, 22 Mar 2014 14:35:50 +0000 (15:35 +0100)]
pass the initial / from uclient core to the proto handler

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd utilities for calculating http digest hashes
Felix Fietkau [Sat, 22 Mar 2014 13:23:33 +0000 (14:23 +0100)]
add utilities for calculating http digest hashes

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agopreserve the contents of the www-authenticate header and use them to detect authentic...
Felix Fietkau [Sat, 22 Mar 2014 13:05:05 +0000 (14:05 +0100)]
preserve the contents of the www-authenticate header and use them to detect authentication mode

preparation for adding digest authentication support

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agofix double / on requests to root
Felix Fietkau [Fri, 21 Mar 2014 23:56:16 +0000 (00:56 +0100)]
fix double / on requests to root

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for processing the content-length header when transfer is not chunked
Felix Fietkau [Fri, 21 Mar 2014 20:58:42 +0000 (21:58 +0100)]
add support for processing the content-length header when transfer is not chunked

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for reusing connections
Felix Fietkau [Fri, 21 Mar 2014 20:43:02 +0000 (21:43 +0100)]
add support for reusing connections

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoset eof on HEAD requests after header end
Felix Fietkau [Fri, 21 Mar 2014 20:32:01 +0000 (21:32 +0100)]
set eof on HEAD requests after header end

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoremove debug code
Felix Fietkau [Fri, 21 Mar 2014 20:30:28 +0000 (21:30 +0100)]
remove debug code

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoexample: use stdout instead of stderr
Felix Fietkau [Fri, 21 Mar 2014 20:11:39 +0000 (21:11 +0100)]
example: use stdout instead of stderr

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoadd support for parsing chunked data on read
Felix Fietkau [Fri, 21 Mar 2014 13:54:19 +0000 (14:54 +0100)]
add support for parsing chunked data on read

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agouse chunked data for POST, set HTTP version to 1.1
Felix Fietkau [Fri, 21 Mar 2014 12:48:59 +0000 (13:48 +0100)]
use chunked data for POST, set HTTP version to 1.1

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 years agoInitial import
Felix Fietkau [Thu, 20 Mar 2014 19:39:47 +0000 (20:39 +0100)]
Initial import

Signed-off-by: Felix Fietkau <nbd@openwrt.org>