From 1bd3cd422512d7d5fc562950cfaa6dee22a3c0a4 Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Thu, 29 Aug 2013 12:36:24 -0400 Subject: [PATCH] Forgot to add new files in previous commit. --- vsprojects/InstallerUpdater/App.config | 6 + .../InstallerUpdater/InstallerUpdater.csproj | 85 ++++++++++++ .../InstallerUpdater/MainForm.Designer.cs | 39 ++++++ vsprojects/InstallerUpdater/MainForm.cs | 20 +++ vsprojects/InstallerUpdater/Program.cs | 22 +++ .../Properties/AssemblyInfo.cs | 36 +++++ .../Properties/Resources.Designer.cs | 71 ++++++++++ .../Properties/Resources.resx | 117 ++++++++++++++++ .../Properties/Settings.Designer.cs | 30 ++++ .../Properties/Settings.settings | 7 + vsprojects/Service/App.config | 6 + vsprojects/Service/Program.cs | 17 +++ vsprojects/Service/Properties/AssemblyInfo.cs | 36 +++++ vsprojects/Service/Service.csproj | 108 +++++++++++++++ .../Service/ZeroTierOneService.Designer.cs | 71 ++++++++++ vsprojects/Service/ZeroTierOneService.cs | 44 ++++++ vsprojects/Service/ZeroTierOneService.resx | 129 ++++++++++++++++++ 17 files changed, 844 insertions(+) create mode 100644 vsprojects/InstallerUpdater/App.config create mode 100644 vsprojects/InstallerUpdater/InstallerUpdater.csproj create mode 100644 vsprojects/InstallerUpdater/MainForm.Designer.cs create mode 100644 vsprojects/InstallerUpdater/MainForm.cs create mode 100644 vsprojects/InstallerUpdater/Program.cs create mode 100644 vsprojects/InstallerUpdater/Properties/AssemblyInfo.cs create mode 100644 vsprojects/InstallerUpdater/Properties/Resources.Designer.cs create mode 100644 vsprojects/InstallerUpdater/Properties/Resources.resx create mode 100644 vsprojects/InstallerUpdater/Properties/Settings.Designer.cs create mode 100644 vsprojects/InstallerUpdater/Properties/Settings.settings create mode 100644 vsprojects/Service/App.config create mode 100644 vsprojects/Service/Program.cs create mode 100644 vsprojects/Service/Properties/AssemblyInfo.cs create mode 100644 vsprojects/Service/Service.csproj create mode 100644 vsprojects/Service/ZeroTierOneService.Designer.cs create mode 100644 vsprojects/Service/ZeroTierOneService.cs create mode 100644 vsprojects/Service/ZeroTierOneService.resx diff --git a/vsprojects/InstallerUpdater/App.config b/vsprojects/InstallerUpdater/App.config new file mode 100644 index 000000000..8e1564635 --- /dev/null +++ b/vsprojects/InstallerUpdater/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/vsprojects/InstallerUpdater/InstallerUpdater.csproj b/vsprojects/InstallerUpdater/InstallerUpdater.csproj new file mode 100644 index 000000000..6c2631863 --- /dev/null +++ b/vsprojects/InstallerUpdater/InstallerUpdater.csproj @@ -0,0 +1,85 @@ + + + + + Debug + AnyCPU + {B2A5CD75-E0FF-42A3-833A-0C6B0278CFEA} + WinExe + Properties + InstallerUpdater + InstallerUpdater + v4.5 + 512 + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + Form + + + MainForm.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/vsprojects/InstallerUpdater/MainForm.Designer.cs b/vsprojects/InstallerUpdater/MainForm.Designer.cs new file mode 100644 index 000000000..573a083ef --- /dev/null +++ b/vsprojects/InstallerUpdater/MainForm.Designer.cs @@ -0,0 +1,39 @@ +namespace InstallerUpdater +{ + partial class MainForm + { + /// + /// 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.Text = "Form1"; + } + + #endregion + } +} + diff --git a/vsprojects/InstallerUpdater/MainForm.cs b/vsprojects/InstallerUpdater/MainForm.cs new file mode 100644 index 000000000..f671dfb69 --- /dev/null +++ b/vsprojects/InstallerUpdater/MainForm.cs @@ -0,0 +1,20 @@ +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 InstallerUpdater +{ + public partial class MainForm : Form + { + public MainForm() + { + InitializeComponent(); + } + } +} diff --git a/vsprojects/InstallerUpdater/Program.cs b/vsprojects/InstallerUpdater/Program.cs new file mode 100644 index 000000000..d7f1996ea --- /dev/null +++ b/vsprojects/InstallerUpdater/Program.cs @@ -0,0 +1,22 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace InstallerUpdater +{ + static class Program + { + /// + /// The main entry point for the application. + /// + [STAThread] + static void Main() + { + Application.EnableVisualStyles(); + Application.SetCompatibleTextRenderingDefault(false); + Application.Run(new MainForm()); + } + } +} diff --git a/vsprojects/InstallerUpdater/Properties/AssemblyInfo.cs b/vsprojects/InstallerUpdater/Properties/AssemblyInfo.cs new file mode 100644 index 000000000..03edc8bdd --- /dev/null +++ b/vsprojects/InstallerUpdater/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +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("InstallerUpdater")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("InstallerUpdater")] +[assembly: AssemblyCopyright("Copyright © 2013")] +[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("8ae5142c-2de0-430e-aff7-b2487042615d")] + +// 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/vsprojects/InstallerUpdater/Properties/Resources.Designer.cs b/vsprojects/InstallerUpdater/Properties/Resources.Designer.cs new file mode 100644 index 000000000..3fb330e28 --- /dev/null +++ b/vsprojects/InstallerUpdater/Properties/Resources.Designer.cs @@ -0,0 +1,71 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.18052 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace InstallerUpdater.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("InstallerUpdater.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/vsprojects/InstallerUpdater/Properties/Resources.resx b/vsprojects/InstallerUpdater/Properties/Resources.resx new file mode 100644 index 000000000..af7dbebba --- /dev/null +++ b/vsprojects/InstallerUpdater/Properties/Resources.resx @@ -0,0 +1,117 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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/vsprojects/InstallerUpdater/Properties/Settings.Designer.cs b/vsprojects/InstallerUpdater/Properties/Settings.Designer.cs new file mode 100644 index 000000000..8713e48d3 --- /dev/null +++ b/vsprojects/InstallerUpdater/Properties/Settings.Designer.cs @@ -0,0 +1,30 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.18052 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace InstallerUpdater.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/vsprojects/InstallerUpdater/Properties/Settings.settings b/vsprojects/InstallerUpdater/Properties/Settings.settings new file mode 100644 index 000000000..39645652a --- /dev/null +++ b/vsprojects/InstallerUpdater/Properties/Settings.settings @@ -0,0 +1,7 @@ + + + + + + + diff --git a/vsprojects/Service/App.config b/vsprojects/Service/App.config new file mode 100644 index 000000000..8e1564635 --- /dev/null +++ b/vsprojects/Service/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/vsprojects/Service/Program.cs b/vsprojects/Service/Program.cs new file mode 100644 index 000000000..579e5bfec --- /dev/null +++ b/vsprojects/Service/Program.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.ServiceProcess; +using System.Text; +using System.Threading.Tasks; + +namespace Service +{ + static class Program + { + static void Main() + { + ServiceBase.Run(new ZeroTierOneService()); + } + } +} diff --git a/vsprojects/Service/Properties/AssemblyInfo.cs b/vsprojects/Service/Properties/AssemblyInfo.cs new file mode 100644 index 000000000..04bb7710d --- /dev/null +++ b/vsprojects/Service/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +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("Service")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("Service")] +[assembly: AssemblyCopyright("Copyright © 2013")] +[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("8c5f91e6-d727-431c-b99c-8e16dc423889")] + +// 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/vsprojects/Service/Service.csproj b/vsprojects/Service/Service.csproj new file mode 100644 index 000000000..10372114b --- /dev/null +++ b/vsprojects/Service/Service.csproj @@ -0,0 +1,108 @@ + + + + + Debug + AnyCPU + {079E8119-388C-4676-964E-0B8C5324F770} + WinExe + Properties + Service + Service + v4.5 + 512 + publish\ + true + Disk + false + Foreground + 7 + Days + false + false + true + 0 + 1.0.0.%2a + false + false + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + false + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + false + + + Service.Program + + + + + + + + + + + + + + + Component + + + ZeroTierOneService.cs + + + + + + + + + + ZeroTierOneService.cs + + + + + False + Microsoft .NET Framework 4.5 %28x86 and x64%29 + true + + + False + .NET Framework 3.5 SP1 Client Profile + false + + + False + .NET Framework 3.5 SP1 + false + + + + + \ No newline at end of file diff --git a/vsprojects/Service/ZeroTierOneService.Designer.cs b/vsprojects/Service/ZeroTierOneService.Designer.cs new file mode 100644 index 000000000..9b1f6ddf2 --- /dev/null +++ b/vsprojects/Service/ZeroTierOneService.Designer.cs @@ -0,0 +1,71 @@ +namespace Service +{ + partial class ZeroTierOneService + { + /// + /// 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 Component 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.zeroTierProcess = new System.Diagnostics.Process(); + this.checkForUpdatesTimer = new System.Windows.Forms.Timer(this.components); + // + // zeroTierProcess + // + this.zeroTierProcess.EnableRaisingEvents = true; + this.zeroTierProcess.StartInfo.CreateNoWindow = true; + this.zeroTierProcess.StartInfo.Domain = ""; + this.zeroTierProcess.StartInfo.LoadUserProfile = false; + this.zeroTierProcess.StartInfo.Password = null; + this.zeroTierProcess.StartInfo.RedirectStandardError = true; + this.zeroTierProcess.StartInfo.RedirectStandardInput = true; + this.zeroTierProcess.StartInfo.RedirectStandardOutput = true; + this.zeroTierProcess.StartInfo.StandardErrorEncoding = null; + this.zeroTierProcess.StartInfo.StandardOutputEncoding = null; + this.zeroTierProcess.StartInfo.UserName = ""; + this.zeroTierProcess.StartInfo.UseShellExecute = false; + this.zeroTierProcess.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden; + this.zeroTierProcess.OutputDataReceived += new System.Diagnostics.DataReceivedEventHandler(this.zeroTierProcess_OutputDataReceived); + this.zeroTierProcess.ErrorDataReceived += new System.Diagnostics.DataReceivedEventHandler(this.zeroTierProcess_ErrorDataReceived); + this.zeroTierProcess.Exited += new System.EventHandler(this.zeroTierProcess_Exited); + // + // checkForUpdatesTimer + // + this.checkForUpdatesTimer.Enabled = true; + this.checkForUpdatesTimer.Interval = 3600000; + this.checkForUpdatesTimer.Tick += new System.EventHandler(this.checkForUpdatesTimer_Tick); + // + // ZeroTierOneService + // + this.ServiceName = "ZeroTier One"; + + } + + #endregion + + private System.Diagnostics.Process zeroTierProcess; + private System.Windows.Forms.Timer checkForUpdatesTimer; + } +} diff --git a/vsprojects/Service/ZeroTierOneService.cs b/vsprojects/Service/ZeroTierOneService.cs new file mode 100644 index 000000000..f654f1086 --- /dev/null +++ b/vsprojects/Service/ZeroTierOneService.cs @@ -0,0 +1,44 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Diagnostics; +using System.Linq; +using System.ServiceProcess; +using System.Text; +using System.Threading.Tasks; + +namespace Service +{ + public partial class ZeroTierOneService : ServiceBase + { + public ZeroTierOneService() + { + InitializeComponent(); + } + + protected override void OnStart(string[] args) + { + } + + protected override void OnStop() + { + } + + private void zeroTierProcess_Exited(object sender, EventArgs e) + { + } + + private void zeroTierProcess_ErrorDataReceived(object sender, DataReceivedEventArgs e) + { + } + + private void zeroTierProcess_OutputDataReceived(object sender, DataReceivedEventArgs e) + { + } + + private void checkForUpdatesTimer_Tick(object sender, EventArgs e) + { + } + } +} diff --git a/vsprojects/Service/ZeroTierOneService.resx b/vsprojects/Service/ZeroTierOneService.resx new file mode 100644 index 000000000..73b94cb82 --- /dev/null +++ b/vsprojects/Service/ZeroTierOneService.resx @@ -0,0 +1,129 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17, 17 + + + 146, 17 + + + False + + \ No newline at end of file