Jens Nielsen
c34120e855
TFTP server handle retransmit Data packets
...
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-04-25 20:29:31 +02:00
goldsimon
b1fe8cf4b8
netbiosns: check question type before generating an answer
2018-04-18 08:17:10 +02:00
goldsimon
f65911a84b
netbios: fix response length of node status response
2018-04-18 07:28:41 +02:00
Dirk Ziegelmeier
66800925cf
Fix indent in netbiosns.c
2018-04-17 14:08:59 +02:00
Dirk Ziegelmeier
533c97f0c3
Fix bug #53626 : NetBIOS Responder generates malformed packet responding to "*" name
...
Implement corrected answer packet
2018-04-16 10:40:05 +02:00
goldsimon
4cc953d0e3
httpd: fixed compiling makefsdata.c
2018-04-04 21:45:47 +02:00
Ray Abram
b0ae967660
NetBIOS Responder should respond to "*" names
...
See bug #53325
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-04-03 22:19:18 +02:00
Tom Ferrin
82d8f08451
Add "server reachability" register to SNTP
...
Guarded with SNTP_MONITOR_SERVER_REACHABILITY (sntp_opts.h).
See patch 9581
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-04-03 21:56:33 +02:00
Tom Ferrin
e46b9ad4ac
sntp: store server IP address after DNS lookup
...
See patch #9612
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-04-03 21:16:05 +02:00
Giuseppe Modugno
2d4da92eeb
makefsdata: added options to skip and avoid compressing some extensions
...
See patch #9605
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-04-03 21:08:25 +02:00
goldsimon
c974fc9d43
http_client: fix compiling if mem_size_t is smaller than size_t
2018-03-21 09:33:00 +01:00
Axel Lin
600527dde7
apps/http: httpd: Fix unused parameter warning if !LWIP_HTTPD_SUPPORT_V09
...
Signed-off-by: Axel Lin <axel.lin@ingics.com>
2018-03-21 15:05:33 +08:00
Axel Lin
e19d908f0e
apps/http: Fix httpd_structs.h build error
...
Fixes: bug #53382 : HTTPD_ADDITIONAL_CONTENT_TYPES doesn't compile
Reported-by: Giuseppe Modugno <giuseppe.modugno.loqed@gmail.com>
Signed-off-by: Axel Lin <axel.lin@ingics.com>
2018-03-19 21:08:17 +08:00
goldsimon
253fcc8dcd
http_client: call tcp_recved for header bytes
...
Without this, closing the connection after successful transfer resulted
in a RST being sent because the window was not fully marked as 'recved'.
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-03-09 11:30:23 +01:00
goldsimon
61a1b98cc9
various IPv6-only compile fixes
2018-03-07 20:55:00 +01:00
goldsimon
b6d9bb6b2a
http_client: check current state when receiving FIN
2018-03-06 21:51:13 +01:00
Axel Lin
53ddb9244b
apps/sntp: Trivial build warning fix
...
Fix below build warning:
../../../../lwip/src/apps/sntp/sntp.c: In function ‘sntp_servermode_dhcp’:
../../../../lwip/src/apps/sntp/sntp.c:726:3: warning: ISO C90 forbids mixed declarations and code [-Wc90-c99-compat]
u8_t new_mode = set_servers_from_dhcp ? 1 : 0;
^~~~
Signed-off-by: Axel Lin <axel.lin@ingics.com>
2018-03-04 19:18:26 +08:00
goldsimon
0ee0393936
fix compiling http_client and altcp_proxyconnect with gcc
2018-02-22 09:12:51 +01:00
goldsimon
7b9e145fc5
http_client: change user-agent and make it overridable
2018-02-21 20:18:29 +01:00
goldsimon
2753eb1fb1
add an altcp layer for http proxy connect (e.g. to tunnel TLS through a http proxy)
...
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-21 20:18:05 +01:00
goldsimon
a0e900dd02
makefsdata: update usage output to code
2018-02-21 14:42:47 +01:00
goldsimon
325cdf3c0b
altcp_tls_mbedtls: restructure upper callbacks to prevent double-free
...
This fixes bug #53192 : use-after-free in altcp_mbedtls
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-21 14:20:34 +01:00
goldsimon
d66c0e3381
altcp: mbedtls: move freeing state->rx from close to dealloc (catch-all)
2018-02-20 22:12:11 +01:00
goldsimon
842b9f4429
altcp: simplify creating different types by adding an allocator concept
...
This is done with an example in the http_client
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-19 21:41:48 +01:00
Dirk Ziegelmeier
5b33d33e34
Add HTTP client to documentation
2018-02-19 09:01:44 +01:00
goldsimon
ef29f2d401
http_client: httpc_tcp_recv did not return inner_conn's recv return value
...
Signed-off-by: goldsimon <goldsimon@gmx.de>
Reported-by: Our Air Quality <info@ourairquality.org>
2018-02-18 09:02:00 +01:00
goldsimon
2648d30843
altcp_tls_mbedtls.c: tiny function rename
2018-02-16 13:57:38 +01:00
goldsimon
bd656efd64
http client: add https support, fix parsing header with chained pbufs
2018-02-16 12:29:40 +01:00
goldsimon
e87392cc85
http client: fix proxy support
2018-02-16 09:18:35 +01:00
goldsimon
3dafa72ec8
apps: add http client
...
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-15 22:10:29 +01:00
goldsimon
d4c4b0eec5
rename folder 'src/apps/httpd' to 'http'
...
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-15 20:13:25 +01:00
goldsimon
cd1516e2e4
mqtt: rewrote check for topc_len so that coverity is happy...
2018-02-15 09:15:40 +01:00
Axel Lin
5d5b8fbb46
Fix trivial copy & paste mistake for comment in header files
...
Signed-off-by: Axel Lin <axel.lin@ingics.com>
2018-02-14 22:49:12 +08:00
goldsimon
133bf70ab5
mqtt: slightly change some overflow checks
2018-02-14 12:37:35 +01:00
goldsimon
eea95459c9
mqtt: add more length validity checks in mqtt_message_received
...
This also (but not only) fixes bug #52345 ("MQTT buffer length check seems wrong")
2018-02-14 12:08:15 +01:00
goldsimon
731336223f
mqtt: add comments in mqtt_parse_incoming
2018-02-14 06:54:56 +01:00
goldsimon
e20e9bc3d4
Try to fix issues reported by coverity
2018-02-13 12:09:18 +01:00
goldsimon
010b0210ba
netif: ext_callback: make LWIP_NSC_ defines, not an enum; fix mdns accordingly
...
Re-applied after reverting d6e58d02a619813a4187ab53ab0ffc2f0b864ad7
2018-02-08 12:36:26 +01:00
goldsimon
f201d261b2
Revert "MDNS send probes to verify domain before use"
...
This reverts commit d6e58d02a619813a4187ab53ab0ffc2f0b864ad7.
Erik seems to have commit this by accident. Let's discuss this first
(see patch #9555 )
2018-02-08 12:28:04 +01:00
goldsimon
3cf906e073
Revert "netif: ext_callback: make LWIP_NSC_ defines, not an enum; fix mdns accordingly"
...
This reverts commit 6934bb442832406b5c41fc86bd934091b021f7ad.
Need to revert commit d6e58d02a619813a4187ab53ab0ffc2f0b864ad7 first, and that one produced merge conflicts.
2018-02-08 12:26:16 +01:00
goldsimon
f7be3d10ae
httpd: create "connection" and "content-length" headers when file is ready
...
see patch #9500
2018-02-07 21:27:42 +01:00
goldsimon
e8d7e82c8c
httpd: fix simple typo
2018-02-07 21:19:07 +01:00
goldsimon
6934bb4428
netif: ext_callback: make LWIP_NSC_ defines, not an enum; fix mdns accordingly
2018-02-07 20:35:49 +01:00
goldsimon
ea2e628ac3
httpd: get_http_headers: refactor decision for add_content_len
2018-02-03 21:58:45 +01:00
goldsimon
1a75112b47
httpd: ensure hs->keepalive is 0 if content length is not sent
...
Connections for custom files without the persistent flag were not
closed without this change.
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-03 21:53:44 +01:00
goldsimon
053a5e6e13
httpd: get_http_headers: fix content length check for custom files
...
Headers are never included here or else get_http_headers would not
have been called.
As a result, custom files need to set FS_FILE_FLAGS_HEADER_PERSISTENT
in file->flags if file->len is the correct length of the file.
See also patch #9500
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-03 21:51:33 +01:00
goldsimon
d5d30d49f2
httpd: check that file data is present when dynamic read is disabled
...
Signed-off-by: goldsimon <goldsimon@gmx.de>
2018-02-02 21:31:36 +01:00
Jens Nielsen
d6e58d02a6
MDNS send probes to verify domain before use
2018-02-02 11:10:09 +01:00
goldsimon
6706b3778e
httpd: add "struct file*" parameter to httpd_cgi_handler() callback
2018-02-02 09:29:52 +01:00
Giuseppe Modugno
ab281cb750
httpd: move httpd_cgi_handler() call
...
This patch moves in advance httpd_cgi_handler() call, before assigning
variables like hs->file and hs->left.
In this way, CGI handler could prepare the reply data and set the
"file properties", like file->data and file->len. At the exit, hs->file
and hs->left is correctly assigned.
The handler prototype says it can't access file pointer, however it is
simple to obtain it after setting LWIP_HTTPD_FILE_STATE that enables a
"file state" pointer. It is sufficient to assign file->state to file
itself in fs_open_custom().
For example, I have the request GET /login.cgi?user=admin&pwd=admin and
I have to reply with some JSON data. The answer depends on parameters
user and pwd passed in the query string.
2018-02-02 09:12:42 +01:00