Compare commits

...
468 Commits
Author SHA1 Message Date
Adam Ierymenko af705ac504 VERSIOM 1.6.1
This is a minor point release to fix a number of issues. See
RELEASE-NOTES.md.
2020-11-26 00:49:38 -05:00
Adam Ierymenko af6d01e79b Mac fix (probably) for old versions that require tap.kext. 2020-11-26 00:36:52 -05:00
Adam Ierymenko 1ef3b2d526 Windows build. 2020-11-25 21:36:31 -05:00
Adam Ierymenko 1afd097445 Microsoft signed 32-bit Windows x86 driver. 2020-11-25 23:45:28 -05:00
Adam Ierymenko 52fad6e18f Merge branch 'dev' of http://git.int.zerotier.com/ZeroTier/ZeroTierOne into dev 2020-11-25 23:35:47 -05:00
Adam Ierymenko 3f921c01a6 Merge branch 'dev' of http://git.int.zerotier.com/ZeroTier/ZeroTierOne into dev 2020-11-25 23:35:39 -05:00
Adam Ierymenko eefe34354e Embeddable MSI for new MS-signed X64 Windows tap driver. 2020-11-25 23:35:32 -05:00
Grant Limberg 5188c7d41f com & com security already initialized by here 2020-11-25 20:06:43 -08:00
Grant Limberg f2ba613fb5 line endings 2020-11-25 19:02:00 -08:00
Grant Limberg 6cfdd5b2c1 force eol=crlf for driver .inf files 2020-11-25 18:22:52 -08:00
Grant Limberg f2cd7cd4eb set deployment target for tap agent 2020-11-25 15:34:52 -08:00
Grant Limberg 0a8b692482 fix device binding & possible loopback issue on FreeBSD 2020-11-25 12:03:17 -08:00
Adam Ierymenko 1542163689 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne 2020-11-25 14:28:48 -05:00
Adam Ierymenko 9d66d876f4 Likely fix for some alignment issues on ARM. 2020-11-25 14:28:41 -05:00
Grant Limberg 0456a71295 Windows feedback loop fix 2020-11-25 11:05:36 -08:00
Grant Limberg 70b1b4ecc7 Buffer<> has no .empty() method 2020-11-25 09:49:58 -08:00
Adam Ierymenko bc4bd29488 Merge branch 'master' of github.com:zerotier/ZeroTierOne 2020-11-25 10:50:35 -05:00
Adam Ierymenko f906eec42e Merge branch 'dev' of http://git.int.zerotier.com/ZeroTier/ZeroTierOne into dev 2020-11-24 23:37:54 -05:00
Adam Ierymenko 73b5eadd3c Windows X64 Microsoft-Signed Driver for Windows 10 2020-11-24 23:37:37 -05:00
Adam Ierymenko 1f8905dfc9 Merge pull request #1191 from athoik/armv7ve
Add support for armv7ve
2020-11-24 19:25:53 -05:00
Adam Ierymenko 4465d36db5 Merge pull request #1194 from gutleib/master
Add support for Elbrus-family CPU
2020-11-24 19:25:10 -05:00
Adam Ierymenko d64c5a92c6 Merge pull request #1233 from dosuperuser/improvement/optimizations
Minor C++ optimizations
2020-11-24 19:24:36 -05:00
Adam Ierymenko 0ba358a3d4 Merge pull request #1294 from darkain/master
Add ZT_NO_UNALIGNED_ACCESS for ARMv6/7 on FreeBSD
2020-11-24 19:23:19 -05:00
Grant Limberg 86ff1e7cd2 another comparison fix 2020-11-24 14:12:30 -08:00
Adam Ierymenko 13d7e2f2b9 Merge branch 'dev' of github.com:zerotier/ZeroTierOne into dev 2020-11-24 17:02:17 -05:00
Adam Ierymenko bad1e0d529 CentOS build fixes to build in Cent7. 2020-11-24 14:01:46 -08:00
Grant Limberg 6b21a4f494 fix dns equality check in Android 2020-11-24 13:51:00 -08:00
Adam Ierymenko 891815054c Version bumps. 2020-11-24 16:27:19 -05:00
Adam Ierymenko ce2fb18c02 Set MacOS version flag on assembly file. 2020-11-24 14:27:44 -05:00
Adam Ierymenko 2f359a43bf 1.6.1 notes 2020-11-23 20:17:09 -05:00
Grant Limberg a1b72f0e1a Merge branch 'dev' of github.com:zerotier/ZeroTierOne into dev 2020-11-23 14:54:39 -08:00
Grant Limberg de308f05e0 missing break in InetAddress::ipScope() 2020-11-23 14:54:13 -08:00
Joseph Henry ecfac0601a Add new bond control commands to CLI 2020-11-23 09:59:28 -08:00
Vincent Milum Jr 93ffd75b02 Add ZT_NO_UNALIGNED_ACCESS for ARMv6/7 on FreeBSD
Unaligned access caused SIGBUS errors on ARMv6 and ARMv7 targets under FreeBSD.

This was also the cause of the repeating TAP devices. Each time the SIGBUS happened, the service would auto-restart itself, create a new TAP device, and then crash again.

The particular place causing the SIGBUS was:
https://github.com/zerotier/ZeroTierOne/blob/master/node/Utils.hpp#L695
2020-11-21 13:30:31 -08:00
Joseph Henry 8af4eff43e Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-11-20 20:34:54 -08:00
Adam Ierymenko 167645ba6d Fix for musl libc. 2020-11-20 21:10:08 -05:00
Adam Ierymenko baeab92737 VERSION 1.6.0
See RELEASE-NOTES.md for details.
2020-11-20 18:53:33 -05:00
Joseph Henry 24162fd490 Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-11-19 14:39:40 -08:00
Grant Limberg 95da2bcbcf move CoUninitialize to the proper place at the end of the tap thread 2020-11-19 14:13:16 -08:00
Grant Limberg a9e4fb0ed9 Fix multiple networks on Windows 2020-11-19 14:10:34 -08:00
Adam Ierymenko 45b092532e Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-11-19 13:44:03 -05:00
Adam Ierymenko 3ec932e194 MacOS ARM64 universal binary build fixes. 2020-11-19 13:43:57 -05:00
Adam Ierymenko 565bef05af Release notes and version bumps. 2020-11-19 13:24:30 -05:00
Adam Ierymenko a0c78da1ad Revert "Tune thread count based on hardware concurrency."
This reverts commit 7b14aeb53e.
2020-11-18 22:54:05 -05:00
Adam Ierymenko 7b14aeb53e Tune thread count based on hardware concurrency. 2020-11-18 22:42:00 -05:00
Adam Ierymenko f934a09baa Build fix. 2020-11-18 22:32:57 -05:00
Adam Ierymenko 414c248cc5 Try another approach... 2020-11-18 22:26:06 -05:00
Adam Ierymenko ca428233ba Revert "Try another optimization in LinuxEthernetTap."
This reverts commit a390629371.
2020-11-18 22:24:18 -05:00
Adam Ierymenko 3712f9b318 Revert "Shutdown fix."
This reverts commit 11545bdb5d.
2020-11-18 22:24:09 -05:00
Adam Ierymenko 11545bdb5d Shutdown fix. 2020-11-18 22:13:06 -05:00
Adam Ierymenko a390629371 Try another optimization in LinuxEthernetTap. 2020-11-18 22:06:17 -05:00
Adam Ierymenko e3e188109d Build fix. 2020-11-18 10:14:39 -08:00
Adam Ierymenko 7cbbc38b89 Reduce mutex use in LinuxEthernetTap. Try to squeeze a bit more powah out of it. 2020-11-18 12:50:34 -05:00
Joseph Henry bd1861ef4d Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-11-17 17:24:16 -08:00
Adam Ierymenko b152f9e1d3 Version 1.6.0 bump in version.h 2020-11-17 15:15:06 -08:00
Joseph Henry 24339092f7 Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-11-17 14:05:33 -08:00
Adam Ierymenko 4bd58d47cf Revert "Try factoring out a mutex to see if its faster."
This reverts commit 982c32322b.
2020-11-17 12:52:48 -08:00
Adam Ierymenko 982c32322b Try factoring out a mutex to see if its faster. 2020-11-17 15:48:15 -05:00
Adam Ierymenko 2fcc344299 Some buffer tuning. 2020-11-17 15:34:42 -05:00
Adam Ierymenko 3acd901c88 Build fixes. 2020-11-17 12:13:08 -05:00
Adam Ierymenko 0795dbf5f1 Revert "Moar threadz"
This reverts commit 101a3a7d74.
2020-11-16 19:06:52 -08:00
Adam Ierymenko 101a3a7d74 Moar threadz 2020-11-16 21:49:51 -05:00
Adam Ierymenko 2da162bed7 Split Linux tap receive into two threads: one reader, one processor. 2020-11-16 21:40:25 -05:00
Adam Ierymenko 5282e06fd4 Tun/tap flags fix. 2020-11-16 19:08:09 -05:00
Adam Ierymenko dc806dd718 Try pipelining tap reads on Linux for a little more speed. 2020-11-16 18:56:00 -05:00
Adam Ierymenko 31d8758ad9 Apple "fat binaries" are back! 2020-11-16 16:30:15 -05:00
Joseph Henry ae70db0535 Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-11-16 12:04:03 -08:00
Adam Ierymenko 6b67cb0e2a Linux build fixes. 2020-11-16 11:11:52 -08:00
Adam Ierymenko 250f0ef9db Remove dead code. 2020-11-16 13:51:27 -05:00
Joseph Henry a690ffdb7c Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-11-15 19:00:02 -08:00
Adam Ierymenko 4aab9121d9 Linux build fixes, and new route code seems to work. 2020-11-13 22:25:12 -05:00
Adam Ierymenko 5ea7ef6b65 Rework Linux route setting to actually consult netlink interface. 2020-11-13 22:06:58 -05:00
Adam Ierymenko a3875f9965 Add a route DB to LinuxNetLink to make route sync robust. 2020-11-13 21:55:31 -05:00
Adam Ierymenko 4e3a59f329 Build fix. 2020-11-13 21:21:28 -05:00
Adam Ierymenko 3730917dda LinuxNetLink cleanup 2020-11-13 21:06:34 -05:00
Adam Ierymenko 57516cfbe6 revert queue... not quite what we need 2020-11-13 21:01:55 -05:00
Adam Ierymenko bb62279a20 Queue up managed route syncs and do them periodically to avoid dependency problems. 2020-11-13 20:25:03 -05:00
Adam Ierymenko e8be28734b Linux netlink and route setting... work in progress. 2020-11-13 19:07:54 -05:00
Adam Ierymenko 6c5a097711 Use LinuxNetLink for routes on Linux... still needs testing/debugging on an actual Linux machine. 2020-11-13 18:16:14 -05:00
Adam Ierymenko 16a878adb1 ... route fix test 2020-11-13 16:18:00 -05:00
Adam Ierymenko 020d882e82 Route assignment fix. 2020-11-13 16:02:59 -05:00
Adam Ierymenko 44af828aa4 Tweak multicast settings to prevent failures due to TX queue overflow. 2020-11-12 22:21:43 -05:00
Adam Ierymenko 26a0cbcd73 Revert "Push credentials in multicast."
This reverts commit 1316ee3127.
2020-11-12 20:53:23 -05:00
Adam Ierymenko 1a106bca3b Revert "Build fix, and move multicast pushCredentialsIfNeeded."
This reverts commit cc42d6f4e0.
2020-11-12 20:53:14 -05:00
Adam Ierymenko cc42d6f4e0 Build fix, and move multicast pushCredentialsIfNeeded. 2020-11-12 20:40:10 -05:00
Adam Ierymenko 1316ee3127 Push credentials in multicast. 2020-11-12 20:33:31 -05:00
Adam Ierymenko eadca9dd75 Build fix. 2020-11-11 15:29:01 -05:00
Adam Ierymenko 59dd71187e Build fix. 2020-11-11 15:14:08 -05:00
Adam Ierymenko 36e167013a More Linux tap shotgun debugging. 2020-11-11 15:12:16 -05:00
Adam Ierymenko 2d489a8679 Another possible workaround for what seems to be a Linux bug in some newer kernels. 2020-11-11 14:42:56 -05:00
Adam Ierymenko d735a1d04c Reorder some stuff in LinuxEthernetTap as possible workaround for MAC-set weirdness. 2020-11-11 12:49:56 -05:00
Adam Ierymenko 9480ff1f37 Fix some timestamp signedness mismatches. 2020-11-11 11:46:09 -05:00
Adam Ierymenko d2f2abe525 Add force-exit timeout to get around some of the exit hang issues users have observed. Will punt full diagnosis to V2 which rewrites all these code paths anyway. 2020-11-10 16:30:55 -05:00
Adam Ierymenko e9e20fdad8 Increase multicast announce frequency a little. 2020-11-10 16:16:52 -05:00
Adam Ierymenko 53ba413d32 Dont use AES in HELLO. 2020-11-09 20:52:49 -05:00
Adam Ierymenko 7280fcdec2 Only define FreeBSD hwcaps stuff if ARM crypto is enabled for compiled. 2020-11-09 19:54:32 -05:00
Adam Ierymenko cbcd2be232 Merge pull request #1288 from darkain/dev
FreeBSD ARMv6, ARMv7, and Aarch64 support
2020-11-09 19:50:46 -05:00
Vince 83a2dcb65a FreeBSD ARMv6, ARMv7, and Aarch64 support 2020-11-07 14:16:03 -08:00
Adam Ierymenko dd65680150 Windows build fixes, version bump in AIP. 2020-11-06 11:18:41 -08:00
Adam Ierymenko 90f18f7ee7 Fix for ZTO-33 (Jira), only assign routes if there is a viable source IP. 2020-11-06 11:01:45 -05:00
Adam Ierymenko 317263b31c Remove unused variable on non-windows 2020-11-02 19:09:11 -05:00
Adam Ierymenko 52679d2784 Simplify and fix managed route logic. 2020-11-02 19:02:07 -05:00
Adam Ierymenko 763d1cc3dc Some more changes for slow network leaving on Mac. 2020-11-02 14:00:35 -05:00
Adam Ierymenko c9fe04d8ea Version bump in prep for 1.6.0 beta 2 2020-10-30 17:42:15 -04:00
Adam Ierymenko f2c490345c Remove unnecessary includes that can cause compile problems. 2020-10-30 16:14:59 -04:00
Adam Ierymenko fe5aad3cef Some Mac feth tap changes to hopefully fix slow-leave problem. 2020-10-30 10:40:34 -04:00
Joseph Henry 927bc2e33d Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-10-22 14:04:41 -07:00
Joseph Henry 1331739ee4 Remove (some) debug tracing in Bond which may cause a segfault 2020-10-21 18:40:55 -07:00
Grant Limberg 3da8f5f053 freaking JNI 2020-10-21 16:08:19 -07:00
Grant Limberg fbbcf292c6 forgot accessors 2020-10-21 15:06:50 -07:00
Grant Limberg 2851a9577c JNI for dns configuration 2020-10-21 14:18:29 -07:00
Adam Ierymenko ed9b09e980 Missing flag. 2020-10-20 18:52:36 -04:00
Adam Ierymenko bcb3fc7fc0 Only use SSE/SSE2 for X64 for regular stuff. 2020-10-20 18:51:38 -04:00
Adam Ierymenko 70f37962cf Backport AES fixes for compiler, arch, and splitting into separate files. 2020-10-20 18:50:28 -04:00
Joseph Henry fd7f61bab7 Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-10-14 18:40:38 -07:00
Joseph Henry 5f8714a0cd Remove minor non-functional flow hashing stubs 2020-10-14 18:40:20 -07:00
Adam Ierymenko 8d83b9b7c5 Revert change to path quality to fix IPv6 issue in beta. We will rework this in 2.x. 2020-10-14 20:41:58 -04:00
Adam Ierymenko 2c75be0d64 Do not always enable SSE4 on X64 due to old Atom chips. Enable instead only for AES-NI code which is only run if AES-NI is present, which it is not on these old chips. 2020-10-13 16:08:30 -04:00
Grant Limberg ee04118172 null check 2020-10-13 08:24:36 -07:00
Adam Ierymenko fe1ce885a0 Version 1.6.0 (1.5.0 is a beta!) is a significant release that incorporates a number of back-ported fixes and features from the ZeroTier 2.0 tree.
Major new features are:

 * **Multipath support** with modes modeled after the Linux kernel's bonding driver. This includes active-passive and active-active modes with fast failover and load balancing. See section 2.1.5 of the manual.
 * **DNS configuration** push from network controllers to end nodes, with locally configurable permissions for whether or not push is allowed.
 * **AES-GMAC-SIV** encryption mode, which is both somewhat more secure and significantly faster than the old Salsa20/12-Poly1305 mode on hardware that supports AES acceleration. This includes virtually all X86-64 chips and most ARM64. This mode is based on AES-SIV and has been audited by Trail of Bits to ensure that it is equivalent security-wise.

Known issues that are not yet fixed in this beta:

 * Some Mac users have reported periods of 100% CPU in kernel_task and connection instability after leaving networks that have been joined for a period of time, or needing to kill ZeroTier and restart it to finish leaving a network. This doesn't appear to affect all users and we haven't diagnosed the root cause yet.
 * The service sometimes hangs on shutdown requiring a kill -9. This also does not affect all systems or users.
 * AES hardware acceleration is not yet supported on 32-bit ARM, PowerPC (32 or 64), or MIPS (32 or 64) systems. Currently supported are X86-64 and ARM64/AARCH64 with crypto extensions.
 * Some users have reported multicast/broadcast outages on networks lasting up to 30 seconds. Still investigating.

We're trying to fix all these issues before the 1.6.0 release. Stay tuned.
2020-10-08 18:10:13 -04:00
Adam Ierymenko 24769219b5 Merge branch 'dev' 2020-10-08 18:08:24 -04:00
Adam Ierymenko da6fe18e17 Merge branch 'master' of github.com:zerotier/ZeroTierOne 2020-10-08 18:08:18 -04:00
Adam Ierymenko a973a6e10e Leave feth devices over feth10000 alone. 2020-10-08 12:04:57 -04:00
Adam Ierymenko 5bc64c4c4e Windows build fixes and version bump in Advanced Installer. 2020-10-07 15:56:00 -07:00
Travis LaDuke bd92990165 Update feature_request.md 2020-10-07 10:36:04 -07:00
Adam Ierymenko e26a8be3df Be more consistent about versioning. 2020-10-07 11:55:47 -04:00
Adam Ierymenko 3ef1c8e3fa Use 1.5.0 for package version for centos. 2020-10-06 23:31:20 -04:00
Adam Ierymenko 0ab4b903f4 Cert and codesign tweaks, release notes. 2020-10-06 18:09:51 -04:00
Adam Ierymenko b2ea5aa747 Version bump to 1.5.0 internally and 1.6.0-beta1 in packages. 2020-10-05 20:23:52 -04:00
Grant Limberg c80843e496 Revert "remove redundant writes when changes come from Central"
This reverts commit f9396f979f.
2020-10-05 13:32:47 -07:00
Grant Limberg f9396f979f remove redundant writes when changes come from Central
network & member changes tagged with `"fromCentral": true` will not be rewritten to the db
2020-10-05 11:03:03 -07:00
Adam Ierymenko 610d4ff016 Remove old tap kext from normal pkg as it is too old to be notarized (signature too old, not sure if we can sign again as kexts are being deprecated). It is only used on very old MacOS versions that are rolling off support. 2020-10-02 18:42:40 -04:00
Adam Ierymenko f16421225d Enable hardened executable mode on Mac, should be fine... 2020-10-02 18:36:24 -04:00
Adam Ierymenko d82b3684ac Enable RV64 2020-09-30 21:17:04 -04:00
Adam Ierymenko d7e5a92fe6 Increase debian build parallelism. 2020-09-30 17:39:15 -07:00
Adam Ierymenko bb45f9ca3c Upgrade cpp-httplib 2020-09-30 15:21:58 -04:00
Adam Ierymenko c7dcbba442 Add an AES benchmark to 1.6 (backport) 2020-09-29 18:34:58 -04:00
Adam Ierymenko 255dee7a5e MacOS build fixes. 2020-09-25 14:32:53 -04:00
Adam Ierymenko c86418934c PATH_MAX is not defined on some Linux systems. 2020-09-23 22:06:22 -04:00
Adam Ierymenko 70efa5f606 Merge branch 'dev' of github.com:zerotier/ZeroTierOne into dev 2020-09-23 21:59:14 -04:00
Adam Ierymenko 69b2fcd5af Get rid of obsolete musl libc fix. 2020-09-23 21:58:51 -04:00
Adam Ierymenko 1f93099e1a Get rid of obsolete musl libc fix. 2020-09-23 21:58:28 -04:00
Joseph Henry b3331c5ec2 Fix buffer overflow in windows tap driver 2020-09-23 15:31:20 -07:00
Grant Limberg ff23d3051f self hosted controller JSON format fix for DNS 2020-09-23 12:16:23 -07:00
Grant Limberg 7d8cfb1fee more magic incantations to make crypto extensions work on Android/ARM64 2020-09-22 10:28:31 -07:00
Grant Limberg 8131680735 AES-NI enabled for Android ARM64 2020-09-22 08:04:16 -07:00
Grant Limberg 9e6dba9066 Enable AES-NI on Android X86-64
Need to find the magic incantation to enable it on ARM64 still
2020-09-21 18:05:25 -07:00
Grant Limberg 0f2887265c AES-NI/NEON detection for iOS
Requires 64-bit CPU
2020-09-21 13:18:05 -07:00
Adam Ierymenko 1ff45020e2 Prefer IPv6 if all else is equal. 2020-09-18 16:27:41 -04:00
Grant Limberg 45c5abe05b add Allow DNS settings to win UI 2020-09-18 10:12:11 -07:00
Grant Limberg e7dafb3ae6 allow DNS field for mac UI 2020-09-18 09:30:43 -07:00
Adam Ierymenko 04f6140da6 AES builds and works now on ARM64. 2020-09-16 22:47:13 +00:00
Grant Limberg afcbc6dd9f clean up some error output 2020-09-16 10:54:14 -07:00
Grant Limberg 4da9bed4fa add 'dump' to cli help 2020-09-16 10:52:23 -07:00
Grant Limberg 221e4ecb12 Add "documentation" networks as IP_SCOPE_PRIVATE
https://en.wikipedia.org/wiki/Reserved_IP_addresses
2020-09-16 10:24:36 -07:00
Grant Limberg 1883a8c9ee Set 198.18.0.0/15 to IP_SCOPE_PRIVATE 2020-09-16 10:15:42 -07:00
Grant Limberg 83d92858c1 Merge branch 'dump' into dev 2020-09-16 10:04:01 -07:00
Grant Limberg cff3152985 windows create dump file on desktop 2020-09-16 10:03:03 -07:00
Grant Limberg 5090e95003 dump basics to stdout on other platforms 2020-09-15 16:50:55 -07:00
Grant Limberg 927aeb15f6 macos output dump to file if possible
if not, write to stdout
2020-09-15 16:50:00 -07:00
Grant Limberg 361ca1e8b4 add link to CoreServices framework 2020-09-15 16:49:19 -07:00
Adam Ierymenko 9adf656db5 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-14 20:44:46 -04:00
Adam Ierymenko 7219ca0c0f AES works! Only with this or newer nodes. Uses salsa with older ones as usual. 2020-09-14 20:44:21 -04:00
Grant Limberg 3a75950ff4 Merge branch 'dump' into dev 2020-09-14 15:25:34 -07:00
Joseph Henry fa86b8bae0 Change ZT_MULTIPATH_FLOW_EXPIRATION_INTERVAL from 30 seconds to 5 minutes 2020-09-14 15:22:06 -07:00
Joseph Henry f3c9ab8a7e Add minor trace output formatting changes. Change ZT_MULTIPATH_BOND_STATUS_INTERVAL from 30000 to 60000 2020-09-14 15:21:53 -07:00
Grant Limberg ace03d7c7b zerotier-cli dump for Windows 2020-09-14 15:17:59 -07:00
Michael Adams 97801b3b56 Update issue templates 2020-09-14 13:10:41 -07:00
Michael Adams 74d9e1e558 Update issue templates 2020-09-14 12:59:36 -07:00
Michael Adams c210e9e5cf Update issue templates
Cleaned this up substantially
2020-09-14 12:58:29 -07:00
Grant Limberg df640dc39b Merge branch 'dev' of github.com:zerotier/ZeroTierOne into dev 2020-09-14 12:45:11 -07:00
Grant Limberg d980bba49f fix windows compilation 2020-09-14 12:42:51 -07:00
Grant Limberg 059dfee0c3 fix windows compilation 2020-09-14 12:42:39 -07:00
Joseph Henry 55f442f1a9 Removed erroneous issue template 2020-09-12 13:09:51 -07:00
joseph-henry 2b9d9168e0 Update issue templates 2020-09-12 13:08:31 -07:00
Joseph Henry 94669a4709 Update Game issue template 2020-09-12 12:58:10 -07:00
joseph-henry be560eb704 Game Connection Issue
Game connection issues can be resolved on our forums: discuss.zerotier.com
2020-09-12 12:23:49 -07:00
Grant Limberg 36d867c3fa more config dump for macOS 2020-09-11 16:43:30 -07:00
Joseph Henry cf47618ffb Change ZT_MULTIPATH_FLOW_EXPIRATION_INTERVAL from 30 seconds to 5 minutes 2020-09-11 16:09:46 -07:00
Grant Limberg 62f23e0cfd step 1 of zerotier-cli dump
dump status, networks, peers, bonds & version
2020-09-11 15:31:56 -07:00
Joseph Henry 0e8b54f7a1 Add minor trace output formatting changes. Change ZT_MULTIPATH_BOND_STATUS_INTERVAL from 30000 to 60000 2020-09-11 14:47:18 -07:00
Adam Ierymenko 1c9407e016 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-11 13:40:04 -04:00
Adam Ierymenko cb8d773634 Disable unicast compression as it almost never helps and usually just wastes CPU. 2020-09-11 13:36:21 -04:00
Grant Limberg bbb307aff7 DNS is now toggleable via zerotier-cli set <nwid> allowDNS=[0|1]
Flag is disabled by default as it should be opt-in on each endpoint
2020-09-10 15:59:18 -07:00
Grant Limberg 3db263284b not sure how this got reverted 2020-09-10 13:18:25 -07:00
Grant Limberg d8f041a484 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-10 12:50:30 -07:00
Adam Ierymenko 120bcbc2c9 Merge branch 'dev' of github.com:zerotier/ZeroTierOne into dev 2020-09-10 15:44:47 -04:00
Grant Limberg 10ccaa2620 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-10 12:43:58 -07:00
Adam Ierymenko e6b5f8aabd AES work... but disabled in this commit. 2020-09-10 15:43:40 -04:00
Michael Adams 4798689bf3 Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2020-09-10 12:43:24 -07:00
Michael Adams 0545e70bd5 Added error messages to use admin/sudo/root 2020-09-10 12:42:11 -07:00
Grant Limberg 5032a8eeac Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-10 11:57:51 -07:00
Adam Ierymenko 1ad555a071 More selective push of AES modifications and refactoring stuff. 2020-09-10 14:48:48 -04:00
Grant Limberg 7d0f6933d6 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-10 11:38:25 -07:00
Adam Ierymenko 4cd3d0bb76 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-09-10 14:37:16 -04:00
Adam Ierymenko 8374553b6a Linux build fix for AES flags. 2020-09-10 14:36:33 -04:00
Grant Limberg eca4052884 Merge branch 'dev-redis' into dev 2020-09-10 11:10:10 -07:00
Michael Adams 2d7a96416c Update issue templates
Include use of Discuss forum as an option for feature requests.
2020-09-08 12:25:40 -07:00
Grant Limberg a1f4397959 linux implementaiton of zerotier-cli dump 2020-08-30 14:19:56 -07:00
Grant Limberg 53d5c9890f missed a rollback
# Conflicts:
#	controller/PostgreSQL.cpp
2020-08-26 15:52:01 -07:00
Grant Limberg 43c108f077 missed a rollback 2020-08-26 15:50:36 -07:00
Grant Limberg 33cc59914a Merge branch 'dev-redis' into dev 2020-08-26 14:52:54 -07:00
Grant Limberg 45b6d11126 Put upserts from controller into single transaction 2020-08-26 14:52:23 -07:00
Adam Ierymenko b7b01da742 Wire up dearmor() path. 2020-08-25 14:13:20 -07:00
Adam Ierymenko 93d6b41898 Disable AES in commit so as not to break other builds. 2020-08-25 08:08:54 -07:00
Adam Ierymenko 47e9fb3ddb Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2020-08-25 08:07:23 -07:00
Joseph Henry b1ddba0438 Remove a few old comments 2020-08-24 18:56:49 -07:00
Grant Limberg e7891bfcb0 Merge branch 'dev-redis' into dev 2020-08-21 16:29:13 -07:00
Grant Limberg 7f99c4a779 Sleep 10 seconds between writes to DB 2020-08-21 16:22:28 -07:00
Adam Ierymenko 2ac49d99dd AES integrated on send side. 2020-08-21 14:23:31 -07:00
Adam Ierymenko 3fd8efe642 AES builds now 2020-08-21 09:56:53 -07:00
Adam Ierymenko 06730c7d1d BSL date bump 2020-08-20 12:51:39 -07:00
Grant Limberg 81c9db7a15 fix libs for non-controller builds on macOS 2020-08-18 11:46:29 -07:00
Grant Limberg 8d0a3563e4 Merge branch 'dns' into dev 2020-08-12 13:56:21 -07:00
Grant Limberg c0c215c83c single dns config per network 2020-08-12 13:08:47 -07:00
Grant Limberg 058d888311 More debug logging cleanup 2020-08-12 10:00:09 -07:00
Grant Limberg 30b18d925f clean up some debug logging 2020-08-12 09:16:18 -07:00
Grant Limberg 137d05e799 add setDNS stubs for linux/bsd 2020-08-12 09:14:10 -07:00
Grant Limberg d9c4e644de Windows DNS 2020-08-11 18:55:42 -07:00
Joseph Henry edd960566a Improve bond tracing, fix bond initialization bugs, remove vestigial debug code 2020-08-06 18:10:40 -07:00
Grant Limberg 6868e98904 Get stuff building on Windows
Been a minute since any of this has been updated
2020-08-05 16:04:02 -07:00
Grant Limberg 85a5b0b948 Remove dns config on shutdown
Also add calls to MacDNSHelper to the kext tap
2020-08-05 14:49:45 -07:00
Grant Limberg b9a1719cb1 Let's make sure to clean up our memory 2020-08-05 14:42:19 -07:00
Grant Limberg d6e3164ea1 remove initial attempt at dns config via scutil 2020-08-05 14:42:09 -07:00
Grant Limberg 302ac8fefe DNS config support on macOS 2020-08-05 14:26:11 -07:00
Grant Limberg d2708daa8e debug output 2020-08-04 14:33:18 -07:00
Grant Limberg 88a3c685fb latest 2020-08-04 13:52:57 -07:00
Grant Limberg 2e52a1eebf forgot a couple queries in postgres. trying to pull dns of member not network in embedded network controller
also some debug logging
2020-08-04 09:45:45 -07:00
Grant Limberg d098a99d09 fix memory init issue
and another place where dns data needs to be copied
2020-07-31 11:42:03 -07:00
Grant Limberg 6b197e067a Merge branch 'dev' into dns 2020-07-30 13:15:43 -07:00
Joseph Henry 9f4985b11a Add basic bond health status reporting (listbonds) 2020-07-27 23:01:12 -07:00
Grant Limberg 5b700fa497 println for which notification stream the controller is listening to 2020-07-27 18:37:45 -07:00
Travis LaDuke c92e030a4b Create a bash completion script.
Just adding it to the repo, but it still needs to be dealt with during install.
Probably put it in $ZT_HOME and then symlink to the proper place for the distro?

searches $ZT_HOME/networks.d/ for network IDs
searches HISTORY for 16 digit numbers that look like network IDs.
2020-07-23 13:40:48 -07:00
Grant Limberg 251b06d812 revert redis for member status 2020-07-23 09:38:50 -07:00
Joseph Henry ff50762649 Merge multipath branch into dev branch 2020-07-23 00:40:17 -07:00
Joseph Henry 29ebda62ef Remove (some) debug functions and traces 2020-07-23 00:32:39 -07:00
Joseph Henry a1b2ff772a Add new replacement condition in peer path redundancy logic to fix duplicate paths 2020-07-23 00:15:38 -07:00
Joseph Henry dc784f6213 Comment out Bond and BondController debug traces 2020-07-21 10:22:10 -07:00
Grant Limberg 387039456d Pass 1 at adding DNS to controller 2020-07-20 14:34:19 -07:00
Suad Halilovic c1f4168d2f 2020/07/16, Minor optmizations 2020-07-16 18:38:04 +02:00
Suad Halilovic ffebcd247f 2020/07/16, Minor optmizations 2020-07-16 18:31:56 +02:00
Joseph Henry fd0c906b1b Merge branch 'multipath' of http://git.int.zerotier.com/ZeroTier/ZeroTierOne into multipath 2020-07-14 17:05:42 -07:00
Joseph Henry decd5add2a Fix segfault on unique interface name list generation (for multipath) 2020-07-14 17:05:05 -07:00
Joseph Henry 8eb453e042 Revert to ancient path redundancy check logic 2020-07-06 15:18:17 -07:00
Grant Limberg bd6c97aeb8 dont strip binary 2020-07-06 14:35:05 -07:00
Joseph Henry 29e7fa5c4b Revert to ancient path redundancy check logic 2020-07-06 14:07:31 -07:00
Joseph Henry a23b6d09c0 Fix merge conflict for controller code (minor edit) 2020-06-29 10:27:22 -07:00
Grant Limberg 1bb1dfa87b android changes 2020-06-18 09:32:00 -07:00
Joseph Henry a33a494d60 Adjust terminology 2020-06-17 14:54:13 -07:00
Joseph Henry 5f0ee4fc78 Fix invalid defaultBondingPolicy conditions, Add ZT_MultipathFlowRebalanceStrategy, Add basic hysteresis mechanism to flow re-assignment 2020-06-16 12:30:21 -07:00
Grant Limberg d0aacfddb7 one more spot 2020-06-04 14:12:20 -07:00
Grant Limberg 9b92ad7772 handle case of no networks and/or no members 2020-06-04 14:06:30 -07:00
Grant Limberg 17c7ae20cc force add libredis++.a for mac 2020-06-04 13:46:16 -07:00
Joseph Henry fa5c8ef434 Fix timers, fix flow count discrepancy after flow removal, fix balance-aware flow re-assignment when one or more links go down 2020-06-01 22:58:58 -07:00
Joseph Henry 1dca7b92cf Remove exit condition for bond creation during re-learning of previously-known paths 2020-05-31 17:30:41 -07:00
Joseph Henry 5e122b95e7 Fix segfault during balance-rr when link is brought down 2020-05-30 21:21:22 -07:00
Grant Limberg 135a547889 No longer update both pgsql & redis 2020-05-28 19:22:07 -07:00
Grant Limberg 06de25a680 bump online notification pause to 100ms
also put all online notification redis commands into a single tx
2020-05-27 22:25:07 -07:00
Grant Limberg 5692402d32 A little more cleanup 2020-05-27 21:02:30 -07:00
Grant Limberg ad7ae5a372 list of all network-node pairs 2020-05-27 20:43:31 -07:00
Grant Limberg 9794e31a64 Temporary online notification thread hack
Updates both Redis and Postgres
2020-05-27 20:43:31 -07:00
Grant Limberg 2f0f0e4f53 redis init optimization 2020-05-27 20:43:31 -07:00
Grant Limberg 7bde004c7c Replace scan of Redis with iteration of _networks map 2020-05-27 20:41:47 -07:00
Joseph Henry a8f830aa9c Add multipath documentation to service/ 2020-05-26 18:29:19 -07:00
Joseph Henry 7266550c22 Remove vestigial constructor, fix typos, clean up code 2020-05-26 17:57:37 -07:00
Joseph Henry 7ed960297b Merge changes from dev into multipath 2020-05-26 17:57:09 -07:00
Grant Limberg 39da360725 add online controller list in Redis 2020-05-22 14:16:04 -07:00
Grant Limberg beedee4401 fix typo 2020-05-22 11:07:12 -07:00
Grant Limberg fb0e8aebdb keep list of active networks in redis 2020-05-22 10:07:39 -07:00
Grant Limberg 13929aee6f reduce log chattiness 2020-05-21 09:49:55 -07:00
Grant Limberg c2409ad6c9 fix connection to redis cluster in online notification thread 2020-05-21 09:49:41 -07:00
Grant Limberg 08cb72bdba Temp object was being destroyed before connection was used 2020-05-21 09:33:03 -07:00
Grant Limberg d24c8d858c include climits for Linux 2020-05-20 16:54:18 -07:00
Grant Limberg 879ef58565 Finalize Redis integration 2020-05-20 16:28:28 -07:00
Grant Limberg 8b8399efbc Error recovery for network & member stream watchers 2020-05-20 11:42:51 -07:00
Grant Limberg 0f17508cac error recovery in redis online notification
If a redis cluster member fails over to the slave, we'll get an error from not specifying the key for the insert.  Recover from that instead of crashing the controller
2020-05-20 11:38:04 -07:00
Grant Limberg 7a138f963c TIL: Creating a redis transaction without sending any commands throws an exception
So let's not do that
2020-05-19 17:47:06 -07:00
Grant Limberg b637ced1ee Track member status in Redis 2020-05-19 17:47:02 -07:00
Grant Limberg ee91c81799 Initialize C arrays to NULL in NetworkConfig() constructor 2020-05-19 17:40:51 -07:00
Grant Limberg 8ac42b4600 controller status query fix 2020-05-19 17:40:11 -07:00
Grant Limberg 844725237d Add new ZT_ result codes that were added 2020-05-18 10:31:17 -07:00
Joseph Henry 58d567c331 Formatting 2020-05-14 20:09:25 -07:00
Joseph Henry 4465952d11 Merge remote-tracking branch 'origin/dev' into multipath 2020-05-14 16:06:55 -07:00
Grant Limberg f8ba1962e6 fix equals() methods 2020-05-14 15:08:37 -07:00
Grant Limberg 701960def5 Track member status in Redis 2020-05-13 17:23:27 -07:00
Grant Limberg 15c0c1db39 finish the RabbitMQ-ectomy 2020-05-13 09:46:41 -07:00
Grant Limberg c9f942f79b can now build centos8 docker container with Redis support 2020-05-12 15:17:57 -07:00
Grant Limberg 663df9118a fix centos8 build 2020-05-12 14:04:03 -07:00
Grant Limberg 5d47697ade helps to add the actual library 2020-05-12 13:04:16 -07:00
Grant Limberg 5babd01d40 centos8 binaries for libhiredis and libredis++ 2020-05-12 12:58:09 -07:00
Grant Limberg aab96964b6 Put debug output behind ZT_TRACE 2020-05-12 12:48:58 -07:00
Grant Limberg c6518afa7a Make sure the streams clean up after themselves 2020-05-12 12:37:05 -07:00
Grant Limberg 563655a1a4 Redis now usable as a message queue 2020-05-12 11:56:19 -07:00
Joseph Henry a50e8e9878 Add Bonds, Slaves, and Flows 2020-05-12 01:35:48 -07:00
Joseph Henry de9cfbe9b0 Merge dev into multipath 2020-05-12 00:08:52 -07:00
Grant Limberg d699116795 mac deps 2020-05-11 16:48:14 -07:00
Grant Limberg 8f3a0b17ad redis++ binaries for mac 2020-05-11 15:24:13 -07:00
Grant Limberg b5c661c5d5 add libhiredis.a for mac 2020-05-11 15:06:10 -07:00
Grant Limberg 154470b570 add original hiredis 2020-05-11 15:03:56 -07:00
Grant Limberg 73b1d57b13 rip out rabbitMQ 2020-05-11 12:29:06 -07:00
Grant Limberg acb4ef0f12 add hiredis-vip to controller build 2020-05-11 11:48:05 -07:00
Gleb Panov d2db307bee Add lines to enable Elbrus (https://en.wikipedia.org/wiki/Elbrus-8S) microprocessor architecture. No changes in code, only in build procedure (recognise relevant ARCH output. 2020-04-29 13:51:28 +03:00
Athanasios Oikonomou 182f16d2a4 Add support for armv7ve
This commit adds support for ARM armv7ve arch.
The extended version of the ARMv7-A architecture with support for virtualization.
2020-04-26 17:01:49 +02:00
Joseph Henry 32a78b5f61 Fix preprocessor typo in previous commit 2020-03-31 20:34:48 -07:00
Joseph Henry 54f9f2ad53 Add special case for Ubiquiti routers in platformDefaultHomePath() 2020-03-31 20:27:41 -07:00
Adam Ierymenko f12c75e68b Merge branch 'master' of github.com:zerotier/ZeroTierOne 2020-03-25 13:40:13 -07:00
Travis LaDuke b6b11dbf82 Document allowSecondaryPort 2020-03-25 10:26:14 -07:00
Grant Limberg 0d42108254 member ip inserts DO NOTHING on conflict 2020-03-04 09:45:45 -08:00
Grant Limberg f6026f94a5 More fun with dupes 2020-03-03 23:52:53 -08:00
Grant Limberg e702942041 Fix duplicate assigned IP check when adding assigned IPs to database 2020-03-03 13:34:24 -08:00
Grant Limberg 00ac35ad62 add --no-cache for docker central controller build 2020-02-24 11:06:08 -08:00
Grant Limberg 12a92fc4a1 Un-log & some production build image fixes 2020-02-24 11:02:05 -08:00
Grant Limberg baa14a63c9 It's LOG! It's LOG!
It's big, it's heavy, it's wood
2020-02-24 10:20:47 -08:00
Grant Limberg cce51cea5d Merge branch 'pipeline' into dev 2020-02-03 13:48:46 -08:00
Grant Limberg ba4324f992 Update jenkinsfile for new build process 2020-02-03 12:51:46 -08:00
Grant Limberg 81e982991b add kali rolling 2020-02-03 10:46:39 -08:00
Grant Limberg f6f4fba90e Add docker configs for multi arch jenkins builds 2020-02-03 09:57:48 -08:00
root 23d5a972ba disable lintian because sid/bullseye are sitting there running /bin/sleep 3 endlessly on this step 2020-01-31 13:15:23 -08:00
root d5467e130e disable lintian because sid/bullseye are sitting there running /bin/sleep 3 endlessly on this step 2020-01-31 13:13:02 -08:00
Grant Limberg 5faf0f8ab6 whoops 2020-01-23 09:46:15 -08:00
Grant Limberg 0f17cd4791 Update to jenkinsfile for multi-platform release builds 2020-01-23 09:41:17 -08:00
Grant Limberg e0518ab176 testing armv5t instead of armv5 flag 2020-01-22 16:36:26 -08:00
Grant Limberg 28df0c2e38 Merge branch 'dev' of github.com:zerotier/ZeroTierOne into dev 2019-12-17 10:56:53 -08:00
Grant Limberg 7696d45093 Fix handling of invalid conf file
Fixes GitHub issue #1068
2019-12-17 10:51:01 -08:00
Grant Limberg 2a7d4fcde5 update vs project settings 2019-12-17 10:49:21 -08:00
Grant Limberg 995fa4a76c Merge branch 'refs/heads/master' into dev 2019-11-22 15:00:39 -08:00
Grant Limberg d8597884f6 jenkins windows 2019-11-22 11:25:31 -08:00
Grant Limberg a993ddc54d Merge branch 'refs/heads/master' into dev 2019-11-21 15:12:37 -08:00
Grant Limberg 54e25084fe re-enable CI on master 2019-11-21 14:51:33 -08:00
Grant Limberg e58a0b3efb build central controller docker images on macOS 2019-11-21 14:49:24 -08:00
Grant Limberg 381f15382c Convert central-controller docker build to use a builder subcontainer 2019-11-20 13:56:26 -08:00
Grant Limberg 91d679af15 Merge pull request #1087 from skunkwerks/dev
drop -Werror from DEBUG builds
2019-11-19 08:47:38 -08:00
Dave Cottlehuber 8396f16dd2 drop -Werror from DEBUG builds
Appease compilers. Thanks @glimberg for the diff.
Closes #1086
2019-11-19 16:45:06 +00:00
Travis LaDuke bb84c9b65c Merge pull request #1082 from laduke/controller-readme
Add Managed Routes example to controller readme.
2019-11-15 10:35:13 -08:00
Travis LaDuke e744c95c5b Add Managed Routes example to controller readme. 2019-11-15 10:29:39 -08:00
Travis LaDuke a725d1a29a Merge pull request #1081 from 0xflotus/patch-1
fixed small error
2019-11-14 10:30:30 -08:00
0xflotus 38feda1594 fixed small error 2019-11-14 10:17:05 +01:00
Grant Limberg dc19deb6c3 . 2019-11-13 12:46:52 -08:00
Grant Limberg 86abd31659 fix log line 2019-11-13 12:46:16 -08:00
Joseph Henry b8e70d866a Compile fix for unterminated conditional directive 2019-11-12 09:46:39 -08:00
Joseph Henry e1e27eb19d Bugfix for incorrect port binding of secondary and tertiary ports 2019-11-11 12:03:49 -08:00
Grant Limberg 088dab4f04 Let's not print this to the logs 2019-10-31 15:13:20 -07:00
Grant Limberg cc79ec6179 use std::string instead of const char* in rmq struct 2019-10-31 15:08:59 -07:00
Grant Limberg 74478b24b0 add librabbitmq binaries for macos for testing central controller 2019-10-31 14:04:25 -07:00
Travis LaDuke bad95d7c67 Update cli help to say <network ID> instead of <network>
Closes #1054
2019-10-15 13:15:45 -07:00
Adam Ierymenko de127056c2 Add notarization to "make official". 2019-09-16 20:13:20 -07:00
Adam Ierymenko 0767ea5d69 * Update default root list to latest
* ARM32 platform build and flag fixes
 * Add a clarification line to LICENSE.txt
 * Fix license message in CLI
 * Windows service now looks for service command line arguments
 * Fixed a bug that could cause excessive queued multicasts
2019-09-05 11:02:16 -07:00
Adam Ierymenko 8454a14eac new Windows GUID for build #2 2019-09-04 14:25:57 -07:00
Adam Ierymenko ecee310087 Update built-in root list. 2019-09-04 14:17:41 -07:00
Adam Ierymenko bcdab95e4c Windows installer version bump, build fix. 2019-09-04 14:13:45 -07:00
Adam Ierymenko a16377cea5 Add mitigations against borked ARM32 exception unrollers, possibly fix GitHub issue #1003 2019-09-04 12:48:28 -07:00
Adam Ierymenko ef69f1bb27 ARM wrestling 2019-09-04 12:37:54 -07:00
Adam Ierymenko 27c8eb0d6d GitHub issue #1019 2019-09-04 12:21:51 -07:00
Adam Ierymenko 3c0f54257b Debian typo fix 2019-09-04 08:19:33 -07:00
Adam Ierymenko e6ead35884 docs 2019-08-30 17:48:22 -07:00
Adam Ierymenko a6dff8ff2f Add an extra catch as workaround for possible cause of ARM crash. 2019-08-30 17:47:13 -07:00
Adam Ierymenko 4281b6b448 Ignore MULTICAST_GATHER replies with the wrong count. 2019-08-30 17:45:10 -07:00
Adam Ierymenko 6897f602bf 1.4.6 version bump 2019-08-30 15:30:37 -07:00
Adam Ierymenko 075321fd0d debian build version bump 2019-08-30 15:16:05 -07:00
Adam Ierymenko 5e8e935189 world! 2019-08-30 11:57:18 -07:00
Adam Ierymenko ebb5f1256f ARM wrestling 2019-08-30 10:03:07 -07:00
Adam Ierymenko 7c6d0d3c0f ARM wrestling 2019-08-30 09:50:37 -07:00
Adam Ierymenko 1b6b38e395 Add default addIps() implementation to EthernetTap base class to fix build on systems that do not need addIps(). 2019-08-28 07:43:18 -07:00
Grant Limberg 1cf953c046 working docker image for end users.
GitHub Issue #1013
2019-08-27 16:57:07 -07:00
Grant Limberg e5bf4565da readme in central controller docker folder 2019-08-27 15:43:11 -07:00
Grant Limberg ddc904a502 remove docker line from readme 2019-08-27 15:27:41 -07:00
Grant Limberg 5cda292d15 comment out docker docker target from makefile because broken 2019-08-27 15:16:05 -07:00
Grant Limberg e51cf0d4d2 moved elsewhere for controller builds 2019-08-27 15:14:55 -07:00
Joseph Henry d8de837c60 LinuxEthernetTap addIps virtual function fix for SYNOLOGY builds 2019-08-27 14:43:30 -07:00
Adam Ierymenko ca89695270 Fix make central-controller-docker 2019-08-26 12:19:50 -07:00
Adam Ierymenko 91b16310ea * Change license from GPL3 to BSL 1.1, see LICENSE.txt
* Fix an issue with the "ipauth" rule and auto-generated unforgeable IPv6 addresses
 * Fix socket/bind errors setting IPs and routes on Linux
2019-08-26 10:33:26 -07:00
Adam Ierymenko 609873e6d1 Windows version bump 2019-08-23 22:10:15 -07:00
Adam Ierymenko 4c616621c2 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2019-08-23 21:38:15 -07:00
Adam Ierymenko 05470bf202 Fix RPM targets 2019-08-23 21:38:04 -07:00
Adam Ierymenko 633cf9ec04 Warning removal 2019-08-23 21:28:26 -07:00
Adam Ierymenko f3c3a90393 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2019-08-23 21:24:34 -07:00
Adam Ierymenko 25a48f2f44 Fix RedHat sub-version. 2019-08-23 21:24:05 -07:00
Adam Ierymenko d214a5437f Bump Mac pkg version 2019-08-23 15:24:52 -07:00
Adam Ierymenko de0a5aa840 GitHub issue #994 2019-08-23 12:09:31 -07:00
Adam Ierymenko 6f9e3e3b78 Back out unnecessary hack 2019-08-23 11:14:17 -07:00
Adam Ierymenko 5c5e7fc7ff Merge branch 'dev' of https://github.com/zerotier/ZeroTierOne into dev 2019-08-23 11:13:13 -07:00
Adam Ierymenko 43e98930e9 distro cleanup 2019-08-23 11:12:25 -07:00
Adam Ierymenko 51ebefc3ab Ifdef these to stop non-Windows IDEs from complaining. 2019-08-23 10:34:37 -07:00
Adam Ierymenko 86add4a6d3 Tolerate any libstdc++6 package "version" for Mint and other distros with weird versions on libstdc++6. 2019-08-23 10:31:12 -07:00
Adam Ierymenko 221a3f9a08 Merge branch 'dev' of http://10.187.0.8/zerotier/ZeroTierOne into dev 2019-08-23 10:20:04 -07:00
Adam Ierymenko 2f74bd5150 Add "make docker" for GitHub issue #1013 2019-08-23 10:19:59 -07:00
Adam Ierymenko e8ae333443 Version bumps, license fixed, and GitHub issue #990 take two 2019-08-23 10:15:13 -07:00
Adam Ierymenko 52a166a71f Relicense: GPLv3 -> ZeroTier BSL 1.1 2019-08-23 09:23:39 -07:00
Adam Ierymenko 509da3ac34 Merge pull request #1012 from wendelb/wendelb-patch-1
Controller-Docs little cleanup
2019-08-21 08:14:38 -07:00
Joseph Henry afca5c2536 Partial implementation of ZT_MULTIPATH_BALANCE_RR_OPAQUE 2019-08-20 23:28:59 -07:00
Joseph Henry 5453cab22b Added flow-awareness check for policies, more work on ZT_MULTIPATH_ACTIVE_BACKUP 2019-08-20 18:50:38 -07:00
Joseph Henry b0a91c0187 Partial implementation of ZT_MULTIPATH_ACTIVE_BACKUP 2019-08-20 16:19:20 -07:00
Joseph Henry 963113b86d Minor adjustment to how _allowTcpFallbackRelay is disabled when _multipathMode is set 2019-08-20 10:38:18 -07:00
Joseph Henry 0634214f2c Added notion of Flows 2019-08-19 21:52:33 -07:00
wendelb fe18579061 Removed duplicate line creationTime 2019-08-17 22:50:13 +02:00
Joseph Henry 15e44f0ddd Merge remote-tracking branch 'origin/dev' into multipath 2019-08-14 11:25:40 -07:00
Joseph Henry b0e86d11c9 Minor. Name change for trace functions 2019-08-14 11:24:03 -07:00
Adam Ierymenko 2ec53df7ab Put a limit on the multicast TX queue to prevent memory use ridiculousness. 2019-08-14 10:52:21 -07:00
Adam Ierymenko 1c7b553331 GitHub issue #1000 2019-08-14 10:47:58 -07:00
Joseph Henry 5b7d60f5cd Whoops 2019-08-13 14:42:48 -07:00
Joseph Henry 640567a021 More informative link aggregation trace outputs 2019-08-13 14:34:47 -07:00
Joseph Henry 2593c6efee Adjusted multipath constants 2019-08-13 14:34:11 -07:00
Joseph Henry 36d368cb78 Check for (local multipath support only) during decision to decrease direct path push interval. This prevents the chicken-and-egg situation of not knowing if two peers can support multipath on both ends and thusly not sending eachother their direct paths quickly enough. 2019-08-13 13:26:41 -07:00
Adam Ierymenko a0fb519696 Make sure libstdc++ is in RH spec file 2019-08-13 12:58:14 -07:00
Joseph Henry 2e9fa7a811 Merge remote-tracking branch 'origin/dev' into multipath 2019-08-13 12:42:19 -07:00
Joseph Henry d8ce1f7914 Added ZT_DIRECT_PATH_PUSH_INTERVAL_MULTIPATH to decrease link aggregation time 2019-08-13 12:41:30 -07:00
Adam Ierymenko 83e6864b78 Version bump in Linux packages for new binaries. 2019-08-13 09:34:56 -07:00
Joseph Henry 3c7e25ed58 Added call to computeAggregateAllocation() in multipath mode=1 to give realtime allocation output 2019-08-12 17:04:27 -07:00
Adam Ierymenko 98af3c0dc1 * Fix high CPU use bug on some platforms
* Fix issues with PostgreSQL controller DB (only affects Central)
 * Restore backward compatibility with MacOS versions prior to 10.13
2019-08-12 13:25:12 -07:00
Joseph Henry 77ae929eb3 Merge master into multipath 2019-08-12 11:40:13 -07:00
Adam Ierymenko 5341c216a7 Comment ugly query 2019-08-08 19:20:01 -05:00
Adam Ierymenko 96a0c3d764 ugly query is ugly 2019-08-08 19:16:11 -05:00
Adam Ierymenko 783b49e383 more worky less not worky 2019-08-08 18:58:22 -05:00
Adam Ierymenko d4dc983a01 fix bad column name 2019-08-08 18:31:41 -05:00
Adam Ierymenko 72ccd1020a Another exception fix 2019-08-08 18:11:06 -05:00
Adam Ierymenko 6a9a577c59 rulesSource needs to be required in network or pgsql has issues 2019-08-08 17:56:27 -05:00
Adam Ierymenko 730305ecc7 One more sync fix. 2019-08-08 17:31:32 -05:00
Adam Ierymenko f8f2432ece Shutdown fix 2019-08-08 17:22:20 -05:00
Adam Ierymenko 55087521f6 Add periodic sync check when syncing LF<>another DB 2019-08-08 17:20:50 -05:00
Adam Ierymenko 760ae07d72 Sync bug fix 2019-08-08 16:30:52 -05:00
Adam Ierymenko 28d0070ce2 Fix race in multiple DB mirroring configurations. 2019-08-08 15:29:13 -05:00
Adam Ierymenko ad2a7c2590 More windows build fixes 2019-08-08 15:15:12 -05:00
Adam Ierymenko 8b97755fc5 Windows fixes. 2019-08-08 14:08:35 -05:00
Adam Ierymenko 7bb0d9be1b warning removal 2019-08-08 11:04:11 -05:00
Adam Ierymenko 6c44fcc290 more warning cleanup 2019-08-08 10:28:57 -05:00
Adam Ierymenko c8e7031198 warning cleanup 2019-08-08 10:01:57 -05:00
Adam Ierymenko fb3b2820b5 centos 7 docs 2019-08-08 09:50:05 -05:00
Adam Ierymenko c83a4aef55 cleanup 2019-08-07 21:47:06 -05:00
Adam Ierymenko af7a70bf02 cleanup 2019-08-07 21:11:48 -05:00
Adam Ierymenko 4d70640a15 Remove debug line 2019-08-07 19:06:02 -05:00
Adam Ierymenko b11627a8bc add SDK VirtualTap to new factory method 2019-08-07 18:45:04 -05:00
Adam Ierymenko 7436f85ad0 Require MacOS 10.10 2019-08-07 18:22:03 -05:00
Adam Ierymenko 237c379866 Choose which tap to use (feth or kext) on Mac based on Darwin version. 2019-08-07 18:20:17 -05:00
Adam Ierymenko aca31c7055 Put kext back in Mac distro and use on versions older than High Sierra (which lack the feth device) 2019-08-07 18:14:12 -05:00
Adam Ierymenko 6073e7972f Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2019-08-07 11:24:04 -05:00
Adam Ierymenko f7e8d8f1dd Fix LFDB path issue when using with Postgress in DBMirrorSet config 2019-08-07 11:23:48 -05:00
Grant Limberg 87016ae815 network update to upsert 2019-08-06 15:30:50 -07:00
Adam Ierymenko 3ed8e46782 Use devtoolset-8 on RHEL/CentOS 7 2019-08-06 16:46:41 -05:00
Adam Ierymenko 3db0197865 Add try/catch in LFDB and add introspection into multicast subscriptions in client network status API 2019-08-06 15:22:57 -05:00
Adam Ierymenko 6174c0c103 Fix deadlock bug. 2019-08-06 13:20:37 -05:00
Adam Ierymenko 8898cb342b . 2019-08-06 13:12:45 -05:00
Adam Ierymenko 9cc76d1115 Remove debug line 2019-08-06 11:01:08 -05:00
Adam Ierymenko 5289d3327c Build fixes 2019-08-06 11:00:35 -05:00
Adam Ierymenko 00fb9c475e More work on DB mirroring. 2019-08-06 10:42:54 -05:00
Adam Ierymenko 3c776675b3 Cruftectomy, work in progress on mirrorring 2019-08-06 08:51:23 -05:00
Adam Ierymenko 37d508ab96 Refactoring in prep for mirroring 2019-08-06 07:51:50 -05:00
Adam Ierymenko f4f8fef82e LFDB fix 2019-08-05 15:30:03 -05:00
Adam Ierymenko cd2e3c79f2 Windows AIP version bump 2019-08-04 20:27:09 -07:00
Adam Ierymenko 7722350178 Version bump to 1.4.2 for all but Windows AIP 2019-08-04 20:13:12 -07:00
Adam Ierymenko a77b4ecddb Add optional function in DB change listener for member online events. 2019-08-04 19:55:52 -07:00
Adam Ierymenko 818b7e4a2e GitHub issue #993 (???) 2019-08-04 15:35:43 -07:00
Adam Ierymenko 00d63f6046 GitHub issue #993 (???) 2019-08-04 15:15:02 -07:00
Adam Ierymenko 639fc60257 GitHub issue #990 2019-08-04 15:08:33 -07:00
Grant Limberg 21467596bc Merge branch 'remove_network_status_table' into dev 2019-08-04 12:38:12 -07:00
Adam Ierymenko 75ebe5172f Fix for sharing of capabilities in 1.4 (problem introduced when push frequency was reduced) 2019-08-02 20:43:02 -07:00
Adam Ierymenko 4a9030b4a0 Merge branch 'dev' of http://git.int.zerotier.com/zerotier/ZeroTierOne into dev 2019-08-02 13:59:10 -07:00
Adam Ierymenko fdc708a624 GitHub issue #979 2019-08-02 13:59:03 -07:00
Adam Ierymenko 67beea1e3d Batch file to clean Windows build dir 2019-08-01 13:21:36 -07:00
Adam Ierymenko 34364ab8ee Bump version 2019-07-31 16:41:35 -07:00
Adam Ierymenko bb99ef1351 Get rid of online status stuff in FileDB, not necessary at all. 2019-07-31 16:41:12 -07:00
Adam Ierymenko b3891e5506 Version 1.4.0.1: bug fix for Mac multicast and IPv4 issues, no change for other platforms 2019-07-31 13:27:08 -07:00
Adam Ierymenko 632d6e04ad Mac multicast bug fix -- GitHub issue #986 2019-07-31 13:25:58 -07:00
Grant Limberg 692733fffb Don't write to ztc_network_status table anymore in central controller 2019-07-15 13:00:16 -07:00
Joseph Henry 258b1c8b55 Merge branch 'edge' into multipath 2018-09-12 13:57:57 -07:00
Joseph Henry 1e66854b59 Temporarily added SO_REUSEADDR to netlink binding code 2018-08-07 12:57:40 -07:00
Joseph Henry 12f2df5586 uncommented status fields 2018-08-07 12:39:06 -07:00
Joseph Henry 20a25a6a45 Added debug traces 2018-08-06 14:31:12 -07:00
Joseph Henry 08d9dc5c68 Updated protocol version and versioning blurb 2018-08-06 10:29:37 -07:00
446 changed files with 82105 additions and 15145 deletions

No files matched your search

+2
View File
@@ -0,0 +1,2 @@
.git/
workspace/
+4
View File
@@ -0,0 +1,4 @@
ext/bin/tap-windows-ndis6/x64/zttap300.inf eol=crlf
ext/bin/tap-windows-ndis6/x64.old/zttap300.inf eol=crlf
ext/bin/tap-windows-ndis6/x86/zttap300.inf eol=crlf
windows/TapDriver6/zttap300.inf eol=crlf
-46
View File
@@ -1,46 +0,0 @@
---
name: Bug report
about: Create a report to help us improve
---
**Alternative, faster ways to get help**
If you have just started using ZeroTier, here are some places to get help:
- my.zerotier.com has a _Community_ tab. It's a live chat with other users and the developers.
- [ZeroTier Knowledge Base](https://zerotier.atlassian.net/wiki/spaces/SD/overview)
- www.zerotier.com has a Contact Us button
- email contact@zerotier.com
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior:
1. Create a Network '...'
2. Install zerotier-one '....'
3. '....'
4. See error
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots or console output to help explain your problem.
**Desktop (please complete the following information):**
- OS: [e.g. Mac, Linux, Windows, BSD]
- OS/Distribution Version
- ZeroTier Version [e.g. 1.2.4]
- Hardware [e.g. raspberry pi 3]
**Smartphone (please complete the following information):**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Version [e.g. 1.2.4]
**Additional context**
Add any other context about the problem here.
- ZeroTier Network Configuration
- Router Config
- Firewall Config (try turning the firewall off)
- General Network Environment: [ e.g Home, University Campus, Corporate LAN ]
+50
View File
@@ -0,0 +1,50 @@
---
name: Bugs and Issues
about: Create a report to help us improve
title: ''
labels: NEEDS TRIAGE
assignees: ''
---
# Before filing a Bug Report
_Using these will ensure you get quicker support, and make this space available for code-related issues. Thank you!_
- [Knowledge Base](https://zerotier.atlassian.net/wiki/spaces/SD/overview) => Guides and documentation on how to use ZeroTier.
- [Discuss Forum](https://discuss.zerotier.com/) => Our discussion forum for users and support to mutally resolve issues & suggest ideas.
- [Reddit](https://www.reddit.com/r/zerotier/) => Our subreddit, which we monitor regularly and is fairly active.
- https://www.zerotier.com/contact/ => Sales and licensing queries
- https://zerotier.atlassian.net/servicedesk/customer/portals => Customer Support Portal
# If you still want to file a Bug Report
## Required
- What you expect to be happening.
- What is actually happening?
- Any steps to reproduce the error.
- Any screenshots that would help us out.
## Additional information
**Desktop (please complete the following information):**
- OS: [e.g. Mac, Linux, Windows, BSD]
- OS/Distribution Version
- ZeroTier Version [e.g. 1.4.6]
**Smartphone (please complete the following information):**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- ZeroTier Version [e.g. 1.4.6]
**Embedded & NAS (please complete the following information):**
- Device: [e.g. Synology, Pi4]
- OS/Distribution (if applicable)
- ZeroTier Version [e.g. 1.4.6]
**Additional context**
- ZeroTier Network Configuration: IPv4 & IPv6 networks defined on your ZeroTier Central
- Router Config: are you permitting port 9993, uPnP, and NAT-PMP?
- Firewall Config: are you permitting port 9993 on your OS; setting it to "Private" on Windows?
- Are you using this at home, in an office, college, etc?
+5 -9
View File
@@ -1,17 +1,13 @@
---
name: Feature request
about: Suggest an idea for this project
title: "[Feature Request] "
labels: suggestion
assignees: ''
---
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
If there is something you'd like to have added to ZeroTier, to go to https://discuss.zerotier.com/c/feature-requests/ instead. Issues there can be voted on and discussed in-depth.
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.
Thank you!
@@ -0,0 +1,15 @@
---
name: Game Connection Issue
about: Game issues are better served by forum posts
title: Please go to our Discuss or Reddit for game-related issues. Thanks!
labels: wontfix
assignees: ''
---
Are you having trouble connecting to a game on your virtual network after installing ZeroTier?
- [ ] Yes
- [ ] No
If you answered yes, then it is very likely that your question would be better answered on our [Discuss ](https://discuss.zerotier.com) forum or [Reddit](https://www.reddit.com/r/zerotier/) community; we monitor both regularly. We also have extensive documentation on our [Knowledge Base](https://zerotier.atlassian.net/wiki/spaces/SD/overview). Thank you!
+3 -1
View File
@@ -33,7 +33,6 @@ Thumbs.db
/ext/installfiles/windows/Prerequisites
/ext/installfiles/windows/*-cache
/ZeroTier One.msi
/windows/.vs
*.vcxproj.backup
/windows/TapDriver6/Win7Debug
/windows/TapDriver6/win7Release
@@ -42,6 +41,7 @@ Thumbs.db
enc_temp_folder
/windows/copyutil/bin
/windows/copyutil/obj
.vs/
# *nix/Mac build droppings
/build-*
@@ -120,3 +120,5 @@ __pycache__
*~
attic/world/*.c25519
attic/world/mkworld
workspace/
workspace2/
+3 -1
View File
@@ -1,3 +1,5 @@
# Authors and Third Party Code Licensing Information
## Primary Authors
* ZeroTier Core and ZeroTier One virtual networking service<br>
@@ -26,7 +28,7 @@
## Third-Party Code
ZeroTier includes the following third party code, either in ext/ or incorporated into the ZeroTier core.
ZeroTier includes the following third party code, either in ext/ or incorporated into the ZeroTier core. This third party code remains licensed under its original license and is not subject to ZeroTier's BSL license.
* LZ4 compression algorithm by Yann Collet
+2 -7
View File
@@ -1,13 +1,8 @@
ZeroTier One, an endpoint server for the ZeroTier virtual network layer.
Copyright © 2011–2019 ZeroTier, Inc.
ZeroTier One is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or (at
your option) any later version.
See the file ‘LICENSE.GPL-3’ for the text of the GNU GPL version 3.
If that file is not present, see <http://www.gnu.org/licenses/>.
ZeroTier is released under the terms of the BSL version 1.1. See the
file LICENSE.txt for details.
..
Local variables:
Vendored
+358 -77
View File
@@ -1,84 +1,365 @@
#!/usr/bin/env groovy
node('master') {
checkout scm
pipeline {
options {
disableConcurrentBuilds()
preserveStashes(buildCount: 10)
timestamps()
}
parameters {
booleanParam(name: "BUILD_ALL", defaultValue: false, description: "Build all supported platform/architecture combos. Defaults to x86/x64 only")
}
def changelog = getChangeLog currentBuild
mattermostSend "Building ${env.JOB_NAME} #${env.BUILD_NUMBER} \n Change Log: \n ${changelog}"
}
parallel 'centos7': {
node('centos7') {
try {
checkout scm
stage('Build Centos 7') {
sh 'make -f make-linux.mk'
agent none
stages {
stage ("Build") {
steps {
script {
def tasks = [:]
tasks << buildStaticBinaries()
tasks << buildDebianNative()
tasks << buildCentosNative()
parallel tasks
}
}
}
catch (err) {
currentBuild.result = "FAILURE"
mattermostSend color: '#ff0000', message: "${env.JOB_NAME} broken on Centos 7 (<${env.BUILD_URL}|Open>)"
throw err
stage ("Package Static") {
steps {
script {
parallel packageStatic()
}
}
}
}
// }, 'android-ndk': {
// node('android-ndk') {
// try {
// checkout scm
// stage('Build Android NDK') {
// sh "/android/android-ndk-r15b/ndk-build -C $WORKSPACE/java ZT1=${WORKSPACE}"
// }
// }
// catch (err) {
// currentBuild.result = "FAILURE"
// mattermostSend color: '#ff0000', message: "${env.JOB_NAME} broken on Android NDK (<${env.BUILD_URL}|Open>)"
// throw err
// }
// }
// }, 'macOS': {
// node('macOS') {
// try {
// checkout scm
// stage('Build macOS') {
// sh 'make -f make-mac.mk'
// }
// stage('Build macOS UI') {
// sh 'cd macui && xcodebuild -target "ZeroTier One" -configuration Debug'
// }
// }
// catch (err) {
// currentBuild.result = "FAILURE"
// mattermostSend color: '#ff0000', message: "${env.JOB_NAME} broken on macOS (<${env.BUILD_URL}|Open>)"
// throw err
// }
// }
// }, 'windows': {
// node('windows') {
// try {
// checkout scm
// stage('Build Windows') {
// bat '''CALL "C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\vcvarsall.bat" amd64
// git clean -dfx
// msbuild windows\\ZeroTierOne.sln
// '''
// }
// }
// catch (err) {
// currentBuild.result = "FAILURE"
// mattermostSend color: '#ff0000', message: "${env.JOB_NAME} broken on Windows (<${env.BUILD_URL}|Open>)"
// throw err
// }
// }
}
mattermostSend color: "#00ff00", message: "${env.JOB_NAME} #${env.BUILD_NUMBER} Complete (<${env.BUILD_URL}|Show More...>)"
def buildStaticBinaries() {
def tasks = [:]
def dist = ["alpine"]
def archs = []
if (params.BUILD_ALL == true) {
archs = ["arm64", "amd64", "i386", "armhf", "armel", "ppc64le", "s390x"]
} else {
archs = ["amd64", "i386"]
}
tasks << getTasks(dist, archs, { distro, platform ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
sh "echo ${distro}-${platform}"
def runtime = docker.image("ztbuild/${distro}-${platform}:latest")
runtime.inside {
dir("build") {
sh 'make -j8 ZT_STATIC=1 all'
sh "file ./zerotier-one"
sh "mv zerotier-one zerotier-one-static-${platform}"
stash includes: 'zerotier-one-static-*', name: "static-${platform}"
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
}
return myNode
})
return tasks
}
def getTasks(axisDistro, axisPlatform, task) {
def tasks = [:]
for(int i=0; i< axisDistro.size(); i++) {
def axisDistroValue = axisDistro[i]
for(int j=0; j< axisPlatform.size(); j++) {
def axisPlatformValue = axisPlatform[j]
tasks["${axisDistroValue}/${axisPlatformValue}"] = task(axisDistroValue, axisPlatformValue)
}
}
return tasks
}
def packageStatic() {
def tasks = [:]
def centos6 = ["centos6"]
def centos6Arch = ["i386", "amd64"]
tasks << getTasks(centos6, centos6Arch, { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
dir("build") {
unstash "static-${arch}"
sh "mv zerotier-one-static-${arch} zerotier-one && chmod +x zerotier-one"
sh "make redhat"
sh "mkdir -p ${distro}"
sh "cp -av `find ~/rpmbuild/ -type f -name \"*.rpm\"` ${distro}/"
archiveArtifacts artifacts: "${distro}/*.rpm", onlyIfSuccessful: true
}
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
return myNode
})
def centos7 = ["centos7"]
def centos7Arch = ["i386"]
tasks << getTasks(centos7, centos7Arch, { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
dir("build") {
unstash "static-${arch}"
sh "mv zerotier-one-static-${arch} zerotier-one && chmod +x zerotier-one"
sh "make redhat"
sh "mkdir -p ${distro}"
sh "cp -av `find ~/rpmbuild/ -type f -name \"*.rpm\"` ${distro}/"
archiveArtifacts artifacts: "${distro}/*.rpm", onlyIfSuccessful: true
}
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
return myNode
})
if (params.BUILD_ALL == true) {
def clefos7 = ["clefos"]
def clefos7Arch = ["s390x"]
tasks << getTasks(clefos7, clefos7Arch, { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
dir("build/") {
unstash "static-${arch}"
sh "mv zerotier-one-static-${arch} zerotier-one && chmod +x zerotier-one"
sh "make redhat"
sh "mkdir -p ${distro}"
sh "cp -av `find ~/rpmbuild/ -type f -name \"*.rpm\"` ${distro}/"
archiveArtifacts artifacts: "${distro}/*.rpm", onlyIfSuccessful: true
}
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
return myNode
})
}
def debianJessie = ["debian-jessie"]
def debianJessieArchs = []
if (params.BUILD_ALL == true) {
debianJessieArch = ["armhf", "armel", "amd64", "i386"]
} else {
debianJessieArch = ["amd64", "i386"]
}
tasks << getTasks(debianJessie, debianJessieArch, { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
sh "ls -la ."
dir('build/') {
sh "ls -la ."
unstash "static-${arch}"
sh "pwd"
sh "mv zerotier-one-static-${arch} zerotier-one && chmod +x zerotier-one && file ./zerotier-one"
sh "mv -f debian/rules.static debian/rules"
sh "make debian"
}
sh "mkdir -p ${distro}"
sh "mv *.deb ${distro}"
archiveArtifacts artifacts: "${distro}/*.deb", onlyIfSuccessful: true
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
return myNode
})
def ubuntuTrusty = ["ubuntu-trusty"]
def ubuntuTrustyArch = []
if (params.BUILD_ALL == true) {
ubuntuTrustyArch = ["i386", "amd64", "armhf", "arm64", "ppc64le"]
} else {
ubuntuTrustyArch = ["i386", "amd64"]
}
tasks << getTasks(ubuntuTrusty, ubuntuTrustyArch, { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
sh "ls -la ."
dir('build/') {
sh "ls -la ."
unstash "static-${arch}"
sh "pwd"
sh "mv zerotier-one-static-${arch} zerotier-one && chmod +x zerotier-one && file ./zerotier-one"
sh "mv -f debian/rules.static debian/rules"
sh "make debian"
}
sh "mkdir -p ${distro}"
sh "mv *.deb ${distro}"
archiveArtifacts artifacts: "${distro}/*.deb", onlyIfSuccessful: true
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
return myNode
})
def debianWheezy = ["debian-wheezy"]
def debianWheezyArchs = []
if (params.BUILD_ALL == true) {
debianWheezyArchs = ["armhf", "armel", "amd64", "i386"]
} else {
debianWheezyArchs = ["amd64", "i386"]
}
tasks << getTasks(debianJessie, debianJessieArch, { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
dir('build/') {
unstash "static-${arch}"
sh "mv zerotier-one-static-${arch} zerotier-one && chmod +x zerotier-one && file ./zerotier-one"
sh "mv -f debian/rules.wheezy.static debian/rules"
sh "mv -f debian/control.wheezy debian/control"
sh "make debian"
}
sh "mkdir -p ${distro}"
sh "mv *.deb ${distro}"
archiveArtifacts artifacts: "${distro}/*.deb", onlyIfSuccessful: true
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
return myNode
})
return tasks
}
def buildDebianNative() {
def tasks = [:]
def buster = ["debian-buster", "debian-stretch", "debian-bullseye", "debian-sid"]
def busterArchs = []
if (params.BUILD_ALL) {
busterArchs = ["s390x", "ppc64le", "i386", "armhf", "armel", "arm64", "amd64"]
} else {
busterArchs = ["amd64", "i386"]
}
def build = { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
dir("build") {
sh 'make debian'
}
sh "mkdir -p ${distro}"
sh "mv *.deb ${distro}"
archiveArtifacts artifacts: "${distro}/*.deb", onlyIfSuccessful: true
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
}
return myNode
}
tasks << getTasks(buster, busterArchs, build)
// bash is broken when running under QEMU-s390x on Xenial
def xenial = ["ubuntu-xenial"]
def xenialArchs = []
if (params.BUILD_ALL == true) {
xenialArchs = ["i386", "amd64", "armhf", "arm64", "ppc64le"]
} else {
xenialArchs = ["i386", "amd64"]
}
tasks << getTasks(xenial, xenialArchs, build)
def ubuntu = ["ubuntu-bionic", "ubuntu-eoan"]
def ubuntuArchs = []
if (params.BUILD_ALL == true) {
ubuntuArchs = ["i386", "amd64", "armhf", "arm64", "ppc64le", "s390x"]
} else {
ubuntuArchs = ["i386", "amd64"]
}
tasks << getTasks(ubuntu, ubuntuArchs, build)
def kali = ["kali-rolling"]
def kaliArchs = ["amd64"]
tasks << getTasks(kali, kaliArchs, build)
return tasks
}
def buildCentosNative() {
def tasks = [:]
def build = { distro, arch ->
def myNode = {
node ('linux-build') {
dir ("build") {
checkout scm
}
def runtime = docker.image("ztbuild/${distro}-${arch}:latest")
runtime.inside {
dir("build") {
sh 'make -j4'
sh 'make redhat'
sh "mkdir -p ${distro}"
sh "cp -av `find ~/rpmbuild/ -type f -name \"*.rpm\"` ${distro}/"
archiveArtifacts artifacts: "${distro}/*.rpm", onlyIfSuccessful: true
}
cleanWs deleteDirs: true, disableDeferredWipeout: true, notFailBuild: true
}
}
}
return myNode
}
def centos8 = ["centos8"]
def centos8Archs = []
if (params.BUILD_ALL == true) {
centos8Archs = ["amd64", "arm64", "ppc64le"]
} else {
centos8Archs = ["amd64"]
}
tasks << getTasks(centos8, centos8Archs, build)
def centos7 = ["centos7"]
def centos7Archs = ["amd64"]
tasks << getTasks(centos7, centos7Archs, build)
return tasks
}
-339
View File
@@ -1,339 +0,0 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License.
-674
View File
File diff suppressed because it is too large. Load diff
+140 -28
View File
@@ -1,37 +1,149 @@
ZeroTier One - Network Virtualization Everywhere
Copyright (C) 2011-2019 ZeroTier, Inc. https://www.zerotier.com/
-----------------------------------------------------------------------------
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Business Source License 1.1
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
License text copyright (c) 2017 MariaDB Corporation Ab, All Rights Reserved.
"Business Source License" is a trademark of MariaDB Corporation Ab.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
-----------------------------------------------------------------------------
See LICENSE.GPL-3 for the full GNU GPL v3 license.
Parameters
--
Licensor: ZeroTier, Inc.
Licensed Work: ZeroTier Network Virtualization Engine 1.4.4
The Licensed Work is (c)2019 ZeroTier, Inc.
Additional Use Grant: You may make use of the Licensed Work, provided you
do not use it in any of the following ways:
You can be released from the requirements of the license by purchasing
a commercial license. Buying such a license is mandatory as soon as you
develop commercial closed-source software that incorporates or links
directly against ZeroTier software without disclosing the source code
of your own application.
* Sell hosted ZeroTier services as a "SaaS" Product
--
(1) Operate or sell access to ZeroTier root servers,
network controllers, or authorization key or certificate
generation components of the Licensed Work as a
for-profit service, regardless of whether the use of
these components is sold alone or is bundled with other
services. Note that this does not apply to the use of
ZeroTier behind the scenes to operate a service not
related to ZeroTier network administration.
The above license does not apply to third party code included with or
linked against by ZeroTier software. See the third party code section
of the AUTHORS.md for an index of third party software included in
this software repository.
* Create Non-Open-Source Commercial Derviative Works
Licenses for third party code are all relatively permissive: MIT,
BSD, and public domain. The only exception is the tap-windows driver
which is under the GPLv2, but this is only needed to produce the
binary tap device driver used by the ZeroTier service on Windows.
(2) Link or directly include the Licensed Work in a
commercial or for-profit application or other product
not distributed under an Open Source Initiative (OSI)
compliant license. See: https://opensource.org/licenses
(3) Remove the name, logo, copyright, or other branding
material from the Licensed Work to create a "rebranded"
or "white labeled" version to distribute as part of
any commercial or for-profit product or service.
* Certain Government Uses
(4) Use or deploy the Licensed Work in a government
setting in support of any active government function
or operation with the exception of the following:
physical or mental health care, family and social
services, social welfare, senior care, child care, and
the care of persons with disabilities.
Change Date: 2025-01-01
Change License: Apache License version 2.0 as published by the Apache
Software Foundation
https://www.apache.org/licenses/
Alternative Licensing
If you would like to use the Licensed Work in any way that conflicts with
the stipulations of the Additional Use Grant, contact ZeroTier, Inc. to
obtain an alternative commercial license.
Visit us on the web at: https://www.zerotier.com/
Notice
The Business Source License (this document, or the "License") is not an Open
Source license. However, the Licensed Work will eventually be made available
under an Open Source License, as stated in this License.
For more information on the use of the Business Source License for ZeroTier
products, please visit our pricing page which contains license details and
and license FAQ: https://zerotier.com/pricing
For more information on the use of the Business Source License generally,
please visit the Adopting and Developing Business Source License FAQ at
https://mariadb.com/bsl-faq-adopting.
-----------------------------------------------------------------------------
Business Source License 1.1
Terms
The Licensor hereby grants you the right to copy, modify, create derivative
works, redistribute, and make non-production use of the Licensed Work. The
Licensor may make an Additional Use Grant, above, permitting limited
production use.
Effective on the Change Date, or the fourth anniversary of the first publicly
available distribution of a specific version of the Licensed Work under this
License, whichever comes first, the Licensor hereby grants you rights under
the terms of the Change License, and the rights granted in the paragraph
above terminate.
If your use of the Licensed Work does not comply with the requirements
currently in effect as described in this License, you must purchase a
commercial license from the Licensor, its affiliated entities, or authorized
resellers, or you must refrain from using the Licensed Work.
All copies of the original and modified Licensed Work, and derivative works
of the Licensed Work, are subject to this License. This License applies
separately for each version of the Licensed Work and the Change Date may vary
for each version of the Licensed Work released by Licensor.
You must conspicuously display this License on each original or modified copy
of the Licensed Work. If you receive the Licensed Work in original or
modified form from a third party, the terms and conditions set forth in this
License apply to your use of that work.
Any use of the Licensed Work in violation of this License will automatically
terminate your rights under this License for the current and all other
versions of the Licensed Work.
This License does not grant you any right in any trademark or logo of
Licensor or its affiliates (provided that you may use a trademark or logo of
Licensor as expressly required by this License).
TO THE EXTENT PERMITTED BY APPLICABLE LAW, THE LICENSED WORK IS PROVIDED ON
AN "AS IS" BASIS. LICENSOR HEREBY DISCLAIMS ALL WARRANTIES AND CONDITIONS,
EXPRESS OR IMPLIED, INCLUDING (WITHOUT LIMITATION) WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, AND
TITLE.
-----------------------------------------------------------------------------
MariaDB hereby grants you permission to use this License’s text to license
your works, and to refer to it using the trademark "Business Source License",
as long as you comply with the Covenants of Licensor below.
Covenants of Licensor
In consideration of the right to use this License’s text and the "Business
Source License" name and trademark, Licensor covenants to MariaDB, and to all
other recipients of the licensed work to be provided by Licensor:
1. To specify as the Change License the GPL Version 2.0 or any later version,
or a license that is compatible with GPL Version 2.0 or a later version,
where "compatible" means that software provided under the Change License can
be included in a program with software provided under GPL Version 2.0 or a
later version. Licensor may specify additional Change Licenses without
limitation.
2. To either: (a) specify an additional grant of rights to use that does not
impose any additional restriction on the right granted in this License, as
the Additional Use Grant; or (b) insert the text "None".
3. To specify a Change Date.
4. Not to modify this License in any other way.
+16 -17
View File
@@ -1,19 +1,27 @@
ZeroTier - Global Area Networking
======
ZeroTier is a smart programmable Ethernet switch for planet Earth. It allows networked devices and applications to be managed as if the entire world is one data center or cloud region.
ZeroTier is a smart programmable Ethernet switch for planet Earth. It allows all networked devices, VMs, containers, and applications to communicate as if they all reside in the same physical data center or cloud region.
It replaces the physical LAN/WAN boundary with a virtual one, allowing devices of any type at any location to be managed as if they all reside in the same cloud region or data center. All traffic is encrypted end-to-end and takes the most direct path available for minimum latency and maximum performance. The goals and design of ZeroTier are inspired by among other things the original [Google BeyondCorp](https://static.googleusercontent.com/media/research.google.com/en//pubs/archive/43231.pdf) paper and the [Jericho Forum](https://en.wikipedia.org/wiki/Jericho_Forum).
This is accomplished by combining a cryptographically addressed and secure peer to peer network (termed VL1) with an Ethernet emulation layer somewhat similar to VXLAN (termed VL2). Our VL2 Ethernet virtualization layer includes advanced enterprise SDN features like fine grained access control rules for network micro-segmentation and security monitoring.
All ZeroTier traffic is encrypted end-to-end using secret keys that only you control. Most traffic flows peer to peer, though we offer free (but slow) relaying for users who cannot establish peer to peer connections.
The goals and design principles of ZeroTier are inspired by among other things the original [Google BeyondCorp](https://static.googleusercontent.com/media/research.google.com/en//pubs/archive/43231.pdf) paper and the [Jericho Forum](https://en.wikipedia.org/wiki/Jericho_Forum) with its notion of "deperimeterization."
Visit [ZeroTier's site](https://www.zerotier.com/) for more information and [pre-built binary packages](https://www.zerotier.com/download/). Apps for Android and iOS are available for free in the Google Play and Apple app stores.
ZeroTier is licensed under the [BSL version 1.1](https://mariadb.com/bsl11/). See [LICENSE.txt](LICENSE.txt) and the [ZeroTier pricing page](https://www.zerotier.com/pricing) for details. ZeroTier is free to use internally in businesses and academic institutions and for non-commercial purposes. Certain types of commercial use such as building closed-source apps and devices based on ZeroTier or offering ZeroTier network controllers and network management as a SaaS service require a commercial license.
A small amount of third party code is also included in ZeroTier and is not subject to our BSL license. See [AUTHORS.md] for a list of third party code, where it is included, and the licenses that apply to it. All of the third party code in ZeroTier is liberally licensed (MIT, BSD, Apache, public domain, etc.).
### Getting Started
Everything in the ZeroTier world is controlled by two types of identifier: 40-bit/10-digit *ZeroTier addresses* and 64-bit/16-digit *network IDs*. A ZeroTier address identifies a node or "device" (laptop, phone, server, VM, app, etc.) while a network ID identifies a virtual Ethernet network that can be joined by devices.
Everything in the ZeroTier world is controlled by two types of identifier: 40-bit/10-digit *ZeroTier addresses* and 64-bit/16-digit *network IDs*. These identifiers are easily distinguished by their length. A ZeroTier address identifies a node or "device" (laptop, phone, server, VM, app, etc.) while a network ID identifies a virtual Ethernet network that can be joined by devices.
Another way of thinking about it is that ZeroTier addresses are port numbers on a giant planetary-sized smart switch while network IDs are VLANs to which these ports can be assigned. For more details read about VL1 and VL2 in [the ZeroTier manual](https://www.zerotier.com/manual/).
ZeroTier addresses can be thought of as port numbers on an enormous planet-wide enterprise Ethernet smart switch supporting VLANs. Network IDs are VLAN IDs to which these ports may be assigned. A single port can be assigned to more than one VLAN.
*Network controllers* are ZeroTier nodes that act as access control certificate authorities and configuration managers for virtual networks. The first 40 bits (or 10 digits) of a network ID is the ZeroTier address of its controller. You can create networks with our [hosted controllers](https://my.zerotier.com/) and web UI/API or [host your own](controller/) if you don't mind posting some JSON configuration info or writing a script to do so.
A ZeroTier address looks like `8056c2e21c` and a network ID looks like `8056c2e21c000001`. Network IDs are composed of the ZeroTier address of that network's primary controller and an arbitrary 24-bit ID that identifies the network on this controller. Network controllers are roughly analogous to SDN controllers in SDN protocols like [OpenFlow](https://en.wikipedia.org/wiki/OpenFlow), though as with the analogy between VXLAN and VL2 this should not be read to imply that the protocols or design are the same. You can use our convenient and inexpensive SaaS hosted controllers at [my.zerotier.com](https://my.zerotier.com/) or [run your own controller](controller/) if you don't mind messing around with JSON configuration files or writing scripts to do so.
### Project Layout
@@ -24,7 +32,6 @@ The base path contains the ZeroTier One service main entry point (`one.cpp`), se
- `controller/`: the reference network controller implementation, which is built and included by default on desktop and server build targets.
- `debian/`: files for building Debian packages on Linux.
- `doc/`: manual pages and other documentation.
- `docker/`: Dockerfile to build as a container for containerized Linux systems and Kubernetes clusters.
- `ext/`: third party libraries, binaries that we ship for convenience on some platforms (Mac and Windows), and installation support files.
- `include/`: include files for the ZeroTier core.
- `java/`: a JNI wrapper used with our Android mobile app. (The whole Android app is not open source but may be made so in the future.)
@@ -33,7 +40,7 @@ The base path contains the ZeroTier One service main entry point (`one.cpp`), se
- `osdep/`: code to support and integrate with OSes, including platform-specific stuff only built for certain targets.
- `rule-compiler/`: JavaScript rules language compiler for defining network-level rules.
- `service/`: the ZeroTier One service, which wraps the ZeroTier core and provides VPN-like connectivity to virtual networks for desktops, laptops, servers, VMs, and containers.
- `windows/`: Visual Studio solution files, Windows service code for ZeroTier One, and the Windows task bar app UI.
- `windows/`: Visual Studio solution files, Windows service code, and the Windows task bar app UI.
### Build and Platform Notes
@@ -80,7 +87,7 @@ Running ZeroTier One on a Mac is the same, but OSX requires a kernel extension.
This will create the home folder for Mac, place *tap.kext* there, and set its modes correctly to enable ZeroTier One to manage it with *kextload* and *kextunload*.
### Troubleshooting
### Basic Troubleshooting
For most users, it just works.
@@ -96,14 +103,6 @@ ZeroTier One peers will automatically locate each other and communicate directly
Users behind certain types of firewalls and "symmetric" NAT devices may not able able to connect to external peers directly at all. ZeroTier has limited support for port prediction and will *attempt* to traverse symmetric NATs, but this doesn't always work. If P2P connectivity fails you'll be bouncing UDP packets off our relay servers resulting in slower performance. Some NAT router(s) have a configurable NAT mode, and setting this to "full cone" will eliminate this problem. If you do this you may also see a magical improvement for things like VoIP phones, Skype, BitTorrent, WebRTC, certain games, etc., since all of these use NAT traversal techniques similar to ours.
If you're interested, there's a [technical deep dive about NAT traversal on our blog](https://www.zerotier.com/blog/?p=226?pk_campaign=github_ZeroTierOne). A troubleshooting tool to help you diagnose NAT issues is planned for the future as are uPnP/IGD/NAT-PMP and IPv6 transport.
If a firewall between you and the Internet blocks ZeroTier's UDP traffic, you will fall back to last-resort TCP tunneling to rootservers over port 443 (https impersonation). This will work almost anywhere but is *very slow* compared to UDP or direct peer to peer connectivity.
### Contributing
Please make pull requests against the `dev` branch. The `master` branch is release, and `edge` is for unstable and work in progress changes and is not likely to work.
### License
The ZeroTier source code is open source and is licensed under the GNU GPL v3 (not LGPL). If you'd like to embed it in a closed-source commercial product or appliance, please e-mail [contact@zerotier.com](mailto:contact@zerotier.com) to discuss commercial licensing. Otherwise it can be used for free.
Additional help [can be found in our knowledge base](https://zerotier.atlassian.net/wiki/spaces/SD/overview).
+72
View File
@@ -1,6 +1,78 @@
ZeroTier Release Notes
======
# 2020-11-24 -- Version 1.6.1
This release fixes some minor bugs and other issues in 1.6.0.
* Fixed a bug that caused IP addresses in the 203.0.0.0/8 block to be miscategorized as not being in global scope.
* Changed Linux builds to (hopefully) fix LXC and SELinux issues.
* Fixed unaligned memory access that caused crash on FreeBSD systems on the ARM architecture.
* Merged CLI options for controlling bonded devices into the beta multipath code.
* Updated Windows driver with Microsoft cross-signing to fix issues on some Windows systems.
# 2020-11-19 -- Version 1.6.0
Version 1.6.0 is a major release that incorporates back-ported features from the 2.0 branch, which is still under development. It also fixes a number of issues.
New features and improvements (including those listed under 1.5.0):
* **Apple Silicon** (MacOS ARM64) native support via universal binary. ZeroTier now requires the very latest Xcode to build.
* **Linux performance improvements** for up to 25% faster tun/tap I/O performance on multi-core systems.
* **Multipath support** with modes modeled after the Linux kernel's bonding driver. This includes active-passive and active-active modes with fast failover and load balancing. See section 2.1.5 of the manual.
* **DNS configuration** push from network controllers to end nodes, with locally configurable permissions for whether or not push is allowed.
* **AES-GMAC-SIV** encryption mode, which is both somewhat more secure and significantly faster than the old Salsa20/12-Poly1305 mode on hardware that supports AES acceleration. This includes virtually all X86-64 chips and most ARM64. This mode is based on AES-SIV and has been audited by Trail of Bits to ensure that it is equivalent security-wise.
Bug fixes:
* **Managed route assignment fixes** to eliminate missing routes on Linux and what we believe to be the source of sporadic high CPU usage on MacOS.
* **Hang on shutdown** issues should be fixed.
* **Sporadic multicast outages** should be fixed.
Known remaining issues:
* AES hardware acceleration is not yet supported on 32-bit ARM, PowerPC (32 or 64), or MIPS (32 or 64) systems. Currently supported are X86-64 and ARM64/AARCH64 with crypto extensions.
# 2020-10-05 -- Version 1.5.0 (actually 1.6.0-beta1)
Version 1.6.0 (1.5.0 is a beta!) is a significant release that incorporates a number of back-ported fixes and features from the ZeroTier 2.0 tree.
Major new features are:
* **Multipath support** with modes modeled after the Linux kernel's bonding driver. This includes active-passive and active-active modes with fast failover and load balancing. See section 2.1.5 of the manual.
* **DNS configuration** push from network controllers to end nodes, with locally configurable permissions for whether or not push is allowed.
* **AES-GMAC-SIV** encryption mode, which is both somewhat more secure and significantly faster than the old Salsa20/12-Poly1305 mode on hardware that supports AES acceleration. This includes virtually all X86-64 chips and most ARM64. This mode is based on AES-SIV and has been audited by Trail of Bits to ensure that it is equivalent security-wise.
Known issues that are not yet fixed in this beta:
* Some Mac users have reported periods of 100% CPU in kernel_task and connection instability after leaving networks that have been joined for a period of time, or needing to kill ZeroTier and restart it to finish leaving a network. This doesn't appear to affect all users and we haven't diagnosed the root cause yet.
* The service sometimes hangs on shutdown requiring a kill -9. This also does not affect all systems or users.
* AES hardware acceleration is not yet supported on 32-bit ARM, PowerPC (32 or 64), or MIPS (32 or 64) systems. Currently supported are X86-64 and ARM64/AARCH64 with crypto extensions.
* Some users have reported multicast/broadcast outages on networks lasting up to 30 seconds. Still investigating.
We're trying to fix all these issues before the 1.6.0 release. Stay tuned.
# 2019-08-30 -- Version 1.4.6
* Update default root list to latest
* ARM32 platform build and flag fixes
* Add a clarification line to LICENSE.txt
* Fix license message in CLI
* Windows service now looks for service command line arguments
* Fixed a bug that could cause excessive queued multicasts
# 2019-08-23 -- Version 1.4.4
* Change license from GPL3 to BSL 1.1, see LICENSE.txt
* Fix an issue with the "ipauth" rule and auto-generated unforgeable IPv6 addresses
* Fix socket/bind errors setting IPs and routes on Linux
# 2019-08-12 -- Version 1.4.2
* Fix high CPU use bug on some platforms
* Fix issues with PostgreSQL controller DB (only affects Central)
* Restore backward compatibility with MacOS versions prior to 10.13
# 2019-07-29 -- Version 1.4.0
### Major Changes
+1 -1
View File
@@ -1,3 +1,3 @@
#!/bin/bash
c++ -std=c++11 -I../.. -I.. -O -o mkworld ../../node/C25519.cpp ../../node/Salsa20.cpp ../../node/SHA512.cpp ../../node/Identity.cpp ../../node/Utils.cpp ../../node/InetAddress.cpp ../../osdep/OSUtils.cpp mkworld.cpp -lm
c++ -std=c++11 -I../.. -I.. -g -o mkworld ../../node/C25519.cpp ../../node/Salsa20.cpp ../../node/SHA512.cpp ../../node/Identity.cpp ../../node/Utils.cpp ../../node/InetAddress.cpp ../../osdep/OSUtils.cpp mkworld.cpp -lm
+48 -29
View File
@@ -81,44 +81,63 @@ int main(int argc,char **argv)
std::vector<World::Root> roots;
const uint64_t id = ZT_WORLD_ID_EARTH;
const uint64_t ts = 1562631342273ULL; // July 8th, 2019
const uint64_t ts = 1567191349589ULL; // August 30th, 2019
// Los Angeles
roots.push_back(World::Root());
roots.back().identity = Identity("3a46f1bf30:0:76e66fab33e28549a62ee2064d1843273c2c300ba45c3f20bef02dbad225723bb59a9bb4b13535730961aeecf5a163ace477cceb0727025b99ac14a5166a09a3");
roots.back().stableEndpoints.push_back(InetAddress("185.180.13.82/9993"));
roots.back().stableEndpoints.push_back(InetAddress("2a02:6ea0:c815::/9993"));
// Alice
// Miami
roots.push_back(World::Root());
roots.back().identity = Identity("9d219039f3:0:01f0922a98e3b34ebcbff333269dc265d7a020aab69d72be4d4acc9c8c9294785771256cd1d942a90d1bd1d2dca3ea84ef7d85afe6611fb43ff0b74126d90a6e");
roots.back().stableEndpoints.push_back(InetAddress("188.166.94.177/9993")); // Amsterdam
roots.back().stableEndpoints.push_back(InetAddress("2a03:b0c0:2:d0::7d:1/9993")); // Amsterdam
roots.back().stableEndpoints.push_back(InetAddress("154.66.197.33/9993")); // Johannesburg
roots.back().stableEndpoints.push_back(InetAddress("2c0f:f850:154:197::33/9993")); // Johannesburg
roots.back().stableEndpoints.push_back(InetAddress("159.203.97.171/9993")); // New York
roots.back().stableEndpoints.push_back(InetAddress("2604:a880:800:a1::54:6001/9993")); // New York
roots.back().stableEndpoints.push_back(InetAddress("131.255.6.16/9993")); // Buenos Aires
roots.back().stableEndpoints.push_back(InetAddress("2803:eb80:0:e::2/9993")); // Buenos Aires
roots.back().stableEndpoints.push_back(InetAddress("107.170.197.14/9993")); // San Francisco
roots.back().stableEndpoints.push_back(InetAddress("2604:a880:1:20::200:e001/9993")); // San Francisco
roots.back().stableEndpoints.push_back(InetAddress("128.199.197.217/9993")); // Singapore
roots.back().stableEndpoints.push_back(InetAddress("2400:6180:0:d0::b7:4001/9993")); // Singapore
roots.back().identity = Identity("de8950a8b2:0:1b3ada8251b91b6b6fa6535b8c7e2460918f4f729abdec97d3c7f3796868fb02f0de0b0ee554b2d59fc3524743eebfcf5315e790ed6d92db5bd10c28c09b40ef");
roots.back().stableEndpoints.push_back(InetAddress("207.246.73.245/443"));
roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:9002:5cb:ec4:7aff:fe8f:69d9/443"));
// Tokyo
roots.push_back(World::Root());
roots.back().identity = Identity("34e0a5e174:0:93efb50934788f856d5cfb9ca5be88e85b40965586b75befac900df77352c145a1ba7007569d37c77bfe52c0999f3bdc67a47a4a6000b720a883ce47aa2fb7f8");
roots.back().stableEndpoints.push_back(InetAddress("147.75.92.2/443"));
roots.back().stableEndpoints.push_back(InetAddress("2604:1380:3000:7100::1/443"));
// Amsterdam
roots.push_back(World::Root());
roots.back().identity = Identity("992fcf1db7:0:206ed59350b31916f749a1f85dffb3a8787dcbf83b8c6e9448d4e3ea0e3369301be716c3609344a9d1533850fb4460c50af43322bcfc8e13d3301a1f1003ceb6");
roots.back().stableEndpoints.push_back(InetAddress("195.181.173.159/443"));
roots.back().stableEndpoints.push_back(InetAddress("2a02:6ea0:c024::/443"));
// Alice
//roots.push_back(World::Root());
//roots.back().identity = Identity("9d219039f3:0:01f0922a98e3b34ebcbff333269dc265d7a020aab69d72be4d4acc9c8c9294785771256cd1d942a90d1bd1d2dca3ea84ef7d85afe6611fb43ff0b74126d90a6e");
//roots.back().stableEndpoints.push_back(InetAddress("188.166.94.177/9993")); // Amsterdam
//roots.back().stableEndpoints.push_back(InetAddress("2a03:b0c0:2:d0::7d:1/9993")); // Amsterdam
//roots.back().stableEndpoints.push_back(InetAddress("154.66.197.33/9993")); // Johannesburg
//roots.back().stableEndpoints.push_back(InetAddress("2c0f:f850:154:197::33/9993")); // Johannesburg
//roots.back().stableEndpoints.push_back(InetAddress("159.203.97.171/9993")); // New York
//roots.back().stableEndpoints.push_back(InetAddress("2604:a880:800:a1::54:6001/9993")); // New York
//roots.back().stableEndpoints.push_back(InetAddress("131.255.6.16/9993")); // Buenos Aires
//roots.back().stableEndpoints.push_back(InetAddress("2803:eb80:0:e::2/9993")); // Buenos Aires
//roots.back().stableEndpoints.push_back(InetAddress("107.170.197.14/9993")); // San Francisco
//roots.back().stableEndpoints.push_back(InetAddress("2604:a880:1:20::200:e001/9993")); // San Francisco
//roots.back().stableEndpoints.push_back(InetAddress("128.199.197.217/9993")); // Singapore
//roots.back().stableEndpoints.push_back(InetAddress("2400:6180:0:d0::b7:4001/9993")); // Singapore
// Bob
roots.push_back(World::Root());
roots.back().identity = Identity("8841408a2e:0:bb1d31f2c323e264e9e64172c1a74f77899555ed10751cd56e86405cde118d02dffe555d462ccf6a85b5631c12350c8d5dc409ba10b9025d0f445cf449d92b1c");
roots.back().stableEndpoints.push_back(InetAddress("45.32.198.130/9993")); // Dallas
roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:6400:81c3:5400:00ff:fe18:1d61/9993")); // Dallas
roots.back().stableEndpoints.push_back(InetAddress("46.101.160.249/9993")); // Frankfurt
roots.back().stableEndpoints.push_back(InetAddress("2a03:b0c0:3:d0::6a:3001/9993")); // Frankfurt
roots.back().stableEndpoints.push_back(InetAddress("107.191.46.210/9993")); // Paris
roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:6800:83a4::64/9993")); // Paris
roots.back().stableEndpoints.push_back(InetAddress("45.32.246.179/9993")); // Sydney
roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:5800:8bf8:5400:ff:fe15:b39a/9993")); // Sydney
roots.back().stableEndpoints.push_back(InetAddress("45.32.248.87/9993")); // Tokyo
roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:7000:9bc9:5400:00ff:fe15:c4f5/9993")); // Tokyo
roots.back().stableEndpoints.push_back(InetAddress("159.203.2.154/9993")); // Toronto
roots.back().stableEndpoints.push_back(InetAddress("2604:a880:cad:d0::26:7001/9993")); // Toronto
//roots.push_back(World::Root());
//roots.back().identity = Identity("8841408a2e:0:bb1d31f2c323e264e9e64172c1a74f77899555ed10751cd56e86405cde118d02dffe555d462ccf6a85b5631c12350c8d5dc409ba10b9025d0f445cf449d92b1c");
//roots.back().stableEndpoints.push_back(InetAddress("45.32.198.130/9993")); // Dallas
//roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:6400:81c3:5400:00ff:fe18:1d61/9993")); // Dallas
//roots.back().stableEndpoints.push_back(InetAddress("46.101.160.249/9993")); // Frankfurt
//roots.back().stableEndpoints.push_back(InetAddress("2a03:b0c0:3:d0::6a:3001/9993")); // Frankfurt
//roots.back().stableEndpoints.push_back(InetAddress("107.191.46.210/9993")); // Paris
//roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:6800:83a4::64/9993")); // Paris
//roots.back().stableEndpoints.push_back(InetAddress("45.32.246.179/9993")); // Sydney
//roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:5800:8bf8:5400:ff:fe15:b39a/9993")); // Sydney
//roots.back().stableEndpoints.push_back(InetAddress("45.32.248.87/9993")); // Tokyo
//roots.back().stableEndpoints.push_back(InetAddress("2001:19f0:7000:9bc9:5400:00ff:fe15:c4f5/9993")); // Tokyo
//roots.back().stableEndpoints.push_back(InetAddress("159.203.2.154/9993")); // Toronto
//roots.back().stableEndpoints.push_back(InetAddress("2604:a880:cad:d0::26:7001/9993")); // Toronto
// END WORLD DEFINITION
// =========================================================================
Binary file not shown.
+21 -59
View File
@@ -1,28 +1,15 @@
/*
* ZeroTier One - Network Virtualization Everywhere
* Copyright (C) 2011-2019 ZeroTier, Inc. https://www.zerotier.com/
* Copyright (c)2019 ZeroTier, Inc.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
* Use of this software is governed by the Business Source License included
* in the LICENSE.TXT file in the project's root directory.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* Change Date: 2025-01-01
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
* --
*
* You can be released from the requirements of the license by purchasing
* a commercial license. Buying such a license is mandatory as soon as you
* develop commercial closed-source software that incorporates or links
* directly against ZeroTier software without disclosing the source code
* of your own application.
* On the date above, in accordance with the Business Source License, use
* of this software will be governed by version 2.0 of the Apache License.
*/
/****/
#include "DB.hpp"
#include "EmbeddedNetworkController.hpp"
@@ -52,6 +39,7 @@ void DB::initNetwork(nlohmann::json &network)
if (!network.count("mtu")) network["mtu"] = ZT_DEFAULT_MTU;
if (!network.count("remoteTraceTarget")) network["remoteTraceTarget"] = nlohmann::json();
if (!network.count("removeTraceLevel")) network["remoteTraceLevel"] = 0;
if (!network.count("rulesSource")) network["rulesSource"] = "";
if (!network.count("rules")) {
// If unspecified, rules are set to allow anything and behave like a flat L2 segment
network["rules"] = {{
@@ -60,6 +48,8 @@ void DB::initNetwork(nlohmann::json &network)
{ "type","ACTION_ACCEPT" }
}};
}
if (!network.count("dns")) network["dns"] = nlohmann::json::array();
network["objtype"] = "network";
}
@@ -104,16 +94,7 @@ void DB::cleanMember(nlohmann::json &member)
member.erase("lastRequestMetaData");
}
DB::DB(const Identity &myId,const char *path) :
_myId(myId),
_myAddress(myId.address()),
_path((path) ? path : "")
{
char tmp[32];
_myAddress.toString(tmp);
_myAddressStr = tmp;
}
DB::DB() {}
DB::~DB() {}
bool DB::get(const uint64_t networkId,nlohmann::json &network)
@@ -199,34 +180,15 @@ bool DB::get(const uint64_t networkId,nlohmann::json &network,std::vector<nlohma
return true;
}
bool DB::summary(const uint64_t networkId,NetworkSummaryInfo &info)
{
waitForReady();
std::shared_ptr<_Network> nw;
{
std::lock_guard<std::mutex> l(_networks_l);
auto nwi = _networks.find(networkId);
if (nwi == _networks.end())
return false;
nw = nwi->second;
}
{
std::lock_guard<std::mutex> l2(nw->lock);
_fillSummaryInfo(nw,info);
}
return true;
}
void DB::networks(std::vector<uint64_t> &networks)
void DB::networks(std::set<uint64_t> &networks)
{
waitForReady();
std::lock_guard<std::mutex> l(_networks_l);
networks.reserve(_networks.size() + 1);
for(auto n=_networks.begin();n!=_networks.end();++n)
networks.push_back(n->first);
networks.insert(n->first);
}
void DB::_memberChanged(nlohmann::json &old,nlohmann::json &memberConfig,bool initialized)
void DB::_memberChanged(nlohmann::json &old,nlohmann::json &memberConfig,bool notifyListeners)
{
uint64_t memberId = 0;
uint64_t networkId = 0;
@@ -310,10 +272,10 @@ void DB::_memberChanged(nlohmann::json &old,nlohmann::json &memberConfig,bool in
}
}
if (initialized) {
if (notifyListeners) {
std::lock_guard<std::mutex> ll(_changeListeners_l);
for(auto i=_changeListeners.begin();i!=_changeListeners.end();++i) {
(*i)->onNetworkMemberUpdate(networkId,memberId,memberConfig);
(*i)->onNetworkMemberUpdate(this,networkId,memberId,memberConfig);
}
}
} else if (memberId) {
@@ -333,15 +295,15 @@ void DB::_memberChanged(nlohmann::json &old,nlohmann::json &memberConfig,bool in
}
}
if ((initialized)&&((wasAuth)&&(!isAuth)&&(networkId)&&(memberId))) {
if ((notifyListeners)&&((wasAuth)&&(!isAuth)&&(networkId)&&(memberId))) {
std::lock_guard<std::mutex> ll(_changeListeners_l);
for(auto i=_changeListeners.begin();i!=_changeListeners.end();++i) {
(*i)->onNetworkMemberDeauthorize(networkId,memberId);
(*i)->onNetworkMemberDeauthorize(this,networkId,memberId);
}
}
}
void DB::_networkChanged(nlohmann::json &old,nlohmann::json &networkConfig,bool initialized)
void DB::_networkChanged(nlohmann::json &old,nlohmann::json &networkConfig,bool notifyListeners)
{
if (networkConfig.is_object()) {
const std::string ids = networkConfig["id"];
@@ -359,10 +321,10 @@ void DB::_networkChanged(nlohmann::json &old,nlohmann::json &networkConfig,bool
std::lock_guard<std::mutex> l2(nw->lock);
nw->config = networkConfig;
}
if (initialized) {
if (notifyListeners) {
std::lock_guard<std::mutex> ll(_changeListeners_l);
for(auto i=_changeListeners.begin();i!=_changeListeners.end();++i) {
(*i)->onNetworkUpdate(networkId,networkConfig);
(*i)->onNetworkUpdate(this,networkId,networkConfig);
}
}
}
+56 -34
View File
@@ -1,32 +1,21 @@
/*
* ZeroTier One - Network Virtualization Everywhere
* Copyright (C) 2011-2019 ZeroTier, Inc. https://www.zerotier.com/
* Copyright (c)2019 ZeroTier, Inc.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
* Use of this software is governed by the Business Source License included
* in the LICENSE.TXT file in the project's root directory.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* Change Date: 2025-01-01
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
* --
*
* You can be released from the requirements of the license by purchasing
* a commercial license. Buying such a license is mandatory as soon as you
* develop commercial closed-source software that incorporates or links
* directly against ZeroTier software without disclosing the source code
* of your own application.
* On the date above, in accordance with the Business Source License, use
* of this software will be governed by version 2.0 of the Apache License.
*/
/****/
#ifndef ZT_CONTROLLER_DB_HPP
#define ZT_CONTROLLER_DB_HPP
//#define ZT_CONTROLLER_USE_LIBPQ
#include "../node/Constants.hpp"
#include "../node/Identity.hpp"
#include "../node/InetAddress.hpp"
@@ -41,6 +30,7 @@
#include <vector>
#include <atomic>
#include <mutex>
#include <set>
#include "../ext/json/json.hpp"
@@ -58,9 +48,9 @@ public:
public:
ChangeListener() {}
virtual ~ChangeListener() {}
virtual void onNetworkUpdate(uint64_t networkId,const nlohmann::json &network) {}
virtual void onNetworkMemberUpdate(uint64_t networkId,uint64_t memberId,const nlohmann::json &member) {}
virtual void onNetworkMemberDeauthorize(uint64_t networkId,uint64_t memberId) {}
virtual void onNetworkUpdate(const void *db,uint64_t networkId,const nlohmann::json &network) {}
virtual void onNetworkMemberUpdate(const void *db,uint64_t networkId,uint64_t memberId,const nlohmann::json &member) {}
virtual void onNetworkMemberDeauthorize(const void *db,uint64_t networkId,uint64_t memberId) {}
};
struct NetworkSummaryInfo
@@ -78,7 +68,7 @@ public:
static void cleanNetwork(nlohmann::json &network);
static void cleanMember(nlohmann::json &member);
DB(const Identity &myId,const char *path);
DB();
virtual ~DB();
virtual bool waitForReady() = 0;
@@ -94,12 +84,27 @@ public:
bool get(const uint64_t networkId,nlohmann::json &network,const uint64_t memberId,nlohmann::json &member);
bool get(const uint64_t networkId,nlohmann::json &network,const uint64_t memberId,nlohmann::json &member,NetworkSummaryInfo &info);
bool get(const uint64_t networkId,nlohmann::json &network,std::vector<nlohmann::json> &members);
bool summary(const uint64_t networkId,NetworkSummaryInfo &info);
void networks(std::vector<uint64_t> &networks);
virtual void save(nlohmann::json *orig,nlohmann::json &record) = 0;
void networks(std::set<uint64_t> &networks);
template<typename F>
inline void each(F f)
{
nlohmann::json nullJson;
std::lock_guard<std::mutex> lck(_networks_l);
for(auto nw=_networks.begin();nw!=_networks.end();++nw) {
f(nw->first,nw->second->config,0,nullJson); // first provide network with 0 for member ID
for(auto m=nw->second->members.begin();m!=nw->second->members.end();++m) {
f(nw->first,nw->second->config,m->first,m->second);
}
}
}
virtual bool save(nlohmann::json &record,bool notifyListeners) = 0;
virtual void eraseNetwork(const uint64_t networkId) = 0;
virtual void eraseMember(const uint64_t networkId,const uint64_t memberId) = 0;
virtual void nodeIsOnline(const uint64_t networkId,const uint64_t memberId,const InetAddress &physicalAddress) = 0;
inline void addListener(DB::ChangeListener *const listener)
@@ -109,6 +114,28 @@ public:
}
protected:
static inline bool _compareRecords(const nlohmann::json &a,const nlohmann::json &b)
{
if (a.is_object() == b.is_object()) {
if (a.is_object()) {
if (a.size() != b.size())
return false;
auto amap = a.get<nlohmann::json::object_t>();
auto bmap = b.get<nlohmann::json::object_t>();
for(auto ai=amap.begin();ai!=amap.end();++ai) {
if (ai->first != "revision") { // ignore revision, compare only non-revision-counter fields
auto bi = bmap.find(ai->first);
if ((bi == bmap.end())||(bi->second != ai->second))
return false;
}
}
return true;
}
return (a == b);
}
return false;
}
struct _Network
{
_Network() : mostRecentDeauthTime(0) {}
@@ -121,15 +148,10 @@ protected:
std::mutex lock;
};
void _memberChanged(nlohmann::json &old,nlohmann::json &memberConfig,bool initialized);
void _networkChanged(nlohmann::json &old,nlohmann::json &networkConfig,bool initialized);
void _memberChanged(nlohmann::json &old,nlohmann::json &memberConfig,bool notifyListeners);
void _networkChanged(nlohmann::json &old,nlohmann::json &networkConfig,bool notifyListeners);
void _fillSummaryInfo(const std::shared_ptr<_Network> &nw,NetworkSummaryInfo &info);
const Identity _myId;
const Address _myAddress;
const std::string _path;
std::string _myAddressStr;
std::vector<DB::ChangeListener *> _changeListeners;
std::unordered_map< uint64_t,std::shared_ptr<_Network> > _networks;
std::unordered_multimap< uint64_t,uint64_t > _networkByMember;
Loaded 20 of 446 files, more files were not shown because too many files have changed in this diff. Show more