Jeff Becker
4fdff7f233
consolidate versions
2019-12-11 17:06:44 -05:00
Jeff Becker
f259cca0ba
remove mutexes
2019-12-11 16:49:00 -05:00
Jeff Becker
85e911fed0
fug
2019-12-11 16:36:13 -05:00
Jeff Becker
7a78160bf0
final change
2019-12-11 16:34:03 -05:00
Jeff Becker
5729d0bff5
more
2019-12-11 16:31:49 -05:00
Jeff Becker
c4f08e5145
finish remaining changes
2019-12-11 16:18:47 -05:00
Jeff Becker
abf9544ddc
make libuv on win32 work
2019-12-11 16:05:40 -05:00
Stephen Shelton
e2e9e63467
Optimize AlignedBuffer:::IsZero()
2019-12-10 11:50:52 -07:00
Jeff Becker
95eee4081a
trypushback
2019-12-10 11:49:32 -07:00
Jeff Becker
cdfdfa1068
use thread queue
2019-12-10 11:49:32 -07:00
Jeff Becker
8455d5d1cf
more cleanup
2019-12-10 11:49:32 -07:00
Jeff Becker
b286230d40
limit timer calls
2019-12-10 11:49:32 -07:00
Jeff Becker
35672e6d8c
call timers with queuer if set
2019-12-10 11:49:32 -07:00
Jeff Becker
cec36b62b5
make logic and net thread one in the same
2019-12-10 11:49:32 -07:00
Jeff Becker
581306e35f
prevent crash on exit
2019-12-10 11:49:32 -07:00
Jeff Becker
c9d38d421b
clang fixes
2019-12-10 11:49:32 -07:00
Jeff Becker
1ddc2b40aa
another attempt at travis fix
2019-12-10 11:49:32 -07:00
Jeff Becker
f29083f765
more travis fixes
2019-12-10 11:49:32 -07:00
Jeff Becker
4f87a95f66
fixes for travis
2019-12-10 11:49:32 -07:00
Jeff
22e9223e74
Merge pull request #955 from jagerman/remove-unused-arg
...
Remove unused argument
2019-12-10 07:51:48 -05:00
Jeff
fa75d7c96f
Merge pull request #957 from majestrate/reduce-cpu-use-in-tun-handler-2019-12-09
...
reduce cpu use in logic thread
2019-12-09 17:35:27 -05:00
Jeff Becker
a7884a82e2
use faster hashing
2019-12-09 17:35:05 -05:00
Jeff Becker
92bbda600b
remove callsto Router::PumpLL and stuff gets faster (or stuff)
2019-12-09 16:59:13 -05:00
Jason Rhinelander
6f92ac9c2b
Remove unused argument
...
Fixed a compiler warning about an unused argument, plus the argument
legitimately appears unused/obsolete now.
2019-12-09 11:17:02 -04:00
Jeff Becker
e90cb2929e
disable metrics by default
2019-12-09 08:13:38 -05:00
Jeff Becker
950006c036
reduce log levels at runtime
2019-12-09 08:08:30 -05:00
Jeff
512a350783
Merge pull request #953 from majestrate/try-preventing-router-lockup-2019-12-07
...
try fixing router lockup
2019-12-09 07:38:17 -05:00
Jeff Becker
c010bf05a6
use correct format string
2019-12-07 15:05:07 -05:00
Jeff Becker
f56e543d75
add deadlock checker and revert bencode change from long ago
2019-12-07 14:58:19 -05:00
Jeff Becker
c5f198cfa1
disable absl decorator in release
2019-12-07 14:22:10 -05:00
Jeff Becker
2eabe98d9b
add systemd watchdog if enabled on compile time
2019-12-07 14:21:26 -05:00
Jeff Becker
8ceb20452a
add absl annotations
2019-12-07 07:28:43 -05:00
Jeff Becker
fe6783eef6
squash possible race condition
2019-12-07 07:19:26 -05:00
Jeff Becker
eb87189514
try fixing router lockup
2019-12-07 07:08:00 -05:00
Jason Rhinelander
8d2c22fc72
Replace cppbackport with ghc-filesystem
...
From https://github.com/gulrak/filesystem which is more up-to-date and
looks better maintained than cppbackport.
2019-12-06 20:41:22 -04:00
Jeff
9c7355ff9c
Merge pull request #951 from majestrate/fix-ip-rewrite-on-snode-2019-12-06
...
use ipv6 only with ipv6 packets
2019-12-06 15:35:31 -05:00
Jeff
1396b7b857
Merge branch 'dev' into bootstrap-list-2019-12-06
2019-12-06 15:34:38 -05:00
Jeff Becker
7c0fc69ad8
use ipv6 only with ipv6 packets
2019-12-06 15:33:43 -05:00
Stephen Shelton
68a604070b
Merge pull request #945 from notlesh/key_manager_cleanup
...
Key manager cleanup (post 0.6-rc1)
2019-12-06 12:54:40 -07:00
Stephen Shelton
2c6226f54a
Backup SNApp keys when migrating to new ed25519 crypto
2019-12-06 11:21:14 -07:00
Jeff Becker
0afb3b320b
add bootstrap list functionality and utility
2019-12-06 12:32:46 -05:00
Stephen Shelton
11410a2748
Avoid trivial getters/setters in KeyManager
2019-12-06 10:31:19 -07:00
Stephen Shelton
66a058a2af
Make format
2019-12-06 10:13:09 -07:00
Jeff Becker
32da9e0817
reduce window
2019-12-05 14:58:24 -05:00
Jeff Becker
9be4092a2a
more close changes
2019-12-05 11:31:58 -05:00
Jeff Becker
3410f25fd0
close links lazy
2019-12-05 11:12:26 -05:00
Jeff Becker
87eab87b7f
only close outbound links
2019-12-05 11:05:10 -05:00
Jeff Becker
98d7116ffb
fix typo
2019-12-05 10:11:20 -05:00
Jeff Becker
39ab82ed8c
close sessions to non essential nodes
2019-12-05 09:54:44 -05:00
Stephen Shelton
eb5184ee09
Reinstate link test / update to use KeyManager
2019-12-04 13:13:41 -07:00
Jeff Becker
0c5c1aab1b
remove unneeded log statement
2019-12-04 08:06:16 -05:00
Stephen Shelton
23fc2ad042
Init key manager before InitOutboundLinks are configured
2019-12-03 16:55:16 -07:00
Jason Rhinelander
fd02662d9f
Bump default netid to gamma for 0.6
2019-12-03 16:24:13 -05:00
Jeff Becker
847ab3a47e
make it compile
2019-12-03 16:09:22 -05:00
Jeff
3f19b14c4f
Merge pull request #938 from majestrate/version-motto-bump-for-0.6.0-2019-12-03
...
bump version and motto
2019-12-03 16:00:22 -05:00
Jeff
27b1e36039
Merge pull request #936 from majestrate/dev
...
last changes before 0.6.0 version bump
2019-12-03 15:58:22 -05:00
Stephen Shelton
af2259db5f
Move lokid key API request to KeyManager
2019-12-03 12:32:19 -07:00
Stephen Shelton
49e248bfc1
Fix bad merge
2019-12-03 12:24:57 -07:00
Jeff Becker
91627931ad
bump version and motto
2019-12-03 13:33:43 -05:00
Stephen Shelton
93b8832026
Merge branch 'dev' into private-keys-backup-support
2019-12-03 11:20:45 -07:00
Jeff
76fc50cfb7
Merge pull request #914 from despair86/dev
...
win32 fixes
2019-12-03 13:08:55 -05:00
Stephen Shelton
521ef9b5bb
Handle link transport key in KeyManager
2019-12-03 10:58:53 -07:00
Jeff Becker
7d5fd132c8
make format
2019-12-03 12:55:24 -05:00
Jeff Becker
86a4ccd98f
unconditionally bundle first fragment in xmit
2019-12-03 12:54:32 -05:00
Jeff Becker
1f83fdb190
fix previous commit
2019-12-03 12:54:23 -05:00
Jeff Becker
19835ce501
dont use auto
2019-12-03 12:53:20 -05:00
Jeff Becker
1a6a66108d
make it compile
2019-12-03 12:53:11 -05:00
Jeff Becker
c88602ee16
break the world to make it faster
2019-12-03 12:53:01 -05:00
Jeff Becker
01b24c7090
limit connections
2019-12-03 12:49:29 -05:00
Jeff Becker
0f4c531d06
fix path resource leak
2019-12-03 12:49:15 -05:00
Jeff
b08897a214
Merge pull request #935 from jagerman/logic-thread-fixes
...
Logic thread fixes
2019-12-03 12:47:42 -05:00
Jeff
67b08e0e50
Merge pull request #933 from majestrate/loki-ping-call-2019-11-27
...
Loki ping call 2019 11 27
2019-12-03 12:45:40 -05:00
Jeff
8288bf3958
Merge pull request #931 from majestrate/rpc-fetch-privkey-2019-11-26
...
use curl to fetch from lokid rpc the identity key
2019-12-03 12:45:18 -05:00
Rick V
da8ee47370
tick more often
2019-12-03 11:18:07 -06:00
Rick V
44e8d07d47
fix error msg
2019-12-01 19:01:58 -06:00
Rick V
cf3469e11a
crash on wine, we support linux, ucb_unix, svr4
...
natively ffs. i tested this patch on wine 4.4 on fuckin
Solaris 11 snv_151
2019-12-01 19:01:40 -06:00
Jeff Becker
3c85691f81
limit calls to pumpll such that it gets called fast enough but not too much under load
2019-11-29 19:11:14 -04:00
Jeff Becker
a2fc35a7aa
lower limit to 25ms
2019-11-29 19:11:14 -04:00
Jeff Becker
5924a2cec0
limit calls
2019-11-29 19:11:14 -04:00
Jason Rhinelander
5d8f547d33
Set tun to non-blocking
...
If we can't write to it we want failure, not blocking.
2019-11-29 19:11:14 -04:00
Jason Rhinelander
740460318a
Die if job queue full
...
If this happens it's a pretty serious error; if someone is hitting it
occassionally it's better to know and update their queue size (and if it
is a runaway situation lokinet doesn't come back anyway).
2019-11-29 19:11:14 -04:00
Jeff Becker
28a2d471d6
style nitch
2019-11-29 19:11:14 -04:00
Jeff Becker
44e0e2c034
dont flood the logic queue
2019-11-29 19:11:14 -04:00
Jeff Becker
fba1e47d1c
call jobs in logic
2019-11-29 19:11:14 -04:00
Jeff Becker
f5ede2d875
ammend previous commit
2019-11-29 19:11:14 -04:00
Jeff Becker
3489753d5a
remove jenky call to logic thread in link server
2019-11-29 19:11:14 -04:00
Jeff Becker
0828307906
fix address mapping bug
2019-11-29 19:11:14 -04:00
Jeff Becker
5188873288
batch and flush
2019-11-29 19:11:14 -04:00
Jeff Becker
8849173112
try async decrypt then verify
2019-11-29 19:11:14 -04:00
Jeff Becker
2852601a28
flush in logic
2019-11-29 19:11:14 -04:00
Jeff Becker
d823d6fa70
only flush when no other jobs are executing
2019-11-29 19:11:14 -04:00
Jeff Becker
9e305c5b30
use lockless queues to gather results of transit traffic work
2019-11-29 19:11:14 -04:00
Jeff Becker
d591394ad2
dont process empty queues
2019-11-29 19:11:14 -04:00
Jeff Becker
e2472d985d
process transit hops on flush
2019-11-29 19:11:14 -04:00
Jeff Becker
1a06da9c3d
reduce calls in link pump
2019-11-29 19:11:14 -04:00
Jason Rhinelander
d13a3d2b62
Don't flush here; we already have a tick flushing
2019-11-29 19:11:14 -04:00
Thomas Winget
6d506302dc
Show number of logic thread jobs in debug builds
2019-11-29 19:11:14 -04:00
Thomas Winget
6acf7bff7e
Track and log UV event loop ticks in debug builds
2019-11-29 19:11:14 -04:00
Jeff Becker
285a9a1dd5
prevent segfault
2019-11-29 19:11:14 -04:00
Jeff Becker
a3a62c34f3
use timer guard for all jobs in debug mode
2019-11-29 19:11:14 -04:00
Jeff Becker
af663d8b10
prune members in timer context
2019-11-29 19:11:14 -04:00
Jeff Becker
11d4760c3d
add metrics tracking for logic jobs in debug mode
2019-11-29 19:11:14 -04:00
Jeff Becker
ba0fd223d9
reduce number of jobs we put onto the logic thread
2019-11-29 18:45:06 -04:00
Stephen Shelton
a0699ad229
Undo adding of crypto version to RouterContact, other fixes
2019-11-27 11:30:19 -07:00
Jeff Becker
d880eec1de
ping lokid rpc
2019-11-27 13:11:15 -05:00
Jeff Becker
098915bb8e
add check for identity key validity
2019-11-26 20:40:55 -05:00
Jeff Becker
5868a25fcc
clear response between tries
2019-11-26 17:13:41 -05:00
Jeff Becker
d685057754
update readme and disable curl on windows
2019-11-26 17:11:13 -05:00
Jeff Becker
d12c75ce1e
move sleep
2019-11-26 17:04:52 -05:00
Jeff Becker
61b75828f0
sleep
2019-11-26 17:03:45 -05:00
Jeff Becker
3878ebd534
use curl to fetch from lokid rpc the identity key
2019-11-26 16:58:20 -05:00
Stephen Shelton
e8e2e21fa2
Reorganize priv key file loading a bit and hook KeyManager into Router
2019-11-26 12:42:41 -07:00
Jeff
f8c6c1379a
Merge pull request #929 from majestrate/increase-logic-queue-size-2019-11-25
...
make logic job queue 8 times bigger
2019-11-26 13:32:25 -05:00
Jeff Becker
dd48b149ca
make job queue size configurable
2019-11-25 16:30:34 -05:00
Jeff Becker
853108ce6e
make logic job queue 8 times bigger
2019-11-25 16:15:31 -05:00
Jeff Becker
cbb7196b30
fix "zero hop" bug
2019-11-25 11:53:03 -05:00
Stephen Shelton
7084dae79a
Implement code to move old key files out of the way
2019-11-22 16:11:59 -07:00
Jeff
ee40389f05
Merge pull request #916 from majestrate/add-contention-killer-2019-11-14
...
assorted crap
2019-11-22 16:31:15 -05:00
Jeff Becker
c3858a56df
make it compile
2019-11-22 16:23:21 -05:00
Jeff Becker
34bc3da069
flush quues of other paths
2019-11-22 16:23:20 -05:00
Jeff Becker
6f95fbfece
work in progress
2019-11-22 16:23:20 -05:00
Jeff Becker
ac686a9329
remove valgrind access errors
2019-11-22 16:23:20 -05:00
Jeff Becker
0ec4e583d4
initialize with zeros
2019-11-22 16:23:20 -05:00
Jeff Becker
065b022427
std::move
2019-11-22 16:23:20 -05:00
Jeff Becker
b8f773eb73
use lambda
2019-11-22 16:23:20 -05:00
Jeff Becker
250cfea1e9
remove use of void * in godawful old code from a time before happyness
2019-11-22 16:23:20 -05:00
Jeff Becker
b207db626f
please the gods of valgrind
2019-11-22 16:23:20 -05:00
Jeff Becker
d44d034775
make contention checker templated
2019-11-22 16:23:19 -05:00
Jeff Becker
1fa0a0aab2
make it compile
2019-11-22 16:23:19 -05:00
Jeff Becker
fdbaaa8188
try fixing file log segfault
2019-11-22 16:23:19 -05:00
Jeff Becker
1188763ece
typo fix in release
2019-11-22 16:23:19 -05:00
Jeff Becker
56dce90de9
add trace log level for tracking logic thread jobs
2019-11-22 16:23:19 -05:00
Jeff Becker
eb6d042e73
make sure all calls of logic thread jobs are not having contention
2019-11-22 16:23:18 -05:00
Jeff Becker
d7f09a365d
contention killer
2019-11-22 16:23:18 -05:00
Stephen Shelton
db56e17c23
Rename bencode function for clarity
2019-11-22 14:14:37 -07:00
Stephen Shelton
0c02ea8d2e
Add "keyfile version" to RouterContact
2019-11-22 14:06:15 -07:00
Jason Rhinelander
d3082fffc9
Lower the ev tick interval to 10ms
...
When there's nothing waiting we wait this long unconditionally, but that
can add a lot of latency across a path.
There are likely better ways to handle this via libuv's run handlers,
but this addresses the latency until we figure that out.
2019-11-22 17:05:51 -04:00
Stephen Shelton
1666498405
Replace bencode_write_version_entry with a more general-purpose function for writing bencoded dictionary entries
2019-11-22 10:39:35 -07:00
Stephen Shelton
fd02e3e149
Stub out KeyManager class
2019-11-21 20:57:41 -07:00
Jason Rhinelander
e0340e86b2
clang-format fixes
2019-11-20 17:45:56 -04:00
Jason Rhinelander
d96d33329b
Merge pull request #912 from majestrate/logic-thread-fix-2019-11-13
...
fix logic thread behavior
2019-11-19 15:26:35 -04:00
Jeff
8f6a18f411
Merge pull request #915 from notlesh/fix-session-key-mismatch-2019-11-19
...
Fix #911 : Drop new inbound IWP sessions when the first packet can't be handled
2019-11-19 14:25:49 -05:00
Jason Rhinelander
6524563d33
Merge pull request #897 from majestrate/bencode-seek-for-version-2019-11-03
...
seek for version and set it before deserializing
2019-11-19 15:24:07 -04:00
Stephen Shelton
b5b8cf0745
Reduce log level of IWP session issues as they may be encountered frequently and normally
2019-11-19 12:17:34 -07:00
Stephen Shelton
9eed243346
Merge pull request #860 from notlesh/null_mutex_clarity
...
Null mutex clarity (via comments / log statement)
2019-11-19 11:19:44 -07:00
Stephen Shelton
46fe64c2e6
make format (and git commit --amend to re-trigger CI)
2019-11-19 10:07:27 -07:00
Stephen Shelton
ef2670dfb4
Drop new inbound IWP sessions when the first packet can't be handled
2019-11-19 09:24:29 -07:00
Jeff Becker
168d25f244
add warning when trying to queue onto full logic thread
2019-11-14 12:18:20 -05:00
Jeff Becker
b34caa3e26
make unit tests pass for iwp
2019-11-14 11:48:02 -05:00
Jeff Becker
1a864832c8
make format
2019-11-14 10:07:40 -05:00
Jeff Becker
b31d7b75fc
Merge remote-tracking branch 'origin/dev' into logic-thread-fix-2019-11-13
2019-11-14 10:07:19 -05:00
Jeff Becker
f16c9f9b5d
iot seems that logic thread didn't work the way i remember it should
...
make logic work the way it should
2019-11-14 10:06:53 -05:00
Jeff Becker
3c8e148372
prevent double free crap with shared_ptr
2019-11-13 18:16:34 -05:00
Thomas Winget
5ce6ed5134
fixes some logical errors in per-path queues
2019-11-07 15:05:04 -05:00
Thomas Winget
23a9773e1e
remove our paths from outbound queues
2019-11-07 13:23:14 -05:00
Thomas Winget
ef1a5652ef
remove our paths from outbound queues
2019-11-07 13:23:06 -05:00
Thomas Winget
17de3f2478
do...while; make format; remove erroneous GUARDED_BY
2019-11-06 10:26:51 -05:00
Thomas Winget
12adff570d
fix seg fault, fix uninitialized static member
2019-11-06 10:26:51 -05:00
Thomas Winget
75512b1b58
ban zero id for pathid; clarity and cleanup
2019-11-06 10:26:51 -05:00
Thomas Winget
9d3e7d349c
Add per-path queues, prioritize control messages over traffic
2019-11-06 10:26:51 -05:00
Jeff
c05d7b69fc
Merge pull request #904 from majestrate/try-fixing-path-shit-again-2019-11-05
...
make path builds work
2019-11-05 12:21:51 -05:00
Jeff Becker
8d44eefead
make router give time directly
2019-11-05 12:10:14 -05:00
Jeff Becker
2c5561fc3c
make format
2019-11-05 12:01:34 -05:00
Jeff Becker
b589ea96ff
remove printf
2019-11-05 12:00:33 -05:00
Jeff Becker
7ee026fa50
make path builds work again
2019-11-05 11:58:53 -05:00
Jeff Becker
9b99752276
i hate windows
2019-11-05 08:19:27 -05:00
Jason Rhinelander
b0ab703c45
Silence unused variable warnings in release build
2019-11-04 15:21:32 -04:00
Jeff Becker
0d89f1170b
make it compile
2019-11-04 13:53:53 -05:00
Jeff Becker
c9f26c4911
call Router::PumpLL after every batch of packets from a link session
2019-11-04 13:49:08 -05:00
Jeff Becker
034469bfbf
Merge remote-tracking branch 'origin/dev' into fix-pump-order-2019-11-04
2019-11-04 13:25:36 -05:00
Jeff Becker
90f523881a
try interchanging pump order
2019-11-04 13:25:05 -05:00
Jeff
820f69549f
Merge pull request #899 from majestrate/fix-path-build-2019-11-03
...
make path builds work
2019-11-04 12:40:04 -05:00
Jeff Becker
1fc36f4832
changes from review
2019-11-04 12:24:42 -05:00
Jeff Becker
7c35b00f98
Revert "move calling of path build sccess hook to correct place"
...
This reverts commit 902cd86a3b
.
2019-11-04 08:39:29 -05:00
Jeff Becker
8befd6f2db
flush link session encrypt queue immediately after handling plaintext packets
2019-11-04 08:34:30 -05:00
Jeff Becker
902cd86a3b
move calling of path build sccess hook to correct place
2019-11-03 16:07:39 -05:00
Jeff Becker
9d266dbec7
meh
2019-11-03 15:52:00 -05:00
Jeff Becker
e25356c035
use <= not ==
2019-11-03 14:53:41 -05:00
Jeff Becker
89e5b6b4cc
try fixing leak
2019-11-03 14:38:34 -05:00
Jeff Becker
bdb0b847f8
seek for version and set it before deserializing
2019-11-03 10:31:01 -05:00
Jeff
a843cf44cc
Merge pull request #892 from despair86/dev
...
add patch for libsodium 1.0.17 and zmq-latest
2019-11-01 10:57:19 -04:00
Jeff
9ace1b2398
Merge pull request #870 from majestrate/disable-doh-using-isp-backdoor-provided-by-mozilla-thanks-from-nsa
...
disable DoH
2019-11-01 10:54:00 -04:00
Jeff
30fa45fa05
Merge pull request #895 from majestrate/fix-dns-crash-2019-11-01
...
fix issue #894
2019-11-01 10:53:29 -04:00
Jeff
683594b66a
Merge pull request #877 from majestrate/fix-exit-traffic-bug-2019-10-28
...
fix warnings and prevent bug that sends invalid traffic to user
2019-11-01 10:53:17 -04:00
Jeff Becker
d2be8ac384
fix issue #894
2019-11-01 09:40:31 -04:00
Rick V
28f508c1d2
fix note
2019-10-31 17:22:59 -05:00
Rick V
00440f91eb
add patch for latest stable libzmq on windows with a configure note
2019-10-31 17:10:09 -05:00
Rick V
0b8a518f24
add patch for libsodium 1.0.17
2019-10-31 17:05:58 -05:00
Rick V
44a8b9d3eb
add patchset for libsodium-upstream-stable so we can get rid of vendored
...
lib
2019-10-30 18:02:34 -05:00
Rick V
df29052a75
fix windows
2019-10-30 18:02:34 -05:00
Rick V
e9b4053bac
oops fix up some missing code
2019-10-30 18:02:33 -05:00
Rick V
e901580223
ok set write handler in event loop
2019-10-30 18:02:33 -05:00
Rick V
cfd696b4d9
just write the data straight into the socket
2019-10-30 18:02:32 -05:00
Rick V
d7900a8459
c-f everything
2019-10-30 18:02:32 -05:00
Rick V
df6fe4b6ac
emit libuv-like stub externally
2019-10-30 18:02:32 -05:00
Rick V
46169da7bf
ok add the write handler here too
2019-10-30 18:02:31 -05:00
Rick V
33378b2c0c
ok implement libuv stubs for tcp connectors
2019-10-30 18:02:31 -05:00
Jeff Becker
2bf1e4f46a
enable IOS on IOS
2019-10-30 09:33:23 -04:00
Jeff
8debf6870d
Merge pull request #879 from majestrate/parenthesis-are-hard-2019-10-28
...
fix bounds check
2019-10-29 12:14:41 -04:00
Jeff Becker
e2890e925b
make it compile
2019-10-28 17:46:39 -04:00