From 244286f12795fc8e230860ea7b1cc758463476ed Mon Sep 17 00:00:00 2001 From: dovholuknf <46322585+dovholuknf@users.noreply.github.com> Date: Wed, 13 May 2020 14:36:37 -0400 Subject: [PATCH 1/2] rearrange a bunch of stuff, archive the uwp vpn plugin, start a new readme. remove some older unused projects --- README.md | 31 ++--- ZitiNotificationIcon/App.config | 6 - ZitiNotificationIcon/Form1.Designer.cs | 35 ------ ZitiNotificationIcon/Form1.cs | 17 --- ZitiNotificationIcon/Program.cs | 19 --- .../Properties/AssemblyInfo.cs | 36 ------ .../Properties/Resources.Designer.cs | 62 ---------- .../Properties/Resources.resx | 117 ------------------ .../Properties/Settings.Designer.cs | 26 ---- .../Properties/Settings.settings | 7 -- .../ZitiNotificationIcon.csproj | 80 ------------ ZitiNotifyIcon/Properties/AssemblyInfo.cs | 36 ------ ZitiNotifyIcon/ZitiNotifyIcon.cs | 68 ---------- ZitiNotifyIcon/ZitiNotifyIcon.csproj | 51 -------- {wintun-testing => service}/.gitignore | 0 .../.run/ziti-tunnel-debug.run.xml | 0 {wintun-testing => service}/README.md | 0 {wintun-testing => service}/build.bat | 0 {wintun-testing => service}/build.sh | 0 {wintun-testing => service}/cziti/ctun.go | 0 .../cziti/cziti-cli/main.go | 0 .../cziti/dns-proxy.go | 0 {wintun-testing => service}/cziti/dns.go | 0 {wintun-testing => service}/cziti/sdk.c | 0 {wintun-testing => service}/cziti/sdk.go | 0 {wintun-testing => service}/cziti/sdk.h | 0 .../cziti/windns/windns.go | 0 {wintun-testing => service}/go.mod | 0 {wintun-testing => service}/go.sum | 0 {wintun-testing => service}/reset-nw.bat | 0 .../ziti-tunnel/config/config.go | 0 .../ziti-tunnel/dto/dtos.go | 0 .../ziti-tunnel/globals/loghelper.go | 0 .../ziti-tunnel/idutil/identity.go | 0 .../ziti-tunnel/main.go | 0 .../ziti-tunnel/runtime/package-variables.go | 0 .../ziti-tunnel/runtime/permissions.go | 0 .../ziti-tunnel/runtime/state.go | 0 .../ziti-tunnel/service/install.go | 0 .../ziti-tunnel/service/ipc.go | 0 .../ziti-tunnel/service/manage.go | 0 .../ziti-tunnel/service/pkg-vars.go | 0 .../ziti-tunnel/service/service.go | 0 .../ziti-wintun/main.go | 0 uwp-vpnplugin-archive/README.md | 27 ++++ .../ZitiUWPClient}/ZitiUWPClient.csproj | 0 46 files changed, 38 insertions(+), 580 deletions(-) delete mode 100644 ZitiNotificationIcon/App.config delete mode 100644 ZitiNotificationIcon/Form1.Designer.cs delete mode 100644 ZitiNotificationIcon/Form1.cs delete mode 100644 ZitiNotificationIcon/Program.cs delete mode 100644 ZitiNotificationIcon/Properties/AssemblyInfo.cs delete mode 100644 ZitiNotificationIcon/Properties/Resources.Designer.cs delete mode 100644 ZitiNotificationIcon/Properties/Resources.resx delete mode 100644 ZitiNotificationIcon/Properties/Settings.Designer.cs delete mode 100644 ZitiNotificationIcon/Properties/Settings.settings delete mode 100644 ZitiNotificationIcon/ZitiNotificationIcon.csproj delete mode 100644 ZitiNotifyIcon/Properties/AssemblyInfo.cs delete mode 100644 ZitiNotifyIcon/ZitiNotifyIcon.cs delete mode 100644 ZitiNotifyIcon/ZitiNotifyIcon.csproj rename {wintun-testing => service}/.gitignore (100%) rename {wintun-testing => service}/.run/ziti-tunnel-debug.run.xml (100%) rename {wintun-testing => service}/README.md (100%) rename {wintun-testing => service}/build.bat (100%) rename {wintun-testing => service}/build.sh (100%) rename {wintun-testing => service}/cziti/ctun.go (100%) rename {wintun-testing => service}/cziti/cziti-cli/main.go (100%) rename {wintun-testing => service}/cziti/dns-proxy.go (100%) rename {wintun-testing => service}/cziti/dns.go (100%) rename {wintun-testing => service}/cziti/sdk.c (100%) rename {wintun-testing => service}/cziti/sdk.go (100%) rename {wintun-testing => service}/cziti/sdk.h (100%) rename {wintun-testing => service}/cziti/windns/windns.go (100%) rename {wintun-testing => service}/go.mod (100%) rename {wintun-testing => service}/go.sum (100%) rename {wintun-testing => service}/reset-nw.bat (100%) rename {wintun-testing => service}/ziti-tunnel/config/config.go (100%) rename {wintun-testing => service}/ziti-tunnel/dto/dtos.go (100%) rename {wintun-testing => service}/ziti-tunnel/globals/loghelper.go (100%) rename {wintun-testing => service}/ziti-tunnel/idutil/identity.go (100%) rename {wintun-testing => service}/ziti-tunnel/main.go (100%) rename {wintun-testing => service}/ziti-tunnel/runtime/package-variables.go (100%) rename {wintun-testing => service}/ziti-tunnel/runtime/permissions.go (100%) rename {wintun-testing => service}/ziti-tunnel/runtime/state.go (100%) rename {wintun-testing => service}/ziti-tunnel/service/install.go (100%) rename {wintun-testing => service}/ziti-tunnel/service/ipc.go (100%) rename {wintun-testing => service}/ziti-tunnel/service/manage.go (100%) rename {wintun-testing => service}/ziti-tunnel/service/pkg-vars.go (100%) rename {wintun-testing => service}/ziti-tunnel/service/service.go (100%) rename {wintun-testing => service}/ziti-wintun/main.go (100%) create mode 100644 uwp-vpnplugin-archive/README.md rename {ZitiUWPClient => uwp-vpnplugin-archive/ZitiUWPClient}/ZitiUWPClient.csproj (100%) diff --git a/README.md b/README.md index 47f8edf6..c3517f1b 100644 --- a/README.md +++ b/README.md @@ -1,27 +1,18 @@ -# ziti-client-windows +* Ziti Tunnel for Windows -This is a Windows 10 vpn plugin that "almost" works with windows 10. The VPN API is very fragile -and replacing the wrong element in the wrong place will likely result in errors. +(the uwp project which used to be here has moved to uwp-vpnplugin-archive and is likely abandoned) -Some notes: +The Ziti Tunnel for Windows is an application that is necessary to integrate applications which cannot embed a Ziti SDK +directly into the application. This is colloquially known as a "brown field" Ziti-enabled application because the app +itself has no understanding that it has been Ziti-enabled. -* to connect to a TCP server the traffic seems to be required to leave the actual machine. you - cannot use a locally listening socket for the tcpTransport +In order for an application that has no knowledge of being Ziti-enabled to work the connections established by the app +must be intercepted before leaving the computer and routed through the Ziti network. This is accomplished by three main +components: -* using an empty list as opposed to null in StartWithMainTransport might result in unexpected out of - memory erorrs. - -* git@github.com:YtFlow/YtFlowTunnel.git at least compiles and deploys. never got it working but - might be useful +* [wintun](https://www.wintun.net) - provides a Layer 3 TUN for Windows +* A Windows service which runs as the local system account which creates the TUN as well as manages the Ziti connections +* A Windows UWP UI application that allows the interactively logged on user to interact with the Windows service -Testing: -once deployed (ideally using a remote machine so as to not risk your running windows) you should be able to -get the 'conenct' and 'disconnect' buttons to function. You'll need to update ZitiVPNPlugin.DESIRED_HOST -as that was using a linux vm. - -You can run netcat on that linux vm using: nc -k -l 0.0.0.0 8900 -Then you can see what routes are configured using: netstat -nr -If you run dnsmasq on that same linux VM you can set the vpnContext.DnsServer in MainPage.xaml.cs to the -same machine and influence what DNS results you get back and map those to whatever routes are added via the plugin diff --git a/ZitiNotificationIcon/App.config b/ZitiNotificationIcon/App.config deleted file mode 100644 index 787dcbec..00000000 --- a/ZitiNotificationIcon/App.config +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/ZitiNotificationIcon/Form1.Designer.cs b/ZitiNotificationIcon/Form1.Designer.cs deleted file mode 100644 index 3cd24195..00000000 --- a/ZitiNotificationIcon/Form1.Designer.cs +++ /dev/null @@ -1,35 +0,0 @@ -namespace ZitiNotificationIcon { - partial class Form1 { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) { - if (disposing && (components != null)) { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() { - this.components = new System.ComponentModel.Container(); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(800, 450); - this.Text = "Form1"; - } - - #endregion - } -} - diff --git a/ZitiNotificationIcon/Form1.cs b/ZitiNotificationIcon/Form1.cs deleted file mode 100644 index a63e9dc1..00000000 --- a/ZitiNotificationIcon/Form1.cs +++ /dev/null @@ -1,17 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace ZitiNotificationIcon { - public partial class Form1:Form { - public Form1() { - InitializeComponent(); - } - } -} diff --git a/ZitiNotificationIcon/Program.cs b/ZitiNotificationIcon/Program.cs deleted file mode 100644 index 37ce6223..00000000 --- a/ZitiNotificationIcon/Program.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace ZitiNotificationIcon { - static class Program { - /// - /// The main entry point for the application. - /// - [STAThread] - static void Main() { - Application.EnableVisualStyles(); - Application.SetCompatibleTextRenderingDefault(false); - Application.Run(new Form1()); - } - } -} diff --git a/ZitiNotificationIcon/Properties/AssemblyInfo.cs b/ZitiNotificationIcon/Properties/AssemblyInfo.cs deleted file mode 100644 index b3e7821d..00000000 --- a/ZitiNotificationIcon/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,36 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyTitle("ZitiNotificationIcon")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("ZitiNotificationIcon")] -[assembly: AssemblyCopyright("Copyright © 2020")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from -// COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] - -// The following GUID is for the ID of the typelib if this project is exposed to COM -[assembly: Guid("6b718427-740f-4077-b14d-8e599fcae269")] - -// Version information for an assembly consists of the following four values: -// -// Major Version -// Minor Version -// Build Number -// Revision -// -// You can specify all the values or you can default the Build and Revision Numbers -// by using the '*' as shown below: -// [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/ZitiNotificationIcon/Properties/Resources.Designer.cs b/ZitiNotificationIcon/Properties/Resources.Designer.cs deleted file mode 100644 index 9fab3845..00000000 --- a/ZitiNotificationIcon/Properties/Resources.Designer.cs +++ /dev/null @@ -1,62 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:4.0.30319.42000 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace ZitiNotificationIcon.Properties { - - - /// - /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Resources { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Resources() { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager { - get { - if ((resourceMan == null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ZitiNotificationIcon.Properties.Resources", typeof(Resources).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture { - get { - return resourceCulture; - } - set { - resourceCulture = value; - } - } - } -} diff --git a/ZitiNotificationIcon/Properties/Resources.resx b/ZitiNotificationIcon/Properties/Resources.resx deleted file mode 100644 index af7dbebb..00000000 --- a/ZitiNotificationIcon/Properties/Resources.resx +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/ZitiNotificationIcon/Properties/Settings.Designer.cs b/ZitiNotificationIcon/Properties/Settings.Designer.cs deleted file mode 100644 index 87c12abc..00000000 --- a/ZitiNotificationIcon/Properties/Settings.Designer.cs +++ /dev/null @@ -1,26 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:4.0.30319.42000 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace ZitiNotificationIcon.Properties { - - - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] - internal sealed partial class Settings:global::System.Configuration.ApplicationSettingsBase { - - private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); - - public static Settings Default { - get { - return defaultInstance; - } - } - } -} diff --git a/ZitiNotificationIcon/Properties/Settings.settings b/ZitiNotificationIcon/Properties/Settings.settings deleted file mode 100644 index 39645652..00000000 --- a/ZitiNotificationIcon/Properties/Settings.settings +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/ZitiNotificationIcon/ZitiNotificationIcon.csproj b/ZitiNotificationIcon/ZitiNotificationIcon.csproj deleted file mode 100644 index 88b6f91a..00000000 --- a/ZitiNotificationIcon/ZitiNotificationIcon.csproj +++ /dev/null @@ -1,80 +0,0 @@ - - - - - Debug - AnyCPU - {6B718427-740F-4077-B14D-8E599FCAE269} - WinExe - ZitiNotificationIcon - ZitiNotificationIcon - v4.7.1 - 512 - true - true - - - AnyCPU - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - AnyCPU - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - - - - - - - Form - - - Form1.cs - - - - - ResXFileCodeGenerator - Resources.Designer.cs - Designer - - - True - Resources.resx - - - SettingsSingleFileGenerator - Settings.Designer.cs - - - True - Settings.settings - True - - - - - - - \ No newline at end of file diff --git a/ZitiNotifyIcon/Properties/AssemblyInfo.cs b/ZitiNotifyIcon/Properties/AssemblyInfo.cs deleted file mode 100644 index 5fe4bcf3..00000000 --- a/ZitiNotifyIcon/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,36 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyTitle("ZitiNotifyIcon")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("ZitiNotifyIcon")] -[assembly: AssemblyCopyright("Copyright © 2020")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from -// COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] - -// The following GUID is for the ID of the typelib if this project is exposed to COM -[assembly: Guid("f620947d-5c32-4a6f-beaa-4dcbb2032668")] - -// Version information for an assembly consists of the following four values: -// -// Major Version -// Minor Version -// Build Number -// Revision -// -// You can specify all the values or you can default the Build and Revision Numbers -// by using the '*' as shown below: -// [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/ZitiNotifyIcon/ZitiNotifyIcon.cs b/ZitiNotifyIcon/ZitiNotifyIcon.cs deleted file mode 100644 index addb1bbe..00000000 --- a/ZitiNotifyIcon/ZitiNotifyIcon.cs +++ /dev/null @@ -1,68 +0,0 @@ -using System; -using System.Windows.Forms; - -namespace ZitiNotifyIcon { - public class ZitiNotifyIcon:IDisposable { - - public NotifyIcon targetNotifyIcon; - private System.Drawing.Point notifyIconMousePosition; - private Timer delayMouseLeaveEventTimer; - public delegate void MouseLeaveHandler(); - public event MouseLeaveHandler MouseLeave; - public delegate void MouseMoveHandler(); - public event MouseMoveHandler MouseMove; - - public ZitiNotifyIcon(int millisecondsToDelayMouseLeaveEvent) { - targetNotifyIcon = new NotifyIcon(); - targetNotifyIcon.Visible = true; - targetNotifyIcon.MouseMove += new MouseEventHandler(targetNotifyIcon_MouseMove); - - delayMouseLeaveEventTimer = new Timer(); - delayMouseLeaveEventTimer.Tick += new EventHandler(delayMouseLeaveEventTimer_Tick); - delayMouseLeaveEventTimer.Interval = 1000; - } - - public ZitiNotifyIcon() : this(1000) { } - - public void StartMouseLeaveTimer() { - delayMouseLeaveEventTimer.Start(); - } - - public void StopMouseLeaveEventFromFiring() { - delayMouseLeaveEventTimer.Stop(); - } - - public void targetNotifyIcon_MouseMove(object sender, MouseEventArgs e) { - notifyIconMousePosition = System.Windows.Forms.Control.MousePosition; - MouseMove(); - delayMouseLeaveEventTimer.Start(); - } - - void delayMouseLeaveEventTimer_Tick(object sender, EventArgs e) { - if (notifyIconMousePosition != System.Windows.Forms.Control.MousePosition) { - MouseLeave(); - delayMouseLeaveEventTimer.Stop(); - } - } - - #region IDisposable Members - - private bool _IsDisposed = false; - - ~ZitiNotifyIcon() { - Dispose(false); - } - - public void Dispose() { - Dispose(true); - GC.SuppressFinalize(true); - } - - protected virtual void Dispose(bool IsDisposing) { - if (_IsDisposed) return; - if (IsDisposing) targetNotifyIcon.Dispose(); - _IsDisposed = true; - #endregion - } - } -} diff --git a/ZitiNotifyIcon/ZitiNotifyIcon.csproj b/ZitiNotifyIcon/ZitiNotifyIcon.csproj deleted file mode 100644 index 7676e822..00000000 --- a/ZitiNotifyIcon/ZitiNotifyIcon.csproj +++ /dev/null @@ -1,51 +0,0 @@ - - - - - Debug - AnyCPU - {F620947D-5C32-4A6F-BEAA-4DCBB2032668} - Library - ZitiNotifyIcon - ZitiNotifyIcon - v4.6.1 - 512 - true - - - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/wintun-testing/.gitignore b/service/.gitignore similarity index 100% rename from wintun-testing/.gitignore rename to service/.gitignore diff --git a/wintun-testing/.run/ziti-tunnel-debug.run.xml b/service/.run/ziti-tunnel-debug.run.xml similarity index 100% rename from wintun-testing/.run/ziti-tunnel-debug.run.xml rename to service/.run/ziti-tunnel-debug.run.xml diff --git a/wintun-testing/README.md b/service/README.md similarity index 100% rename from wintun-testing/README.md rename to service/README.md diff --git a/wintun-testing/build.bat b/service/build.bat similarity index 100% rename from wintun-testing/build.bat rename to service/build.bat diff --git a/wintun-testing/build.sh b/service/build.sh similarity index 100% rename from wintun-testing/build.sh rename to service/build.sh diff --git a/wintun-testing/cziti/ctun.go b/service/cziti/ctun.go similarity index 100% rename from wintun-testing/cziti/ctun.go rename to service/cziti/ctun.go diff --git a/wintun-testing/cziti/cziti-cli/main.go b/service/cziti/cziti-cli/main.go similarity index 100% rename from wintun-testing/cziti/cziti-cli/main.go rename to service/cziti/cziti-cli/main.go diff --git a/wintun-testing/cziti/dns-proxy.go b/service/cziti/dns-proxy.go similarity index 100% rename from wintun-testing/cziti/dns-proxy.go rename to service/cziti/dns-proxy.go diff --git a/wintun-testing/cziti/dns.go b/service/cziti/dns.go similarity index 100% rename from wintun-testing/cziti/dns.go rename to service/cziti/dns.go diff --git a/wintun-testing/cziti/sdk.c b/service/cziti/sdk.c similarity index 100% rename from wintun-testing/cziti/sdk.c rename to service/cziti/sdk.c diff --git a/wintun-testing/cziti/sdk.go b/service/cziti/sdk.go similarity index 100% rename from wintun-testing/cziti/sdk.go rename to service/cziti/sdk.go diff --git a/wintun-testing/cziti/sdk.h b/service/cziti/sdk.h similarity index 100% rename from wintun-testing/cziti/sdk.h rename to service/cziti/sdk.h diff --git a/wintun-testing/cziti/windns/windns.go b/service/cziti/windns/windns.go similarity index 100% rename from wintun-testing/cziti/windns/windns.go rename to service/cziti/windns/windns.go diff --git a/wintun-testing/go.mod b/service/go.mod similarity index 100% rename from wintun-testing/go.mod rename to service/go.mod diff --git a/wintun-testing/go.sum b/service/go.sum similarity index 100% rename from wintun-testing/go.sum rename to service/go.sum diff --git a/wintun-testing/reset-nw.bat b/service/reset-nw.bat similarity index 100% rename from wintun-testing/reset-nw.bat rename to service/reset-nw.bat diff --git a/wintun-testing/ziti-tunnel/config/config.go b/service/ziti-tunnel/config/config.go similarity index 100% rename from wintun-testing/ziti-tunnel/config/config.go rename to service/ziti-tunnel/config/config.go diff --git a/wintun-testing/ziti-tunnel/dto/dtos.go b/service/ziti-tunnel/dto/dtos.go similarity index 100% rename from wintun-testing/ziti-tunnel/dto/dtos.go rename to service/ziti-tunnel/dto/dtos.go diff --git a/wintun-testing/ziti-tunnel/globals/loghelper.go b/service/ziti-tunnel/globals/loghelper.go similarity index 100% rename from wintun-testing/ziti-tunnel/globals/loghelper.go rename to service/ziti-tunnel/globals/loghelper.go diff --git a/wintun-testing/ziti-tunnel/idutil/identity.go b/service/ziti-tunnel/idutil/identity.go similarity index 100% rename from wintun-testing/ziti-tunnel/idutil/identity.go rename to service/ziti-tunnel/idutil/identity.go diff --git a/wintun-testing/ziti-tunnel/main.go b/service/ziti-tunnel/main.go similarity index 100% rename from wintun-testing/ziti-tunnel/main.go rename to service/ziti-tunnel/main.go diff --git a/wintun-testing/ziti-tunnel/runtime/package-variables.go b/service/ziti-tunnel/runtime/package-variables.go similarity index 100% rename from wintun-testing/ziti-tunnel/runtime/package-variables.go rename to service/ziti-tunnel/runtime/package-variables.go diff --git a/wintun-testing/ziti-tunnel/runtime/permissions.go b/service/ziti-tunnel/runtime/permissions.go similarity index 100% rename from wintun-testing/ziti-tunnel/runtime/permissions.go rename to service/ziti-tunnel/runtime/permissions.go diff --git a/wintun-testing/ziti-tunnel/runtime/state.go b/service/ziti-tunnel/runtime/state.go similarity index 100% rename from wintun-testing/ziti-tunnel/runtime/state.go rename to service/ziti-tunnel/runtime/state.go diff --git a/wintun-testing/ziti-tunnel/service/install.go b/service/ziti-tunnel/service/install.go similarity index 100% rename from wintun-testing/ziti-tunnel/service/install.go rename to service/ziti-tunnel/service/install.go diff --git a/wintun-testing/ziti-tunnel/service/ipc.go b/service/ziti-tunnel/service/ipc.go similarity index 100% rename from wintun-testing/ziti-tunnel/service/ipc.go rename to service/ziti-tunnel/service/ipc.go diff --git a/wintun-testing/ziti-tunnel/service/manage.go b/service/ziti-tunnel/service/manage.go similarity index 100% rename from wintun-testing/ziti-tunnel/service/manage.go rename to service/ziti-tunnel/service/manage.go diff --git a/wintun-testing/ziti-tunnel/service/pkg-vars.go b/service/ziti-tunnel/service/pkg-vars.go similarity index 100% rename from wintun-testing/ziti-tunnel/service/pkg-vars.go rename to service/ziti-tunnel/service/pkg-vars.go diff --git a/wintun-testing/ziti-tunnel/service/service.go b/service/ziti-tunnel/service/service.go similarity index 100% rename from wintun-testing/ziti-tunnel/service/service.go rename to service/ziti-tunnel/service/service.go diff --git a/wintun-testing/ziti-wintun/main.go b/service/ziti-wintun/main.go similarity index 100% rename from wintun-testing/ziti-wintun/main.go rename to service/ziti-wintun/main.go diff --git a/uwp-vpnplugin-archive/README.md b/uwp-vpnplugin-archive/README.md new file mode 100644 index 00000000..47f8edf6 --- /dev/null +++ b/uwp-vpnplugin-archive/README.md @@ -0,0 +1,27 @@ +# ziti-client-windows + +This is a Windows 10 vpn plugin that "almost" works with windows 10. The VPN API is very fragile +and replacing the wrong element in the wrong place will likely result in errors. + +Some notes: + +* to connect to a TCP server the traffic seems to be required to leave the actual machine. you + cannot use a locally listening socket for the tcpTransport + +* using an empty list as opposed to null in StartWithMainTransport might result in unexpected out of + memory erorrs. + +* git@github.com:YtFlow/YtFlowTunnel.git at least compiles and deploys. never got it working but + might be useful + +Testing: + +once deployed (ideally using a remote machine so as to not risk your running windows) you should be able to +get the 'conenct' and 'disconnect' buttons to function. You'll need to update ZitiVPNPlugin.DESIRED_HOST +as that was using a linux vm. + +You can run netcat on that linux vm using: nc -k -l 0.0.0.0 8900 +Then you can see what routes are configured using: netstat -nr +If you run dnsmasq on that same linux VM you can set the vpnContext.DnsServer in MainPage.xaml.cs to the +same machine and influence what DNS results you get back and map those to whatever routes are added via the plugin + diff --git a/ZitiUWPClient/ZitiUWPClient.csproj b/uwp-vpnplugin-archive/ZitiUWPClient/ZitiUWPClient.csproj similarity index 100% rename from ZitiUWPClient/ZitiUWPClient.csproj rename to uwp-vpnplugin-archive/ZitiUWPClient/ZitiUWPClient.csproj From 2dd54e1d3c4a721a2174a565975ada6b6f651139 Mon Sep 17 00:00:00 2001 From: dovholuknf <46322585+dovholuknf@users.noreply.github.com> Date: Wed, 13 May 2020 14:37:18 -0400 Subject: [PATCH 2/2] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c3517f1b..0adbcf7a 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -* Ziti Tunnel for Windows +# Ziti Tunnel for Windows (the uwp project which used to be here has moved to uwp-vpnplugin-archive and is likely abandoned)