Commit Graph

114 Commits

Author SHA1 Message Date
a2e486f2b6 Remove libwget/printf.c
* configure.ac: Remove check for dprintf
* include/libwget.h.in: Remove dprintf/vdprintf prototypes
* libwget/Makefile.am: Remove printf.c from file list
* libwget/printf.c: Remove file
2016-01-11 13:30:56 +01:00
54eaae1381 Use strndup gnulib fallback
* autogen.sh: Add strndup to gnulib modules
* configure.ac: Remove searching for strndup()
* include/libwget.h.in: Remove conditional code
2016-01-11 12:07:31 +01:00
332176577a Auto-generate version defines for library header file
* include/libwget.h: Removed
* include/libwget.h.in: Added
2016-01-06 16:27:33 +01:00
954136e2df Do not percent unescape query
* tests/test.c: Test query parsing in API
* tests/test-base.c: Test query handling of wget2
* include/libwget.h: Add flags to wget_iri_t,
  add function wget_iri_unescape_inline()
* libwget/iri.c: Add function wget_iri_unescape_inline(),
  fix wget_iri_parse() to not percent unescape query
  do not add fragment in wget_iri_get_escaped_resource()
2016-01-06 11:27:07 +01:00
ed5835f446 Cleanup cookie code
Cookies: Add new function wget_cookie_set_keep_session_cookies()
         and adjust wget_cookie_db_load() and wget_cookie_db_save().
         Use wget_update_file() for loading and saving.
2015-11-23 16:43:27 +01:00
bbcb319ac3 Add new options --netrc and --netrc-file
* libwget/netrc.c: New file for netrc API functions
* include/libwget.h: Add netrc function prototypes
* libwget/Makefile.am: Add netrc.c
* libwget/test_linking.c (main): Add call to wget_netrc_deinit()
* src/options.c: Add --netrc and --netrc-file
* src/options.h: Add config.netrc and config.netrc_file
* src/wget.c (http_get): Get login/password from netrc data
* tests/test-auth-basic.c (main): Add test for --netrc-file
2015-11-11 20:58:45 +01:00
d85c4b3fe2 Add new function wget_update_file()
* include/libwget.h: Add wget_update_file()
* libwget/io.c: Add wget_update_file()

Add a function to care about locking, temp files, opening
overhead for our typical updating file database procedure.
Useful for HSTS, OCSP and Cookie file databases.
2015-11-09 11:08:43 +01:00
87de5bd4cb Fixed HSTS policy application
* include/libwget.h (wget_iri_set_scheme): new function.
 * libwget/hsts.c (wget_hsts_host_match): HTTP default port -> HTTPS
   default port
 * libwget/iri.c (wget_iri_set_scheme): new function.
 * src/wget.c (http_get): when changing the scheme, change the port
   number as well (call wget_iri_set_scheme).
2015-11-03 19:20:54 +01:00
36a47cc558 Add function wget_global_get_func()
* include/libwget.h: Add wget_global_get_func() prototype
* libwget/init.c: Add function wget_global_get_func()
2015-10-30 17:39:57 +01:00
7cbd3d5e67 set_http_proxy and set_https_proxy can return an error
* libwget/http.h (wget_http_set_http_proxy): change the return type to int.
(wget_http_set_https_proxy): change the return type to int
* libwget/http.c (wget_http_set_http_proxy): return an error if cannot set the proxies.
(wget_http_set_https_proxy): return an error if cannot set the proxies.
2015-10-23 20:21:33 +02:00
f63767b028 Documented hashing functions 2015-10-23 15:49:15 +02:00
10003c829f Initial docs for hashing utils 2015-10-23 15:48:39 +02:00
e1990c6415 On CTRL-C save downloaded data before exit
* include/libwget.h: New declaration wget_http_abort_connection()
* libwget/http.c: New function wget_http_abort_connection()
* src/wget.c: Call wget_http_abort_connection() on CTRL-C
2015-10-19 21:13:28 +02:00
0f8e49128a Transfer copyright to Free Software Foundation, Inc. 2015-09-22 11:50:06 +02:00
c6b0e461a1 Transform Mget into Wget 2015-09-19 22:54:38 +02:00
c726913a8f More HTTP/2 related code, new option --(no-)http2 2015-09-18 17:04:16 +02:00
db7da4aff0 HTTP/2 download is working 2015-09-11 17:08:19 +02:00
b71abda2b0 Rearrange HTTP header API 2015-09-07 12:26:21 +02:00
591ec4fe65 Request HTTP/1.1 and HTTP/2.0 via ALPN 2015-09-07 10:51:57 +02:00
eacdc709c4 Fix Content-Disposition filename retrieval 2015-08-31 15:03:47 +02:00
cffe303d6e Include sys/types.h in libmget.h 2015-08-28 12:08:01 +02:00
52e10c8886 Unify mget_ssl_server_open and mget_ssl_open 2015-07-12 21:24:55 +02:00
2d35ac3ff0 Add mget_tcp_tls_start() and mget_tcp_tls_stop() 2015-07-12 20:57:52 +02:00
2e8f0b6441 Allow NULL for mget_http_parse_setcookie()i cookie param 2015-07-06 11:40:44 +02:00
1d45d9a704 changes in hashmap handling 2015-03-08 21:44:01 +01:00
6cdd208444 fix several issues found by Coverity 2015-03-07 22:55:17 +01:00
24030f6b01 comment unused mget_bsprintf functions 2015-03-03 21:49:11 +01:00
8a1334d335 fix possible buffer overflow 2015-03-03 21:31:11 +01:00
42bc281945 fixed Mget return value for HTTPS failures 2015-02-24 10:52:22 +01:00
d028fac571 added ALPN for TLS sessions 2015-02-20 17:11:34 +01:00
82149e5a43 fix compiler warnings 2015-02-05 16:32:38 +01:00
2b0ad106be include libintl.h before redefinition of gettext functions 2015-02-05 16:23:04 +01:00
3207affc70 added full cert chain OCSP check 2015-01-29 17:14:20 +01:00
1083b1a434 added --tcp-fastopen to enable/disable TCP Fast Open 2015-01-13 16:48:40 +01:00
7ba53339eb added OCSP response caching 2015-01-08 17:11:30 +01:00
49e602ebf7 new options --ocsp and --ocsp-stapling 2014-12-18 17:03:45 +01:00
cca63cc7b5 Check for gnutls/ocsp.h to compile on older systems 2014-12-15 21:21:35 +01:00
97f2284914 Add wildcard support for -D/--domains and --exclude-domains 2014-12-09 16:26:43 +01:00
d67946f113 added --crl-file for CRL certificates 2014-10-24 23:14:33 +02:00
f7ab61242d moved basic progress bar routines to libmget 2014-10-18 14:26:31 +02:00
675831afa3 use ASCII-only string case comparison 2014-09-23 17:11:01 +02:00
ae4b7e2f43 added --post-data and --post-file 2014-09-22 16:29:40 +02:00
a85b163ee9 added --follow-tags and --ignore-tags 2014-09-09 13:18:32 +02:00
b75d3fd964 fixed clang detections 2014-09-05 17:15:23 +02:00
aeffeabc33 added some first MinGW compatibility code 2014-08-28 17:54:20 +02:00
7f131b0ef5 added -k/--convert-links and -K/--backup-converted 2014-07-17 17:12:44 +02:00
d2813a0dc6 use libpsl for cookie checking against Public Suffix List 2014-07-11 17:05:36 +02:00
67f49bab9d added --accept, --reject, --ignore-case 2014-07-03 13:29:50 +02:00
4e667ae853 fix some clang warnings 2014-04-04 15:36:10 +02:00
a51fe2fe98 fixed up cookie code 2014-03-19 17:15:24 +01:00