├── AWS-Connect-Manager
├── AWS.ico
├── Properties
│ ├── Settings.settings
│ ├── Settings.Designer.cs
│ ├── AssemblyInfo.cs
│ ├── Resources.Designer.cs
│ └── Resources.resx
├── App.config
├── Program.cs
├── packages.config
├── AWS-Connect-Manager.csproj
├── Form1.cs
└── Form1.Designer.cs
├── AWS-Connect-Manager.sln
├── .gitattributes
├── README.md
└── .gitignore
/AWS-Connect-Manager/AWS.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/JozefJarosciak/AWS-Connect-Manager/HEAD/AWS-Connect-Manager/AWS.ico
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Properties/Settings.settings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Program.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Threading.Tasks;
5 | using System.Windows.Forms;
6 |
7 | namespace AWS_Connect_Manager
8 | {
9 | static class Program
10 | {
11 | ///
12 | /// The main entry point for the application.
13 | ///
14 | [STAThread]
15 | static void Main()
16 | {
17 | Application.EnableVisualStyles();
18 | Application.SetCompatibleTextRenderingDefault(false);
19 | Application.Run(new Form1());
20 | }
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Properties/Settings.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 |
12 | namespace AWS_Connect_Manager.Properties
13 | {
14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
17 | {
18 |
19 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
20 |
21 | public static Settings Default
22 | {
23 | get
24 | {
25 | return defaultInstance;
26 | }
27 | }
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 16.0.31729.503
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AWS-Connect-Manager", "AWS-Connect-Manager\AWS-Connect-Manager.csproj", "{4733626A-6650-435F-B3C3-632CA184E6D2}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {4733626A-6650-435F-B3C3-632CA184E6D2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {4733626A-6650-435F-B3C3-632CA184E6D2}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {4733626A-6650-435F-B3C3-632CA184E6D2}.Release|Any CPU.ActiveCfg = Release|Any CPU
17 | {4733626A-6650-435F-B3C3-632CA184E6D2}.Release|Any CPU.Build.0 = Release|Any CPU
18 | EndGlobalSection
19 | GlobalSection(SolutionProperties) = preSolution
20 | HideSolutionNode = FALSE
21 | EndGlobalSection
22 | GlobalSection(ExtensibilityGlobals) = postSolution
23 | SolutionGuid = {F19ADDE9-E412-47CC-94F4-6397C3111688}
24 | EndGlobalSection
25 | EndGlobal
26 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("AWS-Connect-Manager")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("")]
12 | [assembly: AssemblyProduct("AWS-Connect-Manager")]
13 | [assembly: AssemblyCopyright("Copyright © 2021")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("4733626a-6650-435f-b3c3-632ca184e6d2")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("1.0.0.0")]
36 | [assembly: AssemblyFileVersion("1.0.0.0")]
37 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | ###############################################################################
2 | # Set default behavior to automatically normalize line endings.
3 | ###############################################################################
4 | * text=auto
5 |
6 | ###############################################################################
7 | # Set default behavior for command prompt diff.
8 | #
9 | # This is need for earlier builds of msysgit that does not have it on by
10 | # default for csharp files.
11 | # Note: This is only used by command line
12 | ###############################################################################
13 | #*.cs diff=csharp
14 |
15 | ###############################################################################
16 | # Set the merge driver for project and solution files
17 | #
18 | # Merging from the command prompt will add diff markers to the files if there
19 | # are conflicts (Merging from VS is not affected by the settings below, in VS
20 | # the diff markers are never inserted). Diff markers may cause the following
21 | # file extensions to fail to load in VS. An alternative would be to treat
22 | # these files as binary and thus will always conflict and require user
23 | # intervention with every merge. To do so, just uncomment the entries below
24 | ###############################################################################
25 | #*.sln merge=binary
26 | #*.csproj merge=binary
27 | #*.vbproj merge=binary
28 | #*.vcxproj merge=binary
29 | #*.vcproj merge=binary
30 | #*.dbproj merge=binary
31 | #*.fsproj merge=binary
32 | #*.lsproj merge=binary
33 | #*.wixproj merge=binary
34 | #*.modelproj merge=binary
35 | #*.sqlproj merge=binary
36 | #*.wwaproj merge=binary
37 |
38 | ###############################################################################
39 | # behavior for image files
40 | #
41 | # image files are treated as binary by default.
42 | ###############################################################################
43 | #*.jpg binary
44 | #*.png binary
45 | #*.gif binary
46 |
47 | ###############################################################################
48 | # diff behavior for common document formats
49 | #
50 | # Convert binary document formats to text before diffing them. This feature
51 | # is only available from the command line. Turn it on by uncommenting the
52 | # entries below.
53 | ###############################################################################
54 | #*.doc diff=astextplain
55 | #*.DOC diff=astextplain
56 | #*.docx diff=astextplain
57 | #*.DOCX diff=astextplain
58 | #*.dot diff=astextplain
59 | #*.DOT diff=astextplain
60 | #*.pdf diff=astextplain
61 | #*.PDF diff=astextplain
62 | #*.rtf diff=astextplain
63 | #*.RTF diff=astextplain
64 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Properties/Resources.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 |
12 | namespace AWS_Connect_Manager.Properties
13 | {
14 | ///
15 | /// A strongly-typed resource class, for looking up localized strings, etc.
16 | ///
17 | // This class was auto-generated by the StronglyTypedResourceBuilder
18 | // class via a tool like ResGen or Visual Studio.
19 | // To add or remove a member, edit your .ResX file then rerun ResGen
20 | // with the /str option, or rebuild your VS project.
21 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
22 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
23 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
24 | internal class Resources
25 | {
26 |
27 | private static global::System.Resources.ResourceManager resourceMan;
28 |
29 | private static global::System.Globalization.CultureInfo resourceCulture;
30 |
31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
32 | internal Resources()
33 | {
34 | }
35 |
36 | ///
37 | /// Returns the cached ResourceManager instance used by this class.
38 | ///
39 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
40 | internal static global::System.Resources.ResourceManager ResourceManager
41 | {
42 | get
43 | {
44 | if ((resourceMan == null))
45 | {
46 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("AWS_Connect_Manager.Properties.Resources", typeof(Resources).Assembly);
47 | resourceMan = temp;
48 | }
49 | return resourceMan;
50 | }
51 | }
52 |
53 | ///
54 | /// Overrides the current thread's CurrentUICulture property for all
55 | /// resource lookups using this strongly typed resource class.
56 | ///
57 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
58 | internal static global::System.Globalization.CultureInfo Culture
59 | {
60 | get
61 | {
62 | return resourceCulture;
63 | }
64 | set
65 | {
66 | resourceCulture = value;
67 | }
68 | }
69 | }
70 | }
71 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # AWS Connect Manager
2 | - Open-source Windows tool to simplify connecting to Amazon AWS EC2 instances.
3 | - Ever wanted to connect to your Windows or Linux instances with a single click? Give it a try!
4 |
5 | ## Functionality
6 | - Automatically reads your AWS 'credentials' file
7 | - Single click connection to SSM, WinSCP and RDP
8 | - Combobox to switch between AWS Profiles
9 | - Combobox to switch betwen AWS Regions
10 | - Auto lists all instances, providing details such as Instance Tag, Instance ID, Private IP Address, Instance Type, Platform and Availability Zone
11 | - Easily copy to clipboard: Instance ID, IP Address or CLI SSM Command
12 |
13 | ## Screenshots
14 | - Single-click SSM, WinSCP & RDP:
15 | 
16 | - Configuration Screen
17 | 
18 |
19 | ## Prerequisites
20 | - .NET Framework 4.7.2 installed on Windows
21 | - AWS CLI - https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-install.html
22 | - AWS Credential File (.aws/credentials) - https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html
23 | - Session Manager plugin for the AWS CLI - https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-install-plugin.html
24 | - WinSCP - https://winscp.net/eng/download.php
25 | - ConEmu (auto packaged in the Windows download), if you want to use your own version, download here: https://conemu.github.io/
26 |
27 | # WinSCP Prerequisite:
28 | Integration with WinSCP needs some work, it currently requires a manual setup of the new WinSCP connection in WinSCP, which must be configured as follows:
29 | - Connection Name: AWS
30 | - File Protocol: SCP
31 | - Host Name: localhost
32 | - Port: 54321
33 | - User Name: root
34 | Note: If you want SCP auto-login, you need to configure advanced settings and under SSH / Authentication, configure the path to your private key PPK file (also needs to be configured on the server.
35 |
36 | # RDP Auto-Login
37 | - If you want RDP to auto-login to your Windows servers, enter shared RDP credentials into configuration screen. I currently advise against this practice, but if you want to go ahead, be AWARE, that currently credentials are saved into the application config file in a raw unencrypted format.
38 |
39 | # Application Download
40 | - You can download the initial release of AWS Connect Manager for Windows (v1.0.0) in zip format from GitHub release page:
41 | - https://github.com/JozefJarosciak/AWS-Connect-Manager/releases/download/v1.0.0/AWS_Connect_Manager-1.0.0.zip
42 |
43 | # Application Installation
44 | - Download AWS_Connect_Manager-1.0.0.zip
45 | - Unzip
46 | - Run: AWS-Connect-Manager.exe
47 |
48 | # Source Code & Licensing
49 | - This project is open-source released under GNU GENERAL PUBLIC LICENSE - Version 2, June 1991.
50 | - Feel free to fork and further enhance this project.
51 | - Application is coded entirely in C# using Visual Studio.
52 | - No third-party dependencies except ConEmu (open-source tabbed terminal emulator for Windows).
53 |
54 | # Support
55 | - Having trouble? Contact me, I'll try to help as much as I can.
56 | - Or contact me in this dedicated reddit post: https://www.reddit.com/r/aws/comments/qp5h6y/opensource_aws_connect_manager_for_windows_ssm/
57 |
58 | # Author / Contact
59 | - Jozef Jarosciak
60 | - LinkedIn Contact: https://www.linkedin.com/in/jozefj
61 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Properties/Resources.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 | text/microsoft-resx
107 |
108 |
109 | 2.0
110 |
111 |
112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
113 |
114 |
115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | ## Ignore Visual Studio temporary files, build results, and
2 | ## files generated by popular Visual Studio add-ons.
3 | ##
4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
5 |
6 | # User-specific files
7 | *.rsuser
8 | *.suo
9 | *.user
10 | *.userosscache
11 | *.sln.docstates
12 |
13 | # User-specific files (MonoDevelop/Xamarin Studio)
14 | *.userprefs
15 |
16 | # Mono auto generated files
17 | mono_crash.*
18 |
19 | # Build results
20 | [Dd]ebug/
21 | [Dd]ebugPublic/
22 | [Rr]elease/
23 | [Rr]eleases/
24 | x64/
25 | x86/
26 | [Ww][Ii][Nn]32/
27 | [Aa][Rr][Mm]/
28 | [Aa][Rr][Mm]64/
29 | bld/
30 | [Bb]in/
31 | [Oo]bj/
32 | [Oo]ut/
33 | [Ll]og/
34 | [Ll]ogs/
35 |
36 | # Visual Studio 2015/2017 cache/options directory
37 | .vs/
38 | # Uncomment if you have tasks that create the project's static files in wwwroot
39 | #wwwroot/
40 |
41 | # Visual Studio 2017 auto generated files
42 | Generated\ Files/
43 |
44 | # MSTest test Results
45 | [Tt]est[Rr]esult*/
46 | [Bb]uild[Ll]og.*
47 |
48 | # NUnit
49 | *.VisualState.xml
50 | TestResult.xml
51 | nunit-*.xml
52 |
53 | # Build Results of an ATL Project
54 | [Dd]ebugPS/
55 | [Rr]eleasePS/
56 | dlldata.c
57 |
58 | # Benchmark Results
59 | BenchmarkDotNet.Artifacts/
60 |
61 | # .NET Core
62 | project.lock.json
63 | project.fragment.lock.json
64 | artifacts/
65 |
66 | # ASP.NET Scaffolding
67 | ScaffoldingReadMe.txt
68 |
69 | # StyleCop
70 | StyleCopReport.xml
71 |
72 | # Files built by Visual Studio
73 | *_i.c
74 | *_p.c
75 | *_h.h
76 | *.ilk
77 | *.meta
78 | *.obj
79 | *.iobj
80 | *.pch
81 | *.pdb
82 | *.ipdb
83 | *.pgc
84 | *.pgd
85 | *.rsp
86 | *.sbr
87 | *.tlb
88 | *.tli
89 | *.tlh
90 | *.tmp
91 | *.tmp_proj
92 | *_wpftmp.csproj
93 | *.log
94 | *.vspscc
95 | *.vssscc
96 | .builds
97 | *.pidb
98 | *.svclog
99 | *.scc
100 |
101 | # Chutzpah Test files
102 | _Chutzpah*
103 |
104 | # Visual C++ cache files
105 | ipch/
106 | *.aps
107 | *.ncb
108 | *.opendb
109 | *.opensdf
110 | *.sdf
111 | *.cachefile
112 | *.VC.db
113 | *.VC.VC.opendb
114 |
115 | # Visual Studio profiler
116 | *.psess
117 | *.vsp
118 | *.vspx
119 | *.sap
120 |
121 | # Visual Studio Trace Files
122 | *.e2e
123 |
124 | # TFS 2012 Local Workspace
125 | $tf/
126 |
127 | # Guidance Automation Toolkit
128 | *.gpState
129 |
130 | # ReSharper is a .NET coding add-in
131 | _ReSharper*/
132 | *.[Rr]e[Ss]harper
133 | *.DotSettings.user
134 |
135 | # TeamCity is a build add-in
136 | _TeamCity*
137 |
138 | # DotCover is a Code Coverage Tool
139 | *.dotCover
140 |
141 | # AxoCover is a Code Coverage Tool
142 | .axoCover/*
143 | !.axoCover/settings.json
144 |
145 | # Coverlet is a free, cross platform Code Coverage Tool
146 | coverage*.json
147 | coverage*.xml
148 | coverage*.info
149 |
150 | # Visual Studio code coverage results
151 | *.coverage
152 | *.coveragexml
153 |
154 | # NCrunch
155 | _NCrunch_*
156 | .*crunch*.local.xml
157 | nCrunchTemp_*
158 |
159 | # MightyMoose
160 | *.mm.*
161 | AutoTest.Net/
162 |
163 | # Web workbench (sass)
164 | .sass-cache/
165 |
166 | # Installshield output folder
167 | [Ee]xpress/
168 |
169 | # DocProject is a documentation generator add-in
170 | DocProject/buildhelp/
171 | DocProject/Help/*.HxT
172 | DocProject/Help/*.HxC
173 | DocProject/Help/*.hhc
174 | DocProject/Help/*.hhk
175 | DocProject/Help/*.hhp
176 | DocProject/Help/Html2
177 | DocProject/Help/html
178 |
179 | # Click-Once directory
180 | publish/
181 |
182 | # Publish Web Output
183 | *.[Pp]ublish.xml
184 | *.azurePubxml
185 | # Note: Comment the next line if you want to checkin your web deploy settings,
186 | # but database connection strings (with potential passwords) will be unencrypted
187 | *.pubxml
188 | *.publishproj
189 |
190 | # Microsoft Azure Web App publish settings. Comment the next line if you want to
191 | # checkin your Azure Web App publish settings, but sensitive information contained
192 | # in these scripts will be unencrypted
193 | PublishScripts/
194 |
195 | # NuGet Packages
196 | *.nupkg
197 | # NuGet Symbol Packages
198 | *.snupkg
199 | # The packages folder can be ignored because of Package Restore
200 | **/[Pp]ackages/*
201 | # except build/, which is used as an MSBuild target.
202 | !**/[Pp]ackages/build/
203 | # Uncomment if necessary however generally it will be regenerated when needed
204 | #!**/[Pp]ackages/repositories.config
205 | # NuGet v3's project.json files produces more ignorable files
206 | *.nuget.props
207 | *.nuget.targets
208 |
209 | # Microsoft Azure Build Output
210 | csx/
211 | *.build.csdef
212 |
213 | # Microsoft Azure Emulator
214 | ecf/
215 | rcf/
216 |
217 | # Windows Store app package directories and files
218 | AppPackages/
219 | BundleArtifacts/
220 | Package.StoreAssociation.xml
221 | _pkginfo.txt
222 | *.appx
223 | *.appxbundle
224 | *.appxupload
225 |
226 | # Visual Studio cache files
227 | # files ending in .cache can be ignored
228 | *.[Cc]ache
229 | # but keep track of directories ending in .cache
230 | !?*.[Cc]ache/
231 |
232 | # Others
233 | ClientBin/
234 | ~$*
235 | *~
236 | *.dbmdl
237 | *.dbproj.schemaview
238 | *.jfm
239 | *.pfx
240 | *.publishsettings
241 | orleans.codegen.cs
242 |
243 | # Including strong name files can present a security risk
244 | # (https://github.com/github/gitignore/pull/2483#issue-259490424)
245 | #*.snk
246 |
247 | # Since there are multiple workflows, uncomment next line to ignore bower_components
248 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
249 | #bower_components/
250 |
251 | # RIA/Silverlight projects
252 | Generated_Code/
253 |
254 | # Backup & report files from converting an old project file
255 | # to a newer Visual Studio version. Backup files are not needed,
256 | # because we have git ;-)
257 | _UpgradeReport_Files/
258 | Backup*/
259 | UpgradeLog*.XML
260 | UpgradeLog*.htm
261 | ServiceFabricBackup/
262 | *.rptproj.bak
263 |
264 | # SQL Server files
265 | *.mdf
266 | *.ldf
267 | *.ndf
268 |
269 | # Business Intelligence projects
270 | *.rdl.data
271 | *.bim.layout
272 | *.bim_*.settings
273 | *.rptproj.rsuser
274 | *- [Bb]ackup.rdl
275 | *- [Bb]ackup ([0-9]).rdl
276 | *- [Bb]ackup ([0-9][0-9]).rdl
277 |
278 | # Microsoft Fakes
279 | FakesAssemblies/
280 |
281 | # GhostDoc plugin setting file
282 | *.GhostDoc.xml
283 |
284 | # Node.js Tools for Visual Studio
285 | .ntvs_analysis.dat
286 | node_modules/
287 |
288 | # Visual Studio 6 build log
289 | *.plg
290 |
291 | # Visual Studio 6 workspace options file
292 | *.opt
293 |
294 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
295 | *.vbw
296 |
297 | # Visual Studio LightSwitch build output
298 | **/*.HTMLClient/GeneratedArtifacts
299 | **/*.DesktopClient/GeneratedArtifacts
300 | **/*.DesktopClient/ModelManifest.xml
301 | **/*.Server/GeneratedArtifacts
302 | **/*.Server/ModelManifest.xml
303 | _Pvt_Extensions
304 |
305 | # Paket dependency manager
306 | .paket/paket.exe
307 | paket-files/
308 |
309 | # FAKE - F# Make
310 | .fake/
311 |
312 | # CodeRush personal settings
313 | .cr/personal
314 |
315 | # Python Tools for Visual Studio (PTVS)
316 | __pycache__/
317 | *.pyc
318 |
319 | # Cake - Uncomment if you are using it
320 | # tools/**
321 | # !tools/packages.config
322 |
323 | # Tabs Studio
324 | *.tss
325 |
326 | # Telerik's JustMock configuration file
327 | *.jmconfig
328 |
329 | # BizTalk build output
330 | *.btp.cs
331 | *.btm.cs
332 | *.odx.cs
333 | *.xsd.cs
334 |
335 | # OpenCover UI analysis results
336 | OpenCover/
337 |
338 | # Azure Stream Analytics local run output
339 | ASALocalRun/
340 |
341 | # MSBuild Binary and Structured Log
342 | *.binlog
343 |
344 | # NVidia Nsight GPU debugger configuration file
345 | *.nvuser
346 |
347 | # MFractors (Xamarin productivity tool) working folder
348 | .mfractor/
349 |
350 | # Local History for Visual Studio
351 | .localhistory/
352 |
353 | # BeatPulse healthcheck temp database
354 | healthchecksdb
355 |
356 | # Backup folder for Package Reference Convert tool in Visual Studio 2017
357 | MigrationBackup/
358 |
359 | # Ionide (cross platform F# VS Code tools) working folder
360 | .ionide/
361 |
362 | # Fody - auto-generated XML schema
363 | FodyWeavers.xsd
--------------------------------------------------------------------------------
/AWS-Connect-Manager/AWS-Connect-Manager.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Debug
6 | AnyCPU
7 | {4733626A-6650-435F-B3C3-632CA184E6D2}
8 | WinExe
9 | AWS_Connect_Manager
10 | AWS-Connect-Manager
11 | v4.7.2
12 | 512
13 | true
14 | true
15 |
16 |
17 |
18 | AnyCPU
19 | true
20 | full
21 | false
22 | bin\Debug\
23 | DEBUG;TRACE
24 | prompt
25 | 4
26 |
27 |
28 | AnyCPU
29 | pdbonly
30 | true
31 | bin\Release\
32 | TRACE
33 | prompt
34 | 4
35 |
36 |
37 | AWS.ico
38 |
39 |
40 |
41 | ..\packages\AWSSDK.Core.3.7.3.25\lib\net45\AWSSDK.Core.dll
42 |
43 |
44 | ..\packages\AWSSDK.EC2.3.7.34.3\lib\net45\AWSSDK.EC2.dll
45 |
46 |
47 | ..\packages\AWSSDK.SimpleNotificationService.3.7.2.56\lib\net45\AWSSDK.SimpleNotificationService.dll
48 |
49 |
50 | ..\packages\AWSSDK.SSO.3.7.0.84\lib\net45\AWSSDK.SSO.dll
51 |
52 |
53 | ..\packages\Microsoft.Bcl.AsyncInterfaces.5.0.0\lib\net461\Microsoft.Bcl.AsyncInterfaces.dll
54 |
55 |
56 |
57 | ..\packages\System.Buffers.4.5.1\lib\net461\System.Buffers.dll
58 |
59 |
60 |
61 | ..\packages\System.Memory.4.5.4\lib\net461\System.Memory.dll
62 |
63 |
64 |
65 | ..\packages\System.Numerics.Vectors.4.5.0\lib\net46\System.Numerics.Vectors.dll
66 |
67 |
68 | ..\packages\System.Runtime.CompilerServices.Unsafe.5.0.0\lib\net45\System.Runtime.CompilerServices.Unsafe.dll
69 |
70 |
71 | ..\packages\System.Text.Encodings.Web.5.0.1\lib\net461\System.Text.Encodings.Web.dll
72 |
73 |
74 | ..\packages\System.Text.Json.5.0.2\lib\net461\System.Text.Json.dll
75 |
76 |
77 | ..\packages\System.Threading.Tasks.Extensions.4.5.4\lib\net461\System.Threading.Tasks.Extensions.dll
78 |
79 |
80 | ..\packages\System.ValueTuple.4.5.0\lib\net47\System.ValueTuple.dll
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 | Form
95 |
96 |
97 | Form1.cs
98 |
99 |
100 |
101 |
102 | Form1.cs
103 |
104 |
105 | ResXFileCodeGenerator
106 | Resources.Designer.cs
107 | Designer
108 |
109 |
110 | True
111 | Resources.resx
112 |
113 |
114 |
115 | SettingsSingleFileGenerator
116 | Settings.Designer.cs
117 |
118 |
119 | True
120 | Settings.settings
121 | True
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Form1.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.ComponentModel;
4 | using System.Data;
5 | using System.Diagnostics;
6 | using System.Drawing;
7 | using System.IO;
8 | using System.Linq;
9 | using System.Text;
10 | using System.Threading.Tasks;
11 | using System.Windows.Forms;
12 | using Amazon.EC2;
13 | using Amazon.EC2.Model;
14 | using Amazon.SimpleNotificationService;
15 |
16 |
17 | namespace AWS_Connect_Manager
18 | {
19 |
20 | public partial class Form1 : Form
21 | {
22 | public string region_short = "";
23 |
24 | private string[] aws_name = new string[1000];
25 | private string[] aws_key = new string[1000];
26 | private string[] aws_psw = new string[1000];
27 | private string conemu_path = System.IO.Path.GetDirectoryName(Application.ExecutablePath) + "\\cmder_mini\\vendor\\conemu-maximus5\\ConEmu64.exe";
28 | private string ini_path = System.IO.Path.GetDirectoryName(Application.ExecutablePath) + "\\config.ini";
29 | private string start_bat_path = System.IO.Path.GetDirectoryName(Application.ExecutablePath) + "\\start.bat";
30 |
31 | private void UpdateRegion()
32 | {
33 | // update_region
34 | if (region_comboBox.Text == "US East (Ohio)") { region_short = "us-east-2"; }
35 | if (region_comboBox.Text == "US East (N. Virginia)") { region_short = "us-east-1"; }
36 | if (region_comboBox.Text == "US West (N. California)") { region_short = "us-west-1"; }
37 | if (region_comboBox.Text == "US West (Oregon)") { region_short = "us-west-2"; }
38 | if (region_comboBox.Text == "Africa (Cape Town)") { region_short = "af-south-1"; }
39 | if (region_comboBox.Text == "Asia Pacific (Hong Kong)") { region_short = "ap-east-1"; }
40 | if (region_comboBox.Text == "Asia Pacific (Mumbai)") { region_short = "ap-south-1"; }
41 | if (region_comboBox.Text == "Asia Pacific (Osaka)") { region_short = "ap-northeast-3"; }
42 | if (region_comboBox.Text == "Asia Pacific (Seoul)") { region_short = "ap-northeast-2"; }
43 | if (region_comboBox.Text == "Asia Pacific (Singapore)") { region_short = "ap-southeast-1"; }
44 | if (region_comboBox.Text == "Asia Pacific (Sydney)") { region_short = "ap-southeast-2"; }
45 | if (region_comboBox.Text == "Asia Pacific (Tokyo)") { region_short = "ap-northeast-1"; }
46 | if (region_comboBox.Text == "Canada (Central)") { region_short = "ca-central-1"; }
47 | if (region_comboBox.Text == "China (Beijing)") { region_short = "cn-north-1"; }
48 | if (region_comboBox.Text == "China (Ningxia)") { region_short = "cn-northwest-1"; }
49 | if (region_comboBox.Text == "Europe (Frankfurt)") { region_short = "eu-central-1"; }
50 | if (region_comboBox.Text == "Europe (Ireland)") { region_short = "eu-west-1"; }
51 | if (region_comboBox.Text == "Europe (London)") { region_short = "eu-west-2"; }
52 | if (region_comboBox.Text == "Europe (Milan)") { region_short = "eu-south-1"; }
53 | if (region_comboBox.Text == "Europe (Paris)") { region_short = "eu-west-3"; }
54 | if (region_comboBox.Text == "Europe (Stockholm)") { region_short = "eu-north-1"; }
55 | if (region_comboBox.Text == "Middle East (Bahrain)") { region_short = "me-south-1"; }
56 | if (region_comboBox.Text == "South America (São Paulo)") { region_short = "sa-east-1"; }
57 | }
58 |
59 | public Form1()
60 | {
61 | InitializeComponent();
62 | this.select_profile_comboBox.DropDownStyle = ComboBoxStyle.DropDownList;
63 | select_profile_comboBox.Items.Clear();
64 |
65 |
66 |
67 | string path = ini_path;
68 | int counter = 1;
69 | if (File.Exists(path))
70 | {
71 | foreach (string line in System.IO.File.ReadLines(path))
72 | {
73 | if (counter == 1) { environment_config_location.Text = line; }
74 | if (counter == 2) { winscp_install_location.Text = line; }
75 | if (counter == 3) { conemu_install_location.Text = line; }
76 | if (counter == 4) { rdp_username.Text = line; }
77 | if (counter == 5) { rdp_password.Text = line; }
78 |
79 | counter++;
80 | }
81 |
82 | }
83 |
84 |
85 | if (conemu_install_location.Text.Length == 0)
86 | {
87 | conemu_install_location.Text = conemu_path;
88 | }
89 |
90 | counter = 1;
91 | if (File.Exists(environment_config_location.Text))
92 | {
93 | foreach (string line in System.IO.File.ReadLines(environment_config_location.Text))
94 | {
95 |
96 | if (line.StartsWith("[") == true)
97 | {
98 | select_profile_comboBox.Items.Add(line.Replace("[", "").Replace("]", "").Replace(" ", ""));
99 | aws_name[counter] = line.Replace("[", "").Replace("]", "").Replace(" ", "");
100 |
101 | }
102 | else if (line.StartsWith("aws_access_key_id") == true)
103 | {
104 | aws_key[counter - 1] = line.Replace("aws_access_key_id", "").Replace("=", "").Replace(" ", "");
105 | }
106 | else if (line.StartsWith("aws_secret_access_key") == true)
107 | {
108 | aws_psw[counter - 2] = line.Replace("aws_secret_access_key", "").Replace("=", "").Replace(" ", "");
109 | }
110 | counter++;
111 | }
112 | }
113 |
114 | }
115 |
116 |
117 | private void button2_Click(object sender, EventArgs e)
118 | {
119 | var selectedItem = new ListViewItem();
120 | if (aws_instance_list.SelectedItems.Count > 0)
121 | {
122 | selectedItem = aws_instance_list.SelectedItems[0];
123 |
124 | }
125 | else
126 | {
127 | return;
128 | }
129 |
130 |
131 | string path = start_bat_path;
132 | if (File.Exists(path))
133 | {
134 | File.Delete(path);
135 | }
136 |
137 |
138 | System.Diagnostics.Process process = new System.Diagnostics.Process();
139 | System.Diagnostics.ProcessStartInfo startInfo = new System.Diagnostics.ProcessStartInfo();
140 | //startInfo.Verb = "runas";
141 | process.StartInfo = startInfo;
142 |
143 |
144 |
145 | if (selectedItem.SubItems[4].Text.StartsWith("Windows"))
146 | {
147 |
148 | var strCmdText = " -run aws --region "+ region_short + " --profile " + select_profile_comboBox.Text + " ssm start-session --target " + selectedItem.SubItems[1].Text + " --document-name AWS-StartPortForwardingSession --parameters localPortNumber=54322,portNumber=3389";
149 | System.Diagnostics.Process.Start(conemu_path, strCmdText);
150 | System.Threading.Thread.Sleep(3000);
151 | Process rdcProcess = new Process();
152 | sli_ssm_command.Text = "";
153 | rdcProcess.StartInfo.FileName = Environment.ExpandEnvironmentVariables(@"%SystemRoot%\system32\cmdkey.exe");
154 | rdcProcess.StartInfo.Arguments = "/generic:TERMSRV/localhost:54322 /user:" + rdp_username.Text + " /pass:" + rdp_password.Text;
155 | rdcProcess.Start();
156 |
157 | rdcProcess.StartInfo.FileName = Environment.ExpandEnvironmentVariables(@"%SystemRoot%\system32\mstsc.exe");
158 | rdcProcess.StartInfo.Arguments = "/v localhost:54322"; // ip or name of computer to connect
159 | rdcProcess.Start();
160 | }
161 | else
162 | {
163 |
164 | if (winscp_radio_button.Checked == true)
165 | {
166 |
167 | var strCmdText = " -run aws --region " + region_short + " --profile " + select_profile_comboBox.Text + " ssm start-session --target " + selectedItem.SubItems[1].Text + " --document-name AWS-StartPortForwardingSession --parameters localPortNumber=54321,portNumber=22";
168 | System.Diagnostics.Process.Start(conemu_path, strCmdText);
169 | // process.Start();
170 | sli_ssm_command.Text = "";
171 | strCmdText = " -run \"" + winscp_install_location.Text + "\" /mysession AWS";
172 | System.Diagnostics.Process.Start(conemu_path, strCmdText);
173 | //process.Start();
174 |
175 |
176 |
177 | }
178 | else {
179 |
180 | if ((conemu_install_location.Text.Contains("ConEmu") || (conemu_install_location.Text.Contains("Cmder"))))
181 | {
182 | var strCmdText = " -run aws --region " + region_short + " --profile " + select_profile_comboBox.Text + " ssm start-session --target " + selectedItem.SubItems[1].Text;
183 | sli_ssm_command.Text = strCmdText.Replace(" -run ","");
184 | System.Diagnostics.Process.Start(conemu_path, strCmdText);
185 | //process.Start();
186 |
187 | } else
188 | {
189 | MessageBox.Show("ConEmu path is missing in the configuration!");
190 | }
191 |
192 |
193 |
194 | }
195 | }
196 |
197 |
198 | }
199 |
200 | private void Instance_DoubleClick(object sender, EventArgs e)
201 | {
202 | connect_button.PerformClick();
203 | sli_ssm_command.Text = "";
204 | }
205 |
206 |
207 | private void Instance_Click(object sender, EventArgs e)
208 | {
209 |
210 | var selectedItem = aws_instance_list.SelectedItems[0];
211 |
212 | if (selectedItem.SubItems[4].Text.StartsWith("Windows"))
213 | {
214 |
215 | sli_ssm_command.Text = "";
216 | }
217 | else
218 | {
219 |
220 | if (winscp_radio_button.Checked == true)
221 | {
222 |
223 | sli_ssm_command.Text = "";
224 | } else
225 | {
226 |
227 | var strCmdText = "aws --region " + region_short + " --profile " + select_profile_comboBox.Text + " ssm start-session --target " + selectedItem.SubItems[1].Text;
228 | sli_ssm_command.Text = strCmdText;
229 | }
230 |
231 | }
232 | }
233 |
234 | private void Instance_SelectedIndexChanged(object sender, EventArgs e)
235 | {
236 | sli_ssm_command.Text = "";
237 | if (aws_instance_list.SelectedItems.Count > 0)
238 | {
239 | var selectedItem = aws_instance_list.SelectedItems[0];
240 |
241 | var msg = "";
242 |
243 | if (selectedItem.SubItems[4].Text.StartsWith("Windows"))
244 | {
245 | msg = "RDP to ";
246 | winscp_radio_button.Visible = false;
247 | aws_ssm_radio_button.Visible = false;
248 | } else
249 | {
250 | if (aws_ssm_radio_button.Checked) {
251 | msg = "AWS SSM to ";
252 | winscp_radio_button.Visible = true;
253 | aws_ssm_radio_button.Visible = true;
254 | } else
255 | {
256 | msg = "WinSCP to ";
257 | winscp_radio_button.Visible = true;
258 | aws_ssm_radio_button.Visible = true;
259 | }
260 | }
261 |
262 | connect_button.Text = msg + selectedItem.SubItems[0].Text;
263 | copy_instance_id_textBox.Text = selectedItem.SubItems[1].Text;
264 | copy_ip_address_textBox.Text = selectedItem.SubItems[2].Text;
265 | }
266 | else
267 | {
268 | return;
269 | }
270 | }
271 |
272 | private void button2_Click_1(object sender, EventArgs e)
273 | {
274 | var selectedItem = new ListViewItem();
275 | if (aws_instance_list.SelectedItems.Count > 0)
276 | {
277 | selectedItem = aws_instance_list.SelectedItems[0];
278 | Clipboard.SetText(selectedItem.SubItems[1].Text);
279 | }
280 | else
281 | {
282 | return;
283 | }
284 |
285 |
286 | }
287 |
288 | private void checkBox1_CheckedChanged(object sender, EventArgs e)
289 | {
290 | comboBox2_SelectedIndexChanged(select_profile_comboBox, EventArgs.Empty);
291 | }
292 |
293 | private void textBox1_Click(object sender, EventArgs e)
294 | {
295 |
296 |
297 | copy_instance_id_textBox.SelectionStart = 0;
298 | copy_instance_id_textBox.SelectionLength = copy_instance_id_textBox.Text.Length;
299 | Clipboard.SetText(copy_instance_id_textBox.Text);
300 | toolTip1.Show(copy_instance_id_textBox.Text + " - Copied to Clipboard", copy_instance_id_textBox);
301 | toolTip1.Hide(copy_instance_id_textBox);
302 |
303 | }
304 |
305 | private void textBox2_Click(object sender, EventArgs e)
306 | {
307 | copy_ip_address_textBox.SelectionStart = 0;
308 | copy_ip_address_textBox.SelectionLength = copy_ip_address_textBox.Text.Length;
309 | Clipboard.SetText(copy_ip_address_textBox.Text);
310 | toolTip1.Show(copy_ip_address_textBox.Text + " - Copied to Clipboard", copy_ip_address_textBox);
311 | toolTip1.Hide(copy_ip_address_textBox);
312 | }
313 |
314 |
315 | private void region_comboBox_SelectedIndexChanged(object sender, EventArgs e)
316 | {
317 | sli_ssm_command.Text = "";
318 | comboBox2_SelectedIndexChanged(select_profile_comboBox, EventArgs.Empty);
319 | }
320 |
321 | private void comboBox2_SelectedIndexChanged(object sender, EventArgs e)
322 | {
323 | UpdateRegion();
324 | copy_instance_id_textBox.Text = "";
325 | copy_ip_address_textBox.Text = "";
326 | string key = "";
327 | string secret = "";
328 |
329 | for (var xy = 0; xy < aws_name.Length; xy++)
330 | {
331 | if (aws_name[xy] == select_profile_comboBox.Text)
332 | {
333 | key = aws_key[xy];
334 | secret = aws_psw[xy];
335 | break;
336 | }
337 | }
338 |
339 |
340 |
341 | if (!select_profile_comboBox.Text.Equals(""))
342 | {
343 | var awsCredentials = new Amazon.Runtime.BasicAWSCredentials(key, secret);
344 | var region = Amazon.RegionEndpoint.CACentral1;
345 |
346 |
347 | if (region_comboBox.Text == "US East (Ohio)") { region = Amazon.RegionEndpoint.USEast2; }
348 | if (region_comboBox.Text == "US East (N. Virginia)") { region = Amazon.RegionEndpoint.USEast1; }
349 | if (region_comboBox.Text == "US West (N. California)") { region = Amazon.RegionEndpoint.USWest1; }
350 | if (region_comboBox.Text == "US West (Oregon)") { region = Amazon.RegionEndpoint.USWest2; }
351 | if (region_comboBox.Text == "Africa (Cape Town)") { region = Amazon.RegionEndpoint.AFSouth1; }
352 | if (region_comboBox.Text == "Asia Pacific (Hong Kong)") { region = Amazon.RegionEndpoint.APEast1;}
353 | if (region_comboBox.Text == "Asia Pacific (Mumbai)") { region = Amazon.RegionEndpoint.APSouth1; }
354 | if (region_comboBox.Text == "Asia Pacific (Osaka)") { region = Amazon.RegionEndpoint.APNortheast3; }
355 | if (region_comboBox.Text == "Asia Pacific (Seoul)") { region = Amazon.RegionEndpoint.APNortheast2; }
356 | if (region_comboBox.Text == "Asia Pacific (Singapore)") { region = Amazon.RegionEndpoint.APSoutheast1; }
357 | if (region_comboBox.Text == "Asia Pacific (Sydney)") { region = Amazon.RegionEndpoint.APSoutheast2; }
358 | if (region_comboBox.Text == "Asia Pacific (Tokyo)") { region = Amazon.RegionEndpoint.APNortheast1; }
359 | if (region_comboBox.Text == "Canada (Central)") { region = Amazon.RegionEndpoint.CACentral1; }
360 | if (region_comboBox.Text == "China (Beijing)") { region = Amazon.RegionEndpoint.CNNorth1; }
361 | if (region_comboBox.Text == "China (Ningxia)") { region = Amazon.RegionEndpoint.CNNorthWest1; }
362 | if (region_comboBox.Text == "Europe (Frankfurt)") { region = Amazon.RegionEndpoint.EUCentral1; }
363 | if (region_comboBox.Text == "Europe (Ireland)") { region = Amazon.RegionEndpoint.EUWest1; }
364 | if (region_comboBox.Text == "Europe (London)") { region = Amazon.RegionEndpoint.EUWest2; }
365 | if (region_comboBox.Text == "Europe (Milan)") { region = Amazon.RegionEndpoint.EUSouth1; }
366 | if (region_comboBox.Text == "Europe (Paris)") { region = Amazon.RegionEndpoint.EUWest3; }
367 | if (region_comboBox.Text == "Europe (Stockholm)") { region = Amazon.RegionEndpoint.EUNorth1; }
368 | if (region_comboBox.Text == "Middle East (Bahrain)") { region = Amazon.RegionEndpoint.MESouth1; }
369 | if (region_comboBox.Text == "South America (São Paulo)") { region = Amazon.RegionEndpoint.SAEast1; }
370 |
371 |
372 | var ec2Client = new Amazon.EC2.AmazonEC2Client(awsCredentials, region);
373 | List listReservations = ec2Client.DescribeInstances().Reservations;
374 | connect_button.Enabled = false;
375 |
376 | var count = listReservations.Count;
377 | aws_instance_list.Items.Clear();
378 | // continue if more than one instance available
379 | if (count>0) {
380 |
381 | instance_count.Text = count + " instances";
382 | var ins = listReservations.ElementAt(0);
383 |
384 |
385 |
386 | for (var i = 0; i < count; i++)
387 | {
388 | var finname = "";
389 |
390 |
391 | for (var ii = 0; ii < listReservations.ElementAt(i).Instances[0].Tags.Count; ii++)
392 | {
393 | if (listReservations.ElementAt(i).Instances[0].Tags[ii].Key.Equals("Name")) {
394 | finname = listReservations.ElementAt(i).Instances[0].Tags[ii].Value;
395 | }
396 | }
397 |
398 | if (show_running_checkBox.Checked == true)
399 | {
400 | if (listReservations.ElementAt(i).Instances[0].State.Name.Value.Equals("running"))
401 | {
402 | aws_instance_list.Font = new Font(aws_instance_list.Font, FontStyle.Bold);
403 | ListViewItem item = new ListViewItem(finname);
404 | item.Font = new Font(item.Font, FontStyle.Regular);
405 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].InstanceId);
406 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].PrivateIpAddress);
407 | // item.SubItems.Add(listReservations.ElementAt(i).Instances[0].PublicIpAddress);
408 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].InstanceType);
409 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].PlatformDetails);
410 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].Placement.AvailabilityZone);
411 | if (listReservations.ElementAt(i).Instances[0].State.Name.Value.Equals("running"))
412 | {
413 | item.SubItems.Add("Running");
414 | }
415 | else
416 | {
417 | item.SubItems.Add("Stopped");
418 | }
419 | aws_instance_list.Items.Add(item);
420 | }
421 | }
422 | else
423 | {
424 | aws_instance_list.Font = new Font(aws_instance_list.Font, FontStyle.Bold);
425 | ListViewItem item = new ListViewItem(finname);
426 | item.Font = new Font(item.Font, FontStyle.Regular);
427 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].InstanceId);
428 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].PrivateIpAddress);
429 | // item.SubItems.Add(listReservations.ElementAt(i).Instances[0].PublicIpAddress);
430 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].InstanceType);
431 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].PlatformDetails);
432 | item.SubItems.Add(listReservations.ElementAt(i).Instances[0].Placement.AvailabilityZone);
433 | if (listReservations.ElementAt(i).Instances[0].State.Name.Value.Equals("running"))
434 | {
435 | item.SubItems.Add("Running");
436 | }
437 | else
438 | {
439 | item.SubItems.Add("Stopped");
440 | }
441 | aws_instance_list.Items.Add(item);
442 | }
443 |
444 |
445 |
446 | }
447 | aws_instance_list.Columns[0].Width = -2;
448 | aws_instance_list.AutoResizeColumns(ColumnHeaderAutoResizeStyle.ColumnContent);
449 | aws_instance_list.AutoResizeColumns(ColumnHeaderAutoResizeStyle.HeaderSize);
450 |
451 |
452 | }
453 | connect_button.Enabled = true;
454 | }
455 |
456 |
457 |
458 |
459 |
460 |
461 |
462 |
463 |
464 | //instance.Sort();
465 | }
466 |
467 |
468 | private void radioButton1_Click(object sender, EventArgs e)
469 | {
470 | var selectedItem = new ListViewItem();
471 | if (aws_instance_list.SelectedItems.Count > 0)
472 | {
473 | selectedItem = aws_instance_list.SelectedItems[0];
474 |
475 | }
476 | else
477 | {
478 | return;
479 | }
480 | winscp_radio_button.Checked = true;
481 | aws_ssm_radio_button.Checked = false;
482 | connect_button.Text = "WinSCP to " + selectedItem.SubItems[0].Text;
483 | }
484 |
485 | private void radioButton2_Click(object sender, EventArgs e)
486 | {
487 | var selectedItem = new ListViewItem();
488 | if (aws_instance_list.SelectedItems.Count > 0)
489 | {
490 | selectedItem = aws_instance_list.SelectedItems[0];
491 |
492 | }
493 | else
494 | {
495 | return;
496 | }
497 | winscp_radio_button.Checked = false;
498 | aws_ssm_radio_button.Checked = true;
499 | connect_button.Text = "AWS SSM to " + selectedItem.SubItems[0].Text;
500 | }
501 |
502 |
503 | private void button1_Click(object sender, EventArgs e)
504 | {
505 | OpenFileDialog choofdlog = new OpenFileDialog();
506 | choofdlog.Filter = "All Files (*.*)|*";
507 | choofdlog.FilterIndex = 1;
508 | choofdlog.Multiselect = true;
509 |
510 | if (choofdlog.ShowDialog() == DialogResult.OK)
511 | {
512 | string sFileName = choofdlog.FileName;
513 | //string[] arrAllFiles = choofdlog.FileNames; //used when Multiselect = true
514 | environment_config_location.Text = sFileName;
515 | }
516 | }
517 |
518 | private void button2_Click_3(object sender, EventArgs e)
519 | {
520 | OpenFileDialog choofdlog = new OpenFileDialog();
521 | choofdlog.Filter = "All Files (*.*)|*exe*";
522 | choofdlog.FilterIndex = 1;
523 | choofdlog.Multiselect = true;
524 |
525 | if (choofdlog.ShowDialog() == DialogResult.OK)
526 | {
527 | string sFileName = choofdlog.FileName;
528 | //string[] arrAllFiles = choofdlog.FileNames; //used when Multiselect = true
529 | winscp_install_location.Text = sFileName;
530 | }
531 | }
532 |
533 | private void button3_Click(object sender, EventArgs e)
534 | {
535 | select_profile_comboBox.Items.Clear();
536 | aws_instance_list.Items.Clear();
537 |
538 | string path = System.IO.Path.GetDirectoryName(Application.ExecutablePath) + "\\config.ini";
539 | using (StreamWriter writer = new StreamWriter(path))
540 | {
541 | writer.WriteLine(environment_config_location.Text);
542 | writer.WriteLine(winscp_install_location.Text);
543 | writer.WriteLine(conemu_install_location.Text);
544 | writer.WriteLine(rdp_username.Text);
545 | writer.WriteLine(rdp_password.Text);
546 |
547 | }
548 |
549 |
550 | var counter = 1;
551 | if (File.Exists(environment_config_location.Text))
552 | {
553 | foreach (string line in System.IO.File.ReadLines(environment_config_location.Text))
554 | {
555 | //comboBox2.Items.Clear();
556 | if (line.StartsWith("[") == true)
557 | {
558 | select_profile_comboBox.Items.Add(line.Replace("[", "").Replace("]", "").Replace(" ", ""));
559 | aws_name[counter] = line.Replace("[", "").Replace("]", "").Replace(" ", "");
560 |
561 | }
562 | else if (line.StartsWith("aws_access_key_id") == true)
563 | {
564 | aws_key[counter - 1] = line.Replace("aws_access_key_id", "").Replace("=", "").Replace(" ", "");
565 | }
566 | else if (line.StartsWith("aws_secret_access_key") == true)
567 | {
568 | aws_psw[counter - 2] = line.Replace("aws_secret_access_key", "").Replace("=", "").Replace(" ", "");
569 | }
570 | counter++;
571 | }
572 | }
573 |
574 | MessageBox.Show("Saved!");
575 |
576 | }
577 |
578 |
579 | private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
580 | {
581 | System.Diagnostics.Process.Start("https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-install.html");
582 | }
583 |
584 | private void linkLabel2_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
585 | {
586 | System.Diagnostics.Process.Start("https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-install-plugin.html");
587 |
588 | }
589 |
590 | private void linkLabel3_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
591 | {
592 | System.Diagnostics.Process.Start("https://winscp.net/eng/download.php");
593 | }
594 |
595 | private void linkLabel4_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
596 | {
597 | System.Diagnostics.Process.Start("https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html");
598 | }
599 |
600 | private void toolStripStatusLabel1_Click(object sender, EventArgs e)
601 | {
602 | System.Diagnostics.Process.Start("https://joe0.com");
603 | }
604 |
605 | private void aws_ssm_radio_button_CheckedChanged(object sender, EventArgs e)
606 | {
607 | sli_ssm_command.Text = "";
608 | }
609 |
610 | private void winscp_radio_button_CheckedChanged(object sender, EventArgs e)
611 | {
612 | sli_ssm_command.Text = "";
613 | }
614 |
615 | private void copy_ip_address_textBox_TextChanged(object sender, EventArgs e)
616 | {
617 |
618 | }
619 |
620 | private void textBox1_TextChanged(object sender, EventArgs e)
621 | {
622 |
623 | }
624 |
625 | }
626 | }
627 |
--------------------------------------------------------------------------------
/AWS-Connect-Manager/Form1.Designer.cs:
--------------------------------------------------------------------------------
1 |
2 | namespace AWS_Connect_Manager
3 | {
4 | partial class Form1
5 | {
6 | ///
7 | /// Required designer variable.
8 | ///
9 | private System.ComponentModel.IContainer components = null;
10 |
11 | ///
12 | /// Clean up any resources being used.
13 | ///
14 | /// true if managed resources should be disposed; otherwise, false.
15 | protected override void Dispose(bool disposing)
16 | {
17 | if (disposing && (components != null))
18 | {
19 | components.Dispose();
20 | }
21 | base.Dispose(disposing);
22 | }
23 |
24 | #region Windows Form Designer generated code
25 |
26 | ///
27 | /// Required method for Designer support - do not modify
28 | /// the contents of this method with the code editor.
29 | ///
30 | private void InitializeComponent()
31 | {
32 | this.components = new System.ComponentModel.Container();
33 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));
34 | this.select_profile_comboBox = new System.Windows.Forms.ComboBox();
35 | this.aws_instance_list = new System.Windows.Forms.ListView();
36 | this.InstanceTag = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
37 | this.InstanceId = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
38 | this.PrivateIpAddress = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
39 | this.InstanceType = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
40 | this.PlatformDetails = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
41 | this.AvailabilityZone = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
42 | this.connect_button = new System.Windows.Forms.Button();
43 | this.instance_count = new System.Windows.Forms.Label();
44 | this.copy_instance_id_textBox = new System.Windows.Forms.TextBox();
45 | this.copy_ip_address_textBox = new System.Windows.Forms.TextBox();
46 | this.show_running_checkBox = new System.Windows.Forms.CheckBox();
47 | this.winscp_radio_button = new System.Windows.Forms.RadioButton();
48 | this.aws_ssm_radio_button = new System.Windows.Forms.RadioButton();
49 | this.label1 = new System.Windows.Forms.Label();
50 | this.label2 = new System.Windows.Forms.Label();
51 | this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);
52 | this.label11 = new System.Windows.Forms.Label();
53 | this.app__tabControl = new System.Windows.Forms.TabControl();
54 | this.app_tabPage_aws = new System.Windows.Forms.TabPage();
55 | this.label6 = new System.Windows.Forms.Label();
56 | this.sli_ssm_command = new System.Windows.Forms.TextBox();
57 | this.app_tabPage_configuration = new System.Windows.Forms.TabPage();
58 | this.statusStrip1 = new System.Windows.Forms.StatusStrip();
59 | this.toolStripStatusLabel1 = new System.Windows.Forms.ToolStripStatusLabel();
60 | this.linkLabel4 = new System.Windows.Forms.LinkLabel();
61 | this.linkLabel3 = new System.Windows.Forms.LinkLabel();
62 | this.linkLabel2 = new System.Windows.Forms.LinkLabel();
63 | this.linkLabel1 = new System.Windows.Forms.LinkLabel();
64 | this.path_config_header = new System.Windows.Forms.Label();
65 | this.prerequisites_header = new System.Windows.Forms.Label();
66 | this.rdp_header = new System.Windows.Forms.Label();
67 | this.rdp_password_header = new System.Windows.Forms.Label();
68 | this.rdp_password = new System.Windows.Forms.TextBox();
69 | this.rdp_username = new System.Windows.Forms.TextBox();
70 | this.rdp_username_header = new System.Windows.Forms.Label();
71 | this.button4 = new System.Windows.Forms.Button();
72 | this.conemu_install_location = new System.Windows.Forms.TextBox();
73 | this.label5 = new System.Windows.Forms.Label();
74 | this.save_button = new System.Windows.Forms.Button();
75 | this.button2 = new System.Windows.Forms.Button();
76 | this.button1 = new System.Windows.Forms.Button();
77 | this.winscp_install_location = new System.Windows.Forms.TextBox();
78 | this.environment_config_location = new System.Windows.Forms.TextBox();
79 | this.label4 = new System.Windows.Forms.Label();
80 | this.label3 = new System.Windows.Forms.Label();
81 | this.region_comboBox = new System.Windows.Forms.ComboBox();
82 | this.app__tabControl.SuspendLayout();
83 | this.app_tabPage_aws.SuspendLayout();
84 | this.app_tabPage_configuration.SuspendLayout();
85 | this.statusStrip1.SuspendLayout();
86 | this.SuspendLayout();
87 | //
88 | // select_profile_comboBox
89 | //
90 | this.select_profile_comboBox.Font = new System.Drawing.Font("Microsoft Sans Serif", 13F, System.Drawing.FontStyle.Bold);
91 | this.select_profile_comboBox.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
92 | this.select_profile_comboBox.FormattingEnabled = true;
93 | this.select_profile_comboBox.Items.AddRange(new object[] {
94 | "Select Environment"});
95 | this.select_profile_comboBox.Location = new System.Drawing.Point(6, 6);
96 | this.select_profile_comboBox.Name = "select_profile_comboBox";
97 | this.select_profile_comboBox.Size = new System.Drawing.Size(272, 28);
98 | this.select_profile_comboBox.TabIndex = 1;
99 | this.select_profile_comboBox.Text = "Select Environment";
100 | this.select_profile_comboBox.SelectedIndexChanged += new System.EventHandler(this.comboBox2_SelectedIndexChanged);
101 | //
102 | // aws_instance_list
103 | //
104 | this.aws_instance_list.BackColor = System.Drawing.SystemColors.Control;
105 | this.aws_instance_list.BorderStyle = System.Windows.Forms.BorderStyle.None;
106 | this.aws_instance_list.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
107 | this.InstanceTag,
108 | this.InstanceId,
109 | this.PrivateIpAddress,
110 | this.InstanceType,
111 | this.PlatformDetails,
112 | this.AvailabilityZone});
113 | this.aws_instance_list.Font = new System.Drawing.Font("Arial", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
114 | this.aws_instance_list.FullRowSelect = true;
115 | this.aws_instance_list.HideSelection = false;
116 | this.aws_instance_list.Location = new System.Drawing.Point(5, 41);
117 | this.aws_instance_list.Name = "aws_instance_list";
118 | this.aws_instance_list.Size = new System.Drawing.Size(1087, 515);
119 | this.aws_instance_list.Sorting = System.Windows.Forms.SortOrder.Ascending;
120 | this.aws_instance_list.TabIndex = 2;
121 | this.aws_instance_list.UseCompatibleStateImageBehavior = false;
122 | this.aws_instance_list.View = System.Windows.Forms.View.Details;
123 | this.aws_instance_list.SelectedIndexChanged += new System.EventHandler(this.Instance_SelectedIndexChanged);
124 | this.aws_instance_list.Click += new System.EventHandler(this.Instance_Click);
125 | this.aws_instance_list.DoubleClick += new System.EventHandler(this.Instance_DoubleClick);
126 | //
127 | // InstanceTag
128 | //
129 | this.InstanceTag.Text = "Instance Tag";
130 | this.InstanceTag.Width = 141;
131 | //
132 | // InstanceId
133 | //
134 | this.InstanceId.Text = "Instance Id";
135 | this.InstanceId.Width = 145;
136 | //
137 | // PrivateIpAddress
138 | //
139 | this.PrivateIpAddress.Text = "Private IP Address";
140 | this.PrivateIpAddress.Width = 215;
141 | //
142 | // InstanceType
143 | //
144 | this.InstanceType.Text = "Instance Type";
145 | this.InstanceType.Width = 152;
146 | //
147 | // PlatformDetails
148 | //
149 | this.PlatformDetails.Text = "Platform Details";
150 | this.PlatformDetails.Width = 170;
151 | //
152 | // AvailabilityZone
153 | //
154 | this.AvailabilityZone.Text = "Availability Zone";
155 | this.AvailabilityZone.Width = 208;
156 | //
157 | // connect_button
158 | //
159 | this.connect_button.Location = new System.Drawing.Point(6, 562);
160 | this.connect_button.Name = "connect_button";
161 | this.connect_button.Size = new System.Drawing.Size(1086, 53);
162 | this.connect_button.TabIndex = 3;
163 | this.connect_button.Text = "Connect";
164 | this.connect_button.UseVisualStyleBackColor = true;
165 | this.connect_button.Click += new System.EventHandler(this.button2_Click);
166 | //
167 | // instance_count
168 | //
169 | this.instance_count.AutoSize = true;
170 | this.instance_count.Location = new System.Drawing.Point(1273, 11);
171 | this.instance_count.Name = "instance_count";
172 | this.instance_count.Size = new System.Drawing.Size(16, 13);
173 | this.instance_count.TabIndex = 4;
174 | this.instance_count.Text = "...";
175 | //
176 | // copy_instance_id_textBox
177 | //
178 | this.copy_instance_id_textBox.Location = new System.Drawing.Point(8, 659);
179 | this.copy_instance_id_textBox.Name = "copy_instance_id_textBox";
180 | this.copy_instance_id_textBox.Size = new System.Drawing.Size(191, 20);
181 | this.copy_instance_id_textBox.TabIndex = 5;
182 | this.copy_instance_id_textBox.Click += new System.EventHandler(this.textBox1_Click);
183 | //
184 | // copy_ip_address_textBox
185 | //
186 | this.copy_ip_address_textBox.Location = new System.Drawing.Point(218, 658);
187 | this.copy_ip_address_textBox.Name = "copy_ip_address_textBox";
188 | this.copy_ip_address_textBox.Size = new System.Drawing.Size(192, 20);
189 | this.copy_ip_address_textBox.TabIndex = 6;
190 | this.copy_ip_address_textBox.Click += new System.EventHandler(this.textBox2_Click);
191 | this.copy_ip_address_textBox.TextChanged += new System.EventHandler(this.copy_ip_address_textBox_TextChanged);
192 | //
193 | // show_running_checkBox
194 | //
195 | this.show_running_checkBox.AutoSize = true;
196 | this.show_running_checkBox.Checked = true;
197 | this.show_running_checkBox.CheckState = System.Windows.Forms.CheckState.Checked;
198 | this.show_running_checkBox.Location = new System.Drawing.Point(581, 13);
199 | this.show_running_checkBox.Name = "show_running_checkBox";
200 | this.show_running_checkBox.Size = new System.Drawing.Size(120, 17);
201 | this.show_running_checkBox.TabIndex = 7;
202 | this.show_running_checkBox.Text = "Show Running Only";
203 | this.show_running_checkBox.UseVisualStyleBackColor = true;
204 | this.show_running_checkBox.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged);
205 | //
206 | // winscp_radio_button
207 | //
208 | this.winscp_radio_button.AutoSize = true;
209 | this.winscp_radio_button.Location = new System.Drawing.Point(883, 621);
210 | this.winscp_radio_button.Name = "winscp_radio_button";
211 | this.winscp_radio_button.Size = new System.Drawing.Size(65, 17);
212 | this.winscp_radio_button.TabIndex = 10;
213 | this.winscp_radio_button.Text = "WinSCP";
214 | this.winscp_radio_button.UseVisualStyleBackColor = true;
215 | this.winscp_radio_button.Visible = false;
216 | this.winscp_radio_button.CheckedChanged += new System.EventHandler(this.winscp_radio_button_CheckedChanged);
217 | this.winscp_radio_button.Click += new System.EventHandler(this.radioButton1_Click);
218 | //
219 | // aws_ssm_radio_button
220 | //
221 | this.aws_ssm_radio_button.AutoSize = true;
222 | this.aws_ssm_radio_button.Checked = true;
223 | this.aws_ssm_radio_button.Location = new System.Drawing.Point(989, 621);
224 | this.aws_ssm_radio_button.Name = "aws_ssm_radio_button";
225 | this.aws_ssm_radio_button.Size = new System.Drawing.Size(76, 17);
226 | this.aws_ssm_radio_button.TabIndex = 11;
227 | this.aws_ssm_radio_button.TabStop = true;
228 | this.aws_ssm_radio_button.Text = "AWS SSM";
229 | this.aws_ssm_radio_button.UseVisualStyleBackColor = true;
230 | this.aws_ssm_radio_button.Visible = false;
231 | this.aws_ssm_radio_button.CheckedChanged += new System.EventHandler(this.aws_ssm_radio_button_CheckedChanged);
232 | this.aws_ssm_radio_button.Click += new System.EventHandler(this.radioButton2_Click);
233 | //
234 | // label1
235 | //
236 | this.label1.AutoSize = true;
237 | this.label1.Location = new System.Drawing.Point(8, 635);
238 | this.label1.Name = "label1";
239 | this.label1.Size = new System.Drawing.Size(131, 13);
240 | this.label1.TabIndex = 12;
241 | this.label1.Text = "Instance ID (click to copy)";
242 | //
243 | // label2
244 | //
245 | this.label2.AutoSize = true;
246 | this.label2.Location = new System.Drawing.Point(214, 635);
247 | this.label2.Name = "label2";
248 | this.label2.Size = new System.Drawing.Size(127, 13);
249 | this.label2.TabIndex = 13;
250 | this.label2.Text = "IP Address (click to copy)";
251 | //
252 | // label11
253 | //
254 | this.label11.AutoSize = true;
255 | this.label11.Location = new System.Drawing.Point(14, 55);
256 | this.label11.Name = "label11";
257 | this.label11.Size = new System.Drawing.Size(0, 13);
258 | this.label11.TabIndex = 21;
259 | this.toolTip1.SetToolTip(this.label11, "Prerequisites");
260 | //
261 | // app__tabControl
262 | //
263 | this.app__tabControl.Controls.Add(this.app_tabPage_aws);
264 | this.app__tabControl.Controls.Add(this.app_tabPage_configuration);
265 | this.app__tabControl.Dock = System.Windows.Forms.DockStyle.Fill;
266 | this.app__tabControl.Location = new System.Drawing.Point(0, 0);
267 | this.app__tabControl.Name = "app__tabControl";
268 | this.app__tabControl.SelectedIndex = 0;
269 | this.app__tabControl.Size = new System.Drawing.Size(1108, 729);
270 | this.app__tabControl.TabIndex = 14;
271 | //
272 | // app_tabPage_aws
273 | //
274 | this.app_tabPage_aws.BackColor = System.Drawing.SystemColors.Control;
275 | this.app_tabPage_aws.Controls.Add(this.region_comboBox);
276 | this.app_tabPage_aws.Controls.Add(this.label6);
277 | this.app_tabPage_aws.Controls.Add(this.sli_ssm_command);
278 | this.app_tabPage_aws.Controls.Add(this.aws_instance_list);
279 | this.app_tabPage_aws.Controls.Add(this.label2);
280 | this.app_tabPage_aws.Controls.Add(this.select_profile_comboBox);
281 | this.app_tabPage_aws.Controls.Add(this.label1);
282 | this.app_tabPage_aws.Controls.Add(this.aws_ssm_radio_button);
283 | this.app_tabPage_aws.Controls.Add(this.show_running_checkBox);
284 | this.app_tabPage_aws.Controls.Add(this.winscp_radio_button);
285 | this.app_tabPage_aws.Controls.Add(this.instance_count);
286 | this.app_tabPage_aws.Controls.Add(this.copy_ip_address_textBox);
287 | this.app_tabPage_aws.Controls.Add(this.connect_button);
288 | this.app_tabPage_aws.Controls.Add(this.copy_instance_id_textBox);
289 | this.app_tabPage_aws.Location = new System.Drawing.Point(4, 22);
290 | this.app_tabPage_aws.Name = "app_tabPage_aws";
291 | this.app_tabPage_aws.Padding = new System.Windows.Forms.Padding(3);
292 | this.app_tabPage_aws.Size = new System.Drawing.Size(1100, 703);
293 | this.app_tabPage_aws.TabIndex = 0;
294 | this.app_tabPage_aws.Text = "AWS Instances";
295 | //
296 | // label6
297 | //
298 | this.label6.AutoSize = true;
299 | this.label6.Location = new System.Drawing.Point(416, 636);
300 | this.label6.Name = "label6";
301 | this.label6.Size = new System.Drawing.Size(99, 13);
302 | this.label6.TabIndex = 15;
303 | this.label6.Text = "CLI SSM Command";
304 | //
305 | // sli_ssm_command
306 | //
307 | this.sli_ssm_command.Location = new System.Drawing.Point(416, 659);
308 | this.sli_ssm_command.Name = "sli_ssm_command";
309 | this.sli_ssm_command.Size = new System.Drawing.Size(676, 20);
310 | this.sli_ssm_command.TabIndex = 14;
311 | this.sli_ssm_command.TextChanged += new System.EventHandler(this.textBox1_TextChanged);
312 | //
313 | // app_tabPage_configuration
314 | //
315 | this.app_tabPage_configuration.BackColor = System.Drawing.SystemColors.Control;
316 | this.app_tabPage_configuration.Controls.Add(this.statusStrip1);
317 | this.app_tabPage_configuration.Controls.Add(this.linkLabel4);
318 | this.app_tabPage_configuration.Controls.Add(this.linkLabel3);
319 | this.app_tabPage_configuration.Controls.Add(this.linkLabel2);
320 | this.app_tabPage_configuration.Controls.Add(this.linkLabel1);
321 | this.app_tabPage_configuration.Controls.Add(this.path_config_header);
322 | this.app_tabPage_configuration.Controls.Add(this.label11);
323 | this.app_tabPage_configuration.Controls.Add(this.prerequisites_header);
324 | this.app_tabPage_configuration.Controls.Add(this.rdp_header);
325 | this.app_tabPage_configuration.Controls.Add(this.rdp_password_header);
326 | this.app_tabPage_configuration.Controls.Add(this.rdp_password);
327 | this.app_tabPage_configuration.Controls.Add(this.rdp_username);
328 | this.app_tabPage_configuration.Controls.Add(this.rdp_username_header);
329 | this.app_tabPage_configuration.Controls.Add(this.button4);
330 | this.app_tabPage_configuration.Controls.Add(this.conemu_install_location);
331 | this.app_tabPage_configuration.Controls.Add(this.label5);
332 | this.app_tabPage_configuration.Controls.Add(this.save_button);
333 | this.app_tabPage_configuration.Controls.Add(this.button2);
334 | this.app_tabPage_configuration.Controls.Add(this.button1);
335 | this.app_tabPage_configuration.Controls.Add(this.winscp_install_location);
336 | this.app_tabPage_configuration.Controls.Add(this.environment_config_location);
337 | this.app_tabPage_configuration.Controls.Add(this.label4);
338 | this.app_tabPage_configuration.Controls.Add(this.label3);
339 | this.app_tabPage_configuration.Location = new System.Drawing.Point(4, 22);
340 | this.app_tabPage_configuration.Name = "app_tabPage_configuration";
341 | this.app_tabPage_configuration.Padding = new System.Windows.Forms.Padding(3);
342 | this.app_tabPage_configuration.Size = new System.Drawing.Size(1100, 703);
343 | this.app_tabPage_configuration.TabIndex = 1;
344 | this.app_tabPage_configuration.Text = "Configuration";
345 | //
346 | // statusStrip1
347 | //
348 | this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
349 | this.toolStripStatusLabel1});
350 | this.statusStrip1.Location = new System.Drawing.Point(3, 678);
351 | this.statusStrip1.Name = "statusStrip1";
352 | this.statusStrip1.Size = new System.Drawing.Size(1094, 22);
353 | this.statusStrip1.TabIndex = 29;
354 | this.statusStrip1.Text = "statusStrip1";
355 | //
356 | // toolStripStatusLabel1
357 | //
358 | this.toolStripStatusLabel1.Name = "toolStripStatusLabel1";
359 | this.toolStripStatusLabel1.Size = new System.Drawing.Size(97, 17);
360 | this.toolStripStatusLabel1.Text = "© Jozef Jarosciak";
361 | this.toolStripStatusLabel1.Click += new System.EventHandler(this.toolStripStatusLabel1_Click);
362 | //
363 | // linkLabel4
364 | //
365 | this.linkLabel4.AutoSize = true;
366 | this.linkLabel4.Location = new System.Drawing.Point(20, 75);
367 | this.linkLabel4.Name = "linkLabel4";
368 | this.linkLabel4.Size = new System.Drawing.Size(188, 13);
369 | this.linkLabel4.TabIndex = 28;
370 | this.linkLabel4.TabStop = true;
371 | this.linkLabel4.Text = "AWS Credential File (.aws/credentials)";
372 | this.linkLabel4.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel4_LinkClicked);
373 | //
374 | // linkLabel3
375 | //
376 | this.linkLabel3.AutoSize = true;
377 | this.linkLabel3.Location = new System.Drawing.Point(20, 115);
378 | this.linkLabel3.Name = "linkLabel3";
379 | this.linkLabel3.Size = new System.Drawing.Size(47, 13);
380 | this.linkLabel3.TabIndex = 26;
381 | this.linkLabel3.TabStop = true;
382 | this.linkLabel3.Text = "WinSCP";
383 | this.linkLabel3.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel3_LinkClicked);
384 | //
385 | // linkLabel2
386 | //
387 | this.linkLabel2.AutoSize = true;
388 | this.linkLabel2.Location = new System.Drawing.Point(20, 95);
389 | this.linkLabel2.Name = "linkLabel2";
390 | this.linkLabel2.Size = new System.Drawing.Size(200, 13);
391 | this.linkLabel2.TabIndex = 25;
392 | this.linkLabel2.TabStop = true;
393 | this.linkLabel2.Text = "Session Manager plugin for the AWS CLI";
394 | this.linkLabel2.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel2_LinkClicked);
395 | //
396 | // linkLabel1
397 | //
398 | this.linkLabel1.AutoSize = true;
399 | this.linkLabel1.Location = new System.Drawing.Point(20, 55);
400 | this.linkLabel1.Name = "linkLabel1";
401 | this.linkLabel1.Size = new System.Drawing.Size(51, 13);
402 | this.linkLabel1.TabIndex = 24;
403 | this.linkLabel1.TabStop = true;
404 | this.linkLabel1.Text = "AWS CLI";
405 | this.linkLabel1.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel1_LinkClicked);
406 | //
407 | // path_config_header
408 | //
409 | this.path_config_header.AutoSize = true;
410 | this.path_config_header.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
411 | this.path_config_header.Location = new System.Drawing.Point(8, 173);
412 | this.path_config_header.Name = "path_config_header";
413 | this.path_config_header.Size = new System.Drawing.Size(159, 20);
414 | this.path_config_header.TabIndex = 23;
415 | this.path_config_header.Text = "Path Configuration";
416 | //
417 | // prerequisites_header
418 | //
419 | this.prerequisites_header.AutoSize = true;
420 | this.prerequisites_header.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
421 | this.prerequisites_header.Location = new System.Drawing.Point(8, 21);
422 | this.prerequisites_header.Name = "prerequisites_header";
423 | this.prerequisites_header.Size = new System.Drawing.Size(114, 20);
424 | this.prerequisites_header.TabIndex = 20;
425 | this.prerequisites_header.Text = "Prerequisites";
426 | //
427 | // rdp_header
428 | //
429 | this.rdp_header.AutoSize = true;
430 | this.rdp_header.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
431 | this.rdp_header.Location = new System.Drawing.Point(8, 422);
432 | this.rdp_header.Name = "rdp_header";
433 | this.rdp_header.Size = new System.Drawing.Size(139, 20);
434 | this.rdp_header.TabIndex = 18;
435 | this.rdp_header.Text = "RDP Auto-Login";
436 | //
437 | // rdp_password_header
438 | //
439 | this.rdp_password_header.AutoSize = true;
440 | this.rdp_password_header.Location = new System.Drawing.Point(397, 452);
441 | this.rdp_password_header.Name = "rdp_password_header";
442 | this.rdp_password_header.Size = new System.Drawing.Size(53, 13);
443 | this.rdp_password_header.TabIndex = 17;
444 | this.rdp_password_header.Text = "Password";
445 | //
446 | // rdp_password
447 | //
448 | this.rdp_password.Location = new System.Drawing.Point(401, 475);
449 | this.rdp_password.Name = "rdp_password";
450 | this.rdp_password.PasswordChar = '*';
451 | this.rdp_password.Size = new System.Drawing.Size(342, 20);
452 | this.rdp_password.TabIndex = 16;
453 | //
454 | // rdp_username
455 | //
456 | this.rdp_username.Location = new System.Drawing.Point(8, 475);
457 | this.rdp_username.Name = "rdp_username";
458 | this.rdp_username.Size = new System.Drawing.Size(342, 20);
459 | this.rdp_username.TabIndex = 15;
460 | //
461 | // rdp_username_header
462 | //
463 | this.rdp_username_header.AutoSize = true;
464 | this.rdp_username_header.Location = new System.Drawing.Point(8, 452);
465 | this.rdp_username_header.Name = "rdp_username_header";
466 | this.rdp_username_header.Size = new System.Drawing.Size(55, 13);
467 | this.rdp_username_header.TabIndex = 14;
468 | this.rdp_username_header.Text = "Username";
469 | //
470 | // button4
471 | //
472 | this.button4.Location = new System.Drawing.Point(749, 360);
473 | this.button4.Name = "button4";
474 | this.button4.Size = new System.Drawing.Size(47, 26);
475 | this.button4.TabIndex = 13;
476 | this.button4.Text = "...";
477 | this.button4.UseVisualStyleBackColor = true;
478 | //
479 | // conemu_install_location
480 | //
481 | this.conemu_install_location.Location = new System.Drawing.Point(10, 360);
482 | this.conemu_install_location.Name = "conemu_install_location";
483 | this.conemu_install_location.ReadOnly = true;
484 | this.conemu_install_location.Size = new System.Drawing.Size(733, 20);
485 | this.conemu_install_location.TabIndex = 12;
486 | //
487 | // label5
488 | //
489 | this.label5.AutoSize = true;
490 | this.label5.Location = new System.Drawing.Point(6, 337);
491 | this.label5.Name = "label5";
492 | this.label5.Size = new System.Drawing.Size(238, 13);
493 | this.label5.TabIndex = 11;
494 | this.label5.Text = "ConEmu - Path to ConEmu64.exe is auto-prefilled";
495 | //
496 | // save_button
497 | //
498 | this.save_button.Location = new System.Drawing.Point(12, 566);
499 | this.save_button.Name = "save_button";
500 | this.save_button.Size = new System.Drawing.Size(110, 38);
501 | this.save_button.TabIndex = 10;
502 | this.save_button.Text = "Save";
503 | this.save_button.UseVisualStyleBackColor = true;
504 | this.save_button.Click += new System.EventHandler(this.button3_Click);
505 | //
506 | // button2
507 | //
508 | this.button2.Location = new System.Drawing.Point(749, 293);
509 | this.button2.Name = "button2";
510 | this.button2.Size = new System.Drawing.Size(47, 26);
511 | this.button2.TabIndex = 9;
512 | this.button2.Text = "...";
513 | this.button2.UseVisualStyleBackColor = true;
514 | this.button2.Click += new System.EventHandler(this.button2_Click_3);
515 | //
516 | // button1
517 | //
518 | this.button1.Location = new System.Drawing.Point(749, 229);
519 | this.button1.Name = "button1";
520 | this.button1.Size = new System.Drawing.Size(47, 26);
521 | this.button1.TabIndex = 8;
522 | this.button1.Text = "...";
523 | this.button1.UseVisualStyleBackColor = true;
524 | this.button1.Click += new System.EventHandler(this.button1_Click);
525 | //
526 | // winscp_install_location
527 | //
528 | this.winscp_install_location.Location = new System.Drawing.Point(10, 293);
529 | this.winscp_install_location.Name = "winscp_install_location";
530 | this.winscp_install_location.ReadOnly = true;
531 | this.winscp_install_location.Size = new System.Drawing.Size(733, 20);
532 | this.winscp_install_location.TabIndex = 7;
533 | //
534 | // environment_config_location
535 | //
536 | this.environment_config_location.Location = new System.Drawing.Point(10, 229);
537 | this.environment_config_location.Name = "environment_config_location";
538 | this.environment_config_location.ReadOnly = true;
539 | this.environment_config_location.Size = new System.Drawing.Size(733, 20);
540 | this.environment_config_location.TabIndex = 6;
541 | //
542 | // label4
543 | //
544 | this.label4.AutoSize = true;
545 | this.label4.Location = new System.Drawing.Point(6, 270);
546 | this.label4.Name = "label4";
547 | this.label4.Size = new System.Drawing.Size(390, 13);
548 | this.label4.TabIndex = 1;
549 | this.label4.Text = "WinSCP - Path to Executable (e.g. C:\\Program Files (x86)\\WinSCP\\WinSCP.exe)";
550 | //
551 | // label3
552 | //
553 | this.label3.AutoSize = true;
554 | this.label3.Location = new System.Drawing.Point(6, 206);
555 | this.label3.Name = "label3";
556 | this.label3.Size = new System.Drawing.Size(327, 13);
557 | this.label3.TabIndex = 0;
558 | this.label3.Text = "AWS - Environment Config (e.g. C:\\Users\\user_id\\.aws\\credentials)";
559 | //
560 | // region_comboBox
561 | //
562 | this.region_comboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
563 | this.region_comboBox.Font = new System.Drawing.Font("Microsoft Sans Serif", 13F, System.Drawing.FontStyle.Bold);
564 | this.region_comboBox.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
565 | this.region_comboBox.FormattingEnabled = true;
566 | this.region_comboBox.ImeMode = System.Windows.Forms.ImeMode.NoControl;
567 | this.region_comboBox.Items.AddRange(new object[] {
568 | "US East (Ohio)",
569 | "US East (N. Virginia)",
570 | "US West (N. California)",
571 | "US West (Oregon)",
572 | "Africa (Cape Town)",
573 | "Asia Pacific (Hong Kong)",
574 | "Asia Pacific (Mumbai)",
575 | "Asia Pacific (Osaka)",
576 | "Asia Pacific (Seoul)",
577 | "Asia Pacific (Singapore)",
578 | "Asia Pacific (Sydney)",
579 | "Asia Pacific (Tokyo)",
580 | "Canada (Central)",
581 | "China (Beijing)",
582 | "China (Ningxia)",
583 | "Europe (Frankfurt)",
584 | "Europe (Ireland)",
585 | "Europe (London)",
586 | "Europe (Milan)",
587 | "Europe (Paris)",
588 | "Europe (Stockholm)",
589 | "Middle East (Bahrain)",
590 | "South America (São Paulo)"});
591 | this.region_comboBox.Location = new System.Drawing.Point(284, 6);
592 | this.region_comboBox.Name = "region_comboBox";
593 | this.region_comboBox.Size = new System.Drawing.Size(272, 28);
594 | this.region_comboBox.TabIndex = 16;
595 | this.region_comboBox.SelectedIndexChanged += new System.EventHandler(this.region_comboBox_SelectedIndexChanged);
596 | //
597 | // Form1
598 | //
599 | this.AccessibleName = "Form1";
600 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
601 | this.ClientSize = new System.Drawing.Size(1108, 729);
602 | this.Controls.Add(this.app__tabControl);
603 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
604 | this.MaximizeBox = false;
605 | this.MaximumSize = new System.Drawing.Size(1124, 768);
606 | this.MinimumSize = new System.Drawing.Size(1124, 768);
607 | this.Name = "Form1";
608 | this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
609 | this.Text = "AWS Connect Manager for Windows";
610 | this.app__tabControl.ResumeLayout(false);
611 | this.app_tabPage_aws.ResumeLayout(false);
612 | this.app_tabPage_aws.PerformLayout();
613 | this.app_tabPage_configuration.ResumeLayout(false);
614 | this.app_tabPage_configuration.PerformLayout();
615 | this.statusStrip1.ResumeLayout(false);
616 | this.statusStrip1.PerformLayout();
617 | this.ResumeLayout(false);
618 |
619 | }
620 |
621 | #endregion
622 | private System.Windows.Forms.ComboBox select_profile_comboBox;
623 | private System.Windows.Forms.ListView aws_instance_list;
624 | private System.Windows.Forms.ColumnHeader InstanceTag;
625 |
626 | private System.Windows.Forms.ColumnHeader InstanceId;
627 | private System.Windows.Forms.ColumnHeader PrivateIpAddress;
628 | private System.Windows.Forms.ColumnHeader InstanceType;
629 | private System.Windows.Forms.ColumnHeader PlatformDetails;
630 | private System.Windows.Forms.Button connect_button;
631 | private System.Windows.Forms.Label instance_count;
632 | private System.Windows.Forms.TextBox copy_instance_id_textBox;
633 | private System.Windows.Forms.ColumnHeader AvailabilityZone;
634 | private System.Windows.Forms.TextBox copy_ip_address_textBox;
635 | private System.Windows.Forms.CheckBox show_running_checkBox;
636 | private System.Windows.Forms.RadioButton winscp_radio_button;
637 | private System.Windows.Forms.RadioButton aws_ssm_radio_button;
638 | private System.Windows.Forms.Label label1;
639 | private System.Windows.Forms.Label label2;
640 | private System.Windows.Forms.ToolTip toolTip1;
641 | private System.Windows.Forms.TabControl app__tabControl;
642 | private System.Windows.Forms.TabPage app_tabPage_aws;
643 | private System.Windows.Forms.TabPage app_tabPage_configuration;
644 | private System.Windows.Forms.TextBox winscp_install_location;
645 | private System.Windows.Forms.TextBox environment_config_location;
646 | private System.Windows.Forms.Label label4;
647 | private System.Windows.Forms.Label label3;
648 | private System.Windows.Forms.Button button2;
649 | private System.Windows.Forms.Button button1;
650 | private System.Windows.Forms.Button save_button;
651 | private System.Windows.Forms.Button button4;
652 | private System.Windows.Forms.TextBox conemu_install_location;
653 | private System.Windows.Forms.Label label5;
654 | private System.Windows.Forms.TextBox rdp_username;
655 | private System.Windows.Forms.Label rdp_username_header;
656 | private System.Windows.Forms.Label rdp_password_header;
657 | private System.Windows.Forms.TextBox rdp_password;
658 | private System.Windows.Forms.Label rdp_header;
659 | private System.Windows.Forms.Label path_config_header;
660 | private System.Windows.Forms.Label label11;
661 | private System.Windows.Forms.Label prerequisites_header;
662 | private System.Windows.Forms.LinkLabel linkLabel2;
663 | private System.Windows.Forms.LinkLabel linkLabel1;
664 | private System.Windows.Forms.LinkLabel linkLabel3;
665 | private System.Windows.Forms.LinkLabel linkLabel4;
666 | private System.Windows.Forms.StatusStrip statusStrip1;
667 | private System.Windows.Forms.ToolStripStatusLabel toolStripStatusLabel1;
668 | private System.Windows.Forms.TextBox sli_ssm_command;
669 | private System.Windows.Forms.Label label6;
670 | private System.Windows.Forms.ComboBox region_comboBox;
671 | }
672 | }
673 |
674 |
--------------------------------------------------------------------------------