Joseph Henry
bbc713d9e2
Changed references to vs->state to use guarded getters and setters in picoTCP driver
2017-09-19 11:27:37 -07:00
Joseph Henry
5e320fb950
Fixed lwIP driver thread model violation (tcp_close() was being called by application thread)
2017-09-19 10:52:59 -07:00
Joseph Henry
055a58ac63
Added multithreaded unit tests to selftest, standardization pass: conditional statement spacing
2017-09-18 11:58:41 -07:00
Joseph Henry
5ec6f1846b
Fixed uninitialized memory warning before write()
2017-09-17 23:26:38 -07:00
Joseph Henry
ed51f41b47
Fixed memory leak in VirtualTap. Used unique_ptr instead of new/delete pair
2017-09-17 23:13:33 -07:00
Joseph Henry
60800d14ba
Build fix, missing include for RLIMIT_NOFILE
2017-09-15 19:55:27 -07:00
Joseph Henry
11dcc1e959
Stubbed out some of the more obscure socket options for both drivers
2017-09-15 19:45:49 -07:00
Joseph Henry
7c586471f4
standardization pass: conditional statement spacing, removed NULL shorthand making checks more explicit
2017-09-14 13:17:37 -07:00
Joseph Henry
48a07c32a1
standardization pass: trim_right (trailing whitespaces)
2017-09-13 22:41:30 -07:00
Joseph Henry
3bec79314e
Added standardization target for code style, fixed LWIP_DEBUG redefinition warning, fixed rare tcp_close() and cb_poll() bugs
2017-09-13 22:34:25 -07:00
Joseph Henry
0dc390ddcf
Added differentiation of LIBZT_DEBUG and NS_DEBUG flags, other minor tweaks
2017-09-13 16:26:27 -07:00
Joseph Henry
5512ede4fd
Added application polling logic to lwip_cb_poll()
2017-09-11 17:01:59 -07:00
Joseph Henry
67b7c7e2e2
Added exception handling for virtual socket add/del functions
2017-09-11 17:01:02 -07:00
Joseph Henry
d1396c9917
Replaced get_pico_socket() with more generic code. Added checksum note in libzt.h
2017-09-11 14:00:44 -07:00
Joseph Henry
26f906046b
Commented out RAW PCB check in lwIP
2017-09-08 17:12:07 -07:00
Joseph Henry
1d4f36a811
Added selectable TCP_WRITE_FLAG_COPY mode on a per-socket basis, updated lwIP driver for socket limit checks
2017-09-08 16:13:56 -07:00
Joseph Henry
05fec81757
Added more safety checks to del_virtual_socket(), new zts_shutdown() implementation
2017-09-08 11:43:41 -07:00
Joseph Henry
4fd2db7dd6
tcp_received() fix
2017-09-07 18:09:19 -07:00
Joseph Henry
e18c1ccf80
Further improvements to selftest, lwIP driver updates
2017-09-06 18:02:30 -07:00
Joseph Henry
142c27091c
Added new unit tests and time-sync code for subtests, recvfrom() fixes
2017-09-05 16:51:07 -07:00
Joseph Henry
ec323c9842
Added basic DNS functionality, fixed stack smashing bug, organizational improvements
2017-08-30 14:13:13 -07:00
Piotr Sarna
f58b6152f3
Fixed potential stack corruption with sprintf
...
string representation of _nwid itself could take up 16 bytes,
so 17 is definitely not enough for this format string.
snprintf is used as a panic check for future changes,
so we could get a truncated string instead of stack corruption.
2017-08-25 16:35:43 +02:00
Joseph Henry
a723c70feb
tap initialization patch
2017-08-24 14:26:09 -07:00
Joseph Henry
9c901350b3
lwip fix
2017-08-24 12:46:13 -07:00
Joseph Henry
0b726b3ac6
lwipdev initialization fix
2017-08-24 12:27:29 -07:00
Joseph Henry
eff90c7d13
picotcp stack driver edge case bug fixes
2017-08-24 11:45:39 -07:00
Joseph Henry
bceadfbe46
Improvements to selftest, closure bug addressed
2017-08-18 07:43:29 -07:00
Joseph Henry
69ef094a37
Added beautify_eth_proto_nums() and mac2str()
2017-08-17 14:38:13 -07:00
Joseph Henry
8472a45ce3
Renamed lwIP low-level rx/tx functions
2017-08-17 14:37:01 -07:00
Joseph Henry
7d551d6198
Renamed SocketTap to VirtualTap and Connection to VirtualSocket to prevent confusion
2017-08-15 18:15:06 -07:00
Joseph Henry
ad17909f06
Build tweaks, better flag handling across makefiles
2017-08-14 15:53:53 -07:00
Joseph Henry
8e192c0ee8
Managed Routes now supported, with automatic add/remove
2017-08-14 11:25:44 -07:00
Joseph Henry
c0e652bcde
Added incomplete BSD-compatible network stack driver for lwIP
2017-08-08 11:16:01 -07:00
Joseph Henry
649e0d7887
Fix for STACK_LWIP compilation
2017-08-03 11:25:35 -07:00
Joseph Henry
7fb03a7f6a
Fix for NO_STACK compilation bug due to new ZT core helper API
2017-08-03 10:58:19 -07:00
Joseph Henry
9c4a5ae26b
Normalized indentation for entire project to TABS
2017-08-02 14:55:18 -07:00
Joseph Henry
7e00eda5a0
Normalized indentation for entire project to TABS
2017-08-02 14:54:29 -07:00
Joseph Henry
7e30474ee4
Implemented barebones VL2 SOCK_RAW functionality, moved ZT core helper functions from OneService to libzt
2017-08-02 14:39:21 -07:00
Garrett D'Amore
25f18f870e
Fix broken PICO compile (mismerge of LwIP reintroduction.)
2017-07-26 14:24:27 -07:00
Joseph Henry
409c2dc9de
Added layer2 SOCK_RAW example code and stubs
2017-07-26 02:13:13 -07:00
Joseph Henry
b105ddb060
Removed old linger code, formatting fixes, other minor adjustments
2017-07-26 02:12:28 -07:00
Joseph Henry
57d7b30f0c
Merge branch 'master' into gdamore-fixes
2017-07-26 00:08:10 -07:00
Joseph Henry
4e36fe28d5
BSD-license-compatible, and NO_STACK build variants
2017-07-25 23:40:24 -07:00
Garrett D'Amore
a31f81a34d
Silence an aligned access warning.
...
clang is a bit too strict about validating address alignments
when using packed structs. The only member is a 32-bit value,
so the alignment was correct, but this approach is "correct"
and guaranteed to work even if the structure was not aligned,
at the cost of an extra temporary variable and 32-bit copy.
2017-07-25 11:14:29 -07:00
Garrett D'Amore
24fa0c9a6c
In write, buf_w was unchecked.
...
We already checked for room, so the buffer should have room. We make this
a kind of assertion; this silences compiler warnings. Later, if this
becomes a thread-level race condition, come back and actually use buf_w
more meaningfully to handle partial writes.
2017-07-25 11:03:02 -07:00
Garrett D'Amore
8a6d4820cc
Debug buffer address returned from stack should be static.
2017-07-25 10:47:13 -07:00
Garrett D'Amore
1d21bc4145
zts_get_pico_socket needs to pass indirect pointer
2017-07-25 10:43:47 -07:00
Joseph Henry
4ac559a107
Added minor feature request: zts_poll/zts_select
2017-07-17 16:34:35 -07:00
Joseph Henry
43caf4a6f2
Minor changes to selftest, updated TESTING readme, removed old test personality conf files
2017-07-13 10:53:19 -07:00
Joseph Henry
494ec2508c
Added stubs for poll/select, improved selftest/echotest, Added ringbuffer for more efficient RX/TX
2017-07-12 11:44:31 -07:00