Compare commits
14 Commits
1.77.2
...
bug/ssh_fo
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7305bc4441 | ||
|
|
2c47c857ec | ||
|
|
19f1770eda | ||
|
|
40e878a517 | ||
|
|
d09e9b10a0 | ||
|
|
0d727338f0 | ||
|
|
e9838960fa | ||
|
|
74611e9db6 | ||
|
|
f7dc0918eb | ||
|
|
26d9e3c2ff | ||
|
|
53c534aa93 | ||
|
|
dfd02e7b9a | ||
|
|
65eac21471 | ||
|
|
5f776a3525 |
24
.github/CONTRIBUTING.md
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
**Hello, and welcome to the mRemoteNG project!**
|
||||
|
||||
Open source software is best when shared with others. This also applies to the work that goes into the software. Your ideas and passion are what make this software great!
|
||||
There are many ways that you can help improve mRemoteNG, even if you don't know how to program:
|
||||
|
||||
- add documentation or "how-to" articles on the Wiki
|
||||
- answer support questions on the forum
|
||||
- add or improve a translation
|
||||
- submit a pull request for a bug or feature ticket
|
||||
|
||||
The GitHub Issue tracker is our preferred channel for bug reports and feature requests.
|
||||
For questions or general discussion, please use [our public Gitter chat](https://gitter.im/mRemoteNG/PublicChat) or the [forum](http://forum.mremoteng.org).
|
||||
|
||||
If you find a security vulnerability, do **NOT** open an issue. Email security@mremoteng.org instead.
|
||||
|
||||
You'll find all information on our GitHub workflow in our [Wiki](https://github.com/mRemoteNG/mRemoteNG/wiki), or you can use these links:
|
||||
|
||||
- [Branches](https://github.com/mRemoteNG/mRemoteNG/wiki/Branches)
|
||||
- [Bug Repots](https://github.com/mRemoteNG/mRemoteNG/wiki/Bug-Reports)
|
||||
- [Feature Requests](https://github.com/mRemoteNG/mRemoteNG/wiki/Feature-Requests)
|
||||
- [Pull Requests](https://github.com/mRemoteNG/mRemoteNG/wiki/Pull-Requests)
|
||||
|
||||
Want to help but don't know where to start? Check out the issues that we've labeled with [`Help Wanted`](https://github.com/mRemoteNG/mRemoteNG/issues?q=is%3Aissue+is%3Aopen+label%3A%22Help+Wanted%22) or [`ready`](https://github.com/mRemoteNG/mRemoteNG/issues?utf8=%E2%9C%93&q=is%3Aissue%20is%3Aopen%20label%3A%22ready%22). These will vary in difficulty, but should be possible for new contributors.
|
||||
Even if you don't know C# you can heck out the issues that we've labeled with [`Documentation`](https://github.com/mRemoteNG/mRemoteNG/labels/Documentation).
|
||||
30
.github/ISSUE_TEMPLATE.md
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
<!--- Provide a general summary of the issue in the Title above -->
|
||||
|
||||
## Expected Behavior
|
||||
<!--- If you're describing a bug, tell us what should happen -->
|
||||
<!--- If you're suggesting a change/improvement, tell us how it should work -->
|
||||
|
||||
## Current Behavior
|
||||
<!--- If describing a bug, tell us what happens instead of the expected behavior -->
|
||||
<!--- If suggesting a change/improvement, explain the difference from current behavior -->
|
||||
|
||||
## Possible Solution
|
||||
<!--- Not obligatory, but suggest a fix/reason for the bug, -->
|
||||
<!--- or ideas how to implement the addition or change -->
|
||||
|
||||
## Steps to Reproduce (for bugs)
|
||||
<!--- Provide an unambiguous set of steps to reproduce -->
|
||||
<!--- this bug. Include code to reproduce, if relevant -->
|
||||
1.
|
||||
2.
|
||||
3.
|
||||
4.
|
||||
|
||||
## Context
|
||||
<!--- How has this issue affected you? What are you trying to accomplish? -->
|
||||
<!--- Providing context helps us come up with a solution that is most useful in the real world -->
|
||||
|
||||
## Your Environment
|
||||
<!--- Include as many relevant details about the environment you experienced the bug in -->
|
||||
* Version used:
|
||||
* Operating System and version (e.g. Windows 10 1709 x64):
|
||||
32
.github/PULL_REQUEST_TEMPLATE.md
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
<!--- Provide a general summary of your changes in the Title above -->
|
||||
|
||||
## Description
|
||||
<!--- Describe your changes in detail -->
|
||||
|
||||
## Motivation and Context
|
||||
<!--- Why is this change required? What problem does it solve? -->
|
||||
<!--- If it fixes an open issue, please link to the issue here. -->
|
||||
|
||||
## How Has This Been Tested?
|
||||
<!--- Please describe in detail how you tested your changes. -->
|
||||
<!--- Include details of your testing environment, and the tests you ran to -->
|
||||
<!--- see how your change affects other areas of the code, etc. -->
|
||||
|
||||
## Screenshots (if appropriate):
|
||||
|
||||
## Types of changes
|
||||
<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->
|
||||
- [ ] Bug fix (non-breaking change which fixes an issue)
|
||||
- [ ] New feature (non-breaking change which adds functionality)
|
||||
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
|
||||
- [ ] Updated translation
|
||||
|
||||
## Checklist:
|
||||
<!--- Go over all the following points, and put an `x` in all the boxes that apply. -->
|
||||
<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->
|
||||
- [ ] I have read the **CONTRIBUTING** document.
|
||||
- [ ] My code follows the code style of this project.
|
||||
- [ ] This pull request does not target the master branch.
|
||||
- [ ] I have updated the changelog file accordingly.
|
||||
- [ ] My change requires a change to the documentation.
|
||||
- [ ] I have updated the documentation accordingly.
|
||||
|
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 3.1 KiB |
37
CHANGELOG.md
@@ -5,56 +5,19 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
|
||||
## [Unreleased]
|
||||
### Added
|
||||
- #1427: Fix RDP local desktop scale not taking effect on remote
|
||||
- #1770: Added missing RDP performance settings
|
||||
- #1332: Added option to hide menu strip container
|
||||
- #545: Option to minimize to system tray on closing
|
||||
- #420: SSH tunneling implemented
|
||||
- #319: Override quick connect username when using user@domain
|
||||
- #283: Support for native PowerShell remoting as new protocol
|
||||
- #1850: Minify config xml
|
||||
### Changed
|
||||
- #1777: Cleaned up VisualStudio project structure
|
||||
- #1767: Turned about window into a simple popup form
|
||||
- #1766: Converted components check page into options page
|
||||
- #1690: Replaced GeckoFX (Firefox) with CefSharp (Chromium)
|
||||
- #1325: Language resource files cleanup
|
||||
### Fixed
|
||||
- #1783: Added missing inheritance properties to SQL scripts
|
||||
- #1773: Connection issue with mysql - Missing fields in
|
||||
- #1756: Cannot type any character on MultiSSH toolbar
|
||||
- #1720: Show configuration file name in title of password prompt form
|
||||
- #1713: Sound redirection does not work if Clipboard redirection is set to No
|
||||
- #1632: 1.77.1 breaks RDP drive and sound redirection
|
||||
- #1610: Menu bar changes to english when cancelling options form
|
||||
- #1595: Unhandled exception when trying to browse through non existent multi ssh history with keyboard key strokes
|
||||
- #1589: Update SQL tables instead of rewriting them
|
||||
- #1465: REGRESSION: Smart Cards redirection to Remote Desktop not working
|
||||
- #1337: Unhandled exception after closing mRemoteNG
|
||||
- #359: Making a VNC connection to an unreachable host causes the application to not respond for 20-30 seconds
|
||||
|
||||
## [1.77.1] - 2019-09-02
|
||||
### Added
|
||||
- #1512: Added option to close panel from right click menu
|
||||
- #1434: Revised sort button in connection tree to be able to sort in both orders
|
||||
- #1400: Added file download handling to HTTP(S) connections using Gecko
|
||||
- #1385: Added option to start mRemoteNG minimized
|
||||
- #826: Allow selecting RDP version to use when connecting
|
||||
### Changed
|
||||
- #1544: Improved Polish translations
|
||||
- #1518: Inheritance is no longer automatically enabled when importing nodes from Active Directory
|
||||
- #1468: Improved mRemoteNG startup time
|
||||
- #1443: Chinese (simplified) translation improvements
|
||||
- #1437: Norwegian translation improvements
|
||||
- #1378: Hyperlinks embedded within mRemoteNG now open in the system default browser
|
||||
- #1239: Increased default key derivation function (KDF) iterations from 1000 to 10000
|
||||
- #718: Moved port property from 'protocol' to 'connection' section
|
||||
- Moved most RDP enums outside of the RDP protocol class. Scripts which reference these enums will need to be updated.
|
||||
- Removed the "Automatically get session info" from the advanced options screen since it is no longer used.
|
||||
### Fixed
|
||||
- #1505: About screen now better follows theme colors
|
||||
- #1493: Updated database setup scripts for MSSQL and MySQL
|
||||
- #1470: The "Favorite" setting is now properly saved in the local connection settings file (not saved in database)
|
||||
- #1447: Exception occurs when resetting layout
|
||||
- #1439: Searching in hosts tree loses first keystroke
|
||||
- #1428: Fixed a rare error when checking for FIPS
|
||||
|
||||
207
CREDITS.md
@@ -1,39 +1,37 @@
|
||||
# Contributors
|
||||
|
||||
## Current mRemoteNG dev team
|
||||
David Sparer (github.com/sparerd)
|
||||
Sean Kaim (github.com/kmscode)
|
||||
Faryan Rezagholi (github.com/farosch)
|
||||
|
||||
[David Sparer](http://github.com/sparerd)
|
||||
[Sean Kaim](http://github.com/kmscode)
|
||||
[Faryan Rezagholi](http://github.com/farosch)
|
||||
[Bennett Blodinger](http://github.com/benwa)
|
||||
Thanks for the awesome new website!
|
||||
Bennett Blodinger (github.com/benwa)
|
||||
|
||||
[Joe Cefoli](http://github.com/jcefoli)
|
||||
[countchappy](http://github.com/countchappy)
|
||||
Joe Cefoli (github.com/jcefoli)
|
||||
countchappy (github.com/countchappy)
|
||||
Tony Lambert
|
||||
[Julien Roncaglia](http://github.com/vbfox)
|
||||
[peterchenadded](http://github.com/peterchenadded)
|
||||
[Brandon Wulf](http://github.com/mrwulf)
|
||||
[Pedro Rodrigues](http://github.com/pedro2555)
|
||||
[dekelMP](http://github.com/dekelMP)
|
||||
[Bruce](http://github.com/brucetp)
|
||||
[Camilo Alvarez](http://github.com/jotatsu)
|
||||
[DamianBis](http://github.com/DamianBis)
|
||||
[pfjason](http://github.com/pfjason)
|
||||
[sirLoaf](http://github.com/sirLoaf)
|
||||
[Fyers](http://github.com/Fyers)
|
||||
[Vladimir Semenov](http://github.com/sli-pro)
|
||||
[Stephan](http://github.com/st-schuler)
|
||||
[Aleksey Reytsman](http://github.com/areytsman)
|
||||
[Cristian Abelleira](http://github.com/CrAbelleira)
|
||||
[MitchellBot](http://github.com/MitchellBot)
|
||||
[Filippo Ferrazini](http://github.com/Filippo125)
|
||||
Julien Roncaglia (github.com/vbfox)
|
||||
github.com/peterchenadded
|
||||
Brandon Wulf (github.com/mrwulf)
|
||||
Pedro Rodrigues (github.com/pedro2555)
|
||||
github.com/dekelMP
|
||||
Bruce (github.com/brucetp)
|
||||
Camilo Alvarez (github.com/jotatsu)
|
||||
github.com/DamianBis
|
||||
github.com/pfjason
|
||||
github.com/sirLoaf
|
||||
github.com/Fyers
|
||||
Vladimir Semenov (github.com/sli-pro)
|
||||
Stephan (github.com/st-schuler)
|
||||
Aleksey Reytsman (github.com/areytsman)
|
||||
Cristian Abelleira (github.com/CrAbelleira)
|
||||
github.com/MitchellBot
|
||||
|
||||
## Past Contributors
|
||||
|
||||
Felix Deimel - mRemote original developer
|
||||
Riley McArdle - mRemoteNG original developer
|
||||
|
||||
[Hayato Iriumi](http://github.com/hiriumi)
|
||||
Hayato Iriumi (github.com/hiriumi)
|
||||
Jason Barbier
|
||||
Wiktor Beryt
|
||||
Lionel Caignec
|
||||
@@ -43,85 +41,102 @@ Tom Hiller
|
||||
Apisitt Rattana
|
||||
Andreas Rehm
|
||||
David Vidmar
|
||||
[Brandhor](http://github.com/Brandhor)
|
||||
[Dimitrij](http://github.com/Kvarkas)
|
||||
github.com/Brandhor
|
||||
Dimitrij (github.com/Kvarkas)
|
||||
|
||||
## Translators
|
||||
|
||||
Eugenio "Ryo567" Martínez
|
||||
Mathieu Pape
|
||||
Emanuel Silva
|
||||
Robert Siwiec
|
||||
Hayato Iriumi
|
||||
[Sebastien Thieury](http://github.com/SebThieu)
|
||||
Sebastien Thieury (github.com/SebThieu)
|
||||
Riza Emet
|
||||
[Lukas Plachy](http://github.com/rheingold)
|
||||
Lukas Plachy (github.com/rheingold)
|
||||
Gyuha Shin
|
||||
[Stefan](http://github.com/polluks)
|
||||
[emazv72](http://github.com/emazv72)
|
||||
[Vladimir Semenov](http://github.com/sli-pro)
|
||||
[Marco Sousa](http://github.com/marcomsousa)
|
||||
[wwj402](http://github.com/wwj402)
|
||||
[Fyers](http://github.com/Fyers)
|
||||
[pablomh](http://github.com/pablomh)
|
||||
[Damian Szczepanik](http://github.com/damianszczepanik)
|
||||
[Mant1kor](http://github.com/Mant1kor)
|
||||
Stefan (github.com/polluks)
|
||||
github.com/emazv72
|
||||
Vladimir Semenov (github.com/sli-pro)
|
||||
Marco Sousa (github.com/marcomsousa)
|
||||
github.com/wwj402
|
||||
github.com/Fyers
|
||||
github.com/pablomh
|
||||
|
||||
# Included Source Code
|
||||
|
||||
**[Command Line Arguments Parser](http://www.codeproject.com/KB/recipes/command_line.aspx)**
|
||||
## Included Source Code
|
||||
Command Line Arguments Parser
|
||||
Copyright © 2002 Richard Lopes
|
||||
MIT License
|
||||
|
||||
**[FilteredPropertyGrid](http://www.codeproject.com/KB/cs/FilteredPropertyGrid.aspx)**
|
||||
Copyright © 2006 Azuria
|
||||
|
||||
**[InputBox](http://www.csharp-examples.net/inputbox/)**
|
||||
Copyright © 2016 Jan Slama
|
||||
|
||||
**[IP TextBox](http://www.codeproject.com/Articles/11576/IP-TextBox)**
|
||||
Copyright © 2005 mawnkay
|
||||
|
||||
**[PortableSettingsProvider](https://github.com/crdx/PortableSettingsProvider)**
|
||||
Copyright © 2014 crdx
|
||||
|
||||
**[ADTree](http://www.codeproject.com/KB/selection/ADPickerCtrl.aspx)**
|
||||
Copyright © 2004 Marc Merritt © 2008 Felix Deimel
|
||||
|
||||
# Included Components
|
||||
|
||||
**[CefSharp](https://github.com/cefsharp/CefSharp)**
|
||||
Copyright © The CefSharp Authors
|
||||
MIT License
|
||||
|
||||
**[DockPanel Suite](https://github.com/dockpanelsuite/dockpanelsuite)**
|
||||
Copyright © 2018 @roken and @lextm (formerly Weifen Luo)
|
||||
MIT License
|
||||
|
||||
**[log4net](http://logging.apache.org/log4net/)**
|
||||
Copyright © 2001-2015 The Apache Software Foundation
|
||||
Apache License Version 2.0
|
||||
|
||||
**[PuTTY](http://www.chiark.greenend.org.uk/~sgtatham/putty/)**
|
||||
Copyright © 1997-2017 Simon Tatham
|
||||
MIT License
|
||||
|
||||
**[Silk Icon Set](http://www.famfamfam.com/)**
|
||||
Copyright © 2005-2008 FAMFAMFAM
|
||||
Creative Commons Attribution 2.5 License
|
||||
|
||||
**[SSH.NET](https://github.com/sshnet/SSH.NET)**
|
||||
Copyright © 2016
|
||||
MIT License
|
||||
|
||||
**[VncSharp](https://github.com/humphd/VncSharp) (Archived)**
|
||||
Copyright © 2004-2009 David Humphrey
|
||||
GNU General Public License (GPL) Version 2
|
||||
|
||||
**[ObjectListView](https://sourceforge.net/projects/objectlistview/)**
|
||||
Copyright © 2006-2016 Phillip Piper
|
||||
GNU General Public License (GPL) Version 3
|
||||
|
||||
**[ConsoleControl](https://github.com/dwmkerr/consolecontrol)**
|
||||
Copyright © 2015 Dave Kerr
|
||||
MIT License
|
||||
http://www.codeproject.com/KB/recipes/command_line.aspx
|
||||
|
||||
FilteredPropertyGrid
|
||||
Copyright © 2006 Azuria
|
||||
http://www.codeproject.com/KB/cs/FilteredPropertyGrid.aspx
|
||||
|
||||
InputBox
|
||||
Copyright © 2016 Jan Slama
|
||||
http://www.csharp-examples.net/inputbox/
|
||||
|
||||
IP TextBox
|
||||
Copyright © 2005 mawnkay
|
||||
http://www.codeproject.com/Articles/11576/IP-TextBox
|
||||
|
||||
PortableSettingsProvider
|
||||
Copyright © 2014 crdx
|
||||
https://github.com/crdx/PortableSettingsProvider
|
||||
|
||||
|
||||
## Included Components
|
||||
ADTree
|
||||
Copyright © 2004 Marc Merritt
|
||||
Copyright © 2008 Felix Deimel
|
||||
http://www.codeproject.com/KB/selection/ADPickerCtrl.aspx
|
||||
|
||||
DockPanel Suite
|
||||
Copyright © 2018 @roken and @lextm (formerly Weifen Luo)
|
||||
MIT License
|
||||
https://github.com/dockpanelsuite/dockpanelsuite
|
||||
|
||||
GeckoFX
|
||||
Copyright © 2016 Tom Hindle
|
||||
Mozilla Public License
|
||||
https://bitbucket.org/geckofx/
|
||||
|
||||
log4net
|
||||
Copyright © 2001-2015 The Apache Software Foundation
|
||||
Apache License Version 2.0
|
||||
http://logging.apache.org/log4net/
|
||||
|
||||
Magic Library
|
||||
Copyright © 2002-2003 Crownwood Consulting, Ltd.
|
||||
Freely redistributable with attribution
|
||||
http://www.dotnetmagic.com/magic_download.html
|
||||
|
||||
PuTTY
|
||||
Copyright © 1997-2017 Simon Tatham
|
||||
MIT License
|
||||
http://www.chiark.greenend.org.uk/~sgtatham/putty/
|
||||
|
||||
Silk Icon Set
|
||||
Copyright © 2005-2008 FAMFAMFAM
|
||||
Creative Commons Attribution 2.5 License
|
||||
http://www.famfamfam.com/
|
||||
|
||||
SSH.NET
|
||||
Copyright © 2016
|
||||
MIT License
|
||||
https://github.com/sshnet/SSH.NET
|
||||
|
||||
VncSharp
|
||||
Copyright © 2004-2009 David Humphrey
|
||||
GNU General Public License (GPL) Version 2
|
||||
https://github.com/humphd/VncSharp
|
||||
|
||||
ObjectListView
|
||||
Copyright © 2006-2016 Phillip Piper
|
||||
GNU General Public License (GPL) Version 3
|
||||
https://sourceforge.net/projects/objectlistview/
|
||||
|
||||
Markdig
|
||||
Copyright © 2016-2019 Alexandre Mutel
|
||||
BSD 2-Clause "Simplified"
|
||||
https://github.com/lunet-io/markdig
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
|
||||
@@ -10,7 +10,7 @@
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>CustomActions</RootNamespace>
|
||||
<AssemblyName>CustomActions</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||
<TargetFrameworkVersion>v2.0</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<WixCATargetsPath Condition=" '$(WixCATargetsPath)' == '' ">$(MSBuildExtensionsPath)\Microsoft\WiX\v3.x\Wix.CA.targets</WixCATargetsPath>
|
||||
<TargetFrameworkProfile />
|
||||
@@ -23,7 +23,6 @@
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
@@ -32,7 +31,6 @@
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<Prefer32Bit>false</Prefer32Bit>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<StartupObject>
|
||||
@@ -1,4 +1,5 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
@@ -2,8 +2,8 @@
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||
<?include $(sys.CURRENTDIR)Includes\Config.wxi?>
|
||||
<Fragment>
|
||||
<Component Id="C.MainExe" Directory="INSTALLDIR" Guid="a028ee50-3135-46c7-83c0-1d14d36e146c">
|
||||
<File Id="MainExeFile" Source="$(var.SolutionDir)mRemoteNG\bin\$(var.Configuration)\mRemoteNG.exe" />
|
||||
<Component Id="C.MainExe" Directory="INSTALLDIR" Guid="*">
|
||||
<File Id="MainExeFile" Source="$(var.SolutionDir)mRemoteV1\bin\$(var.Configuration)\mRemoteNG.exe" />
|
||||
</Component>
|
||||
</Fragment>
|
||||
</Wix>
|
||||
@@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||
<Fragment>
|
||||
<ComponentGroup Id="CG.ProjectInfoFiles" Directory="INSTALLDIR">
|
||||
<Component Id="C.Changelog" Guid="*">
|
||||
<File Id="ChangelogFile" Name="Changelog.txt" Source="$(var.SolutionDir)CHANGELOG.md" KeyPath="yes" />
|
||||
</Component>
|
||||
<Component Id="C.Credits" Guid="*">
|
||||
<File Id="CreditsFile" Name="Credits.txt" Source="$(var.SolutionDir)CREDITS.md" KeyPath="yes" />
|
||||
</Component>
|
||||
<Component Id="C.License" Guid="*">
|
||||
<File Id="LicenseFile" Name="License.txt" Source="$(var.SolutionDir)COPYING.TXT" KeyPath="yes" />
|
||||
</Component>
|
||||
<Component Id="C.Readme" Guid="*">
|
||||
<File Id="ReadmeFile" Name="Readme.txt" Source="$(var.SolutionDir)README.md" KeyPath="yes" />
|
||||
</Component>
|
||||
<Component Id="C.TileManifest" Guid="*">
|
||||
<File Id="TileManifest" Name="mRemoteNG.VisualElementsManifest.xml" Source="$(var.SolutionDir)mRemoteV1\bin\Release\mRemoteNG.VisualElementsManifest.xml" KeyPath="yes" />
|
||||
</Component>
|
||||
</ComponentGroup>
|
||||
</Fragment>
|
||||
</Wix>
|
||||
@@ -2,7 +2,7 @@
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||
<Fragment>
|
||||
<DirectoryRef Id="INSTALLDIR">
|
||||
<Component Id="C.PuttyNGFile" Guid="86bc1cf4-4c51-40a1-a9fe-cf9669bb883a">
|
||||
<Component Id="C.PuttyNGFile" Guid="*">
|
||||
<File Id="PuttyNGFile" Name="PuTTYNG.exe" Source="$(var.HarvestPath)\PuTTYNG.exe" KeyPath="yes" />
|
||||
</Component>
|
||||
</DirectoryRef>
|
||||
@@ -2,7 +2,7 @@
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||
<Fragment>
|
||||
<DirectoryRef Id="TARGETDIR">
|
||||
<Component Id="C.RegistryEntries" Guid="888643e4-4c52-45d3-801a-0d0d71c737fe">
|
||||
<Component Id="C.RegistryEntries" Guid="*">
|
||||
<RegistryKey Root="HKLM" Key="Software\mRemoteNG">
|
||||
<RegistryValue Type="string" Name="InstallDir" Value="[INSTALLDIR]" KeyPath="yes" />
|
||||
</RegistryKey>
|
||||
@@ -14,16 +14,16 @@
|
||||
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
|
||||
<DefineConstants>HarvestPath=..\mRemoteNG\bin\Debug;</DefineConstants>
|
||||
<DefineConstants>HarvestPath=..\mRemoteV1\bin\Debug;</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
|
||||
<DefineConstants>HarvestPath=..\mRemoteNG\bin\Release;</DefineConstants>
|
||||
<DefineConstants>HarvestPath=..\mRemoteV1\bin\Release;</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)' == 'Debug Portable' ">
|
||||
<DefineConstants>HarvestPath=..\mRemoteNG\bin\Debug Portable;</DefineConstants>
|
||||
<DefineConstants>HarvestPath=..\mRemoteV1\bin\Debug Portable;</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)' == 'Release Portable' ">
|
||||
<DefineConstants>HarvestPath=..\mRemoteNG\bin\Release Portable;</DefineConstants>
|
||||
<DefineConstants>HarvestPath=..\mRemoteV1\bin\Release Portable;</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="CustomActions\CheckForInstalledWindowsUpdates.wxs" />
|
||||
@@ -36,7 +36,7 @@
|
||||
<Compile Include="Fragments\PuTTYNGFragment.wxs" />
|
||||
<Compile Include="Fragments\RegistryEntriesFragment.wxs" />
|
||||
<Compile Include="Fragments\ShortcutFragment.wxs" />
|
||||
<Compile Include="mRemoteNG.wxs" />
|
||||
<Compile Include="mRemoteNGV1.wxs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="Filters\Harvest_Filter.xslt" />
|
||||
@@ -73,13 +73,14 @@
|
||||
</WixExtension>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\mRemoteNG\mRemoteNG.csproj">
|
||||
<Name>mRemoteNG</Name>
|
||||
<ProjectReference Include="..\..\mRemoteV1\mRemoteV1.csproj">
|
||||
<Name>mRemoteV1</Name>
|
||||
<Project>{4934a491-40bc-4e5b-9166-ea1169a220f6}</Project>
|
||||
<Private>True</Private>
|
||||
<DoNotHarvest>True</DoNotHarvest>
|
||||
<DoNotHarvest>
|
||||
</DoNotHarvest>
|
||||
<RefProjectOutputGroups>Binaries;Content;Satellites</RefProjectOutputGroups>
|
||||
<RefTargetDir>INSTALLFOLDER</RefTargetDir>
|
||||
<RefTargetDir>APPLICATIONROOTDIRECTORY</RefTargetDir>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(WixTargetsPath)" />
|
||||
@@ -94,19 +95,31 @@
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<LinkerAdditionalOptions>
|
||||
</LinkerAdditionalOptions>
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteNG\bin\Release;HelpFilesHarvestPath=$(SolutionDir)mRemoteNG\Resources\Help</DefineConstants>
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteV1\bin\Release;HelpFilesHarvestPath=$(SolutionDir)mRemoteV1\Resources\Help</DefineConstants>
|
||||
<Cultures>en-US</Cultures>
|
||||
<SuppressPdbOutput>True</SuppressPdbOutput>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||
<Cultures>en-US</Cultures>
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteNG\bin\Debug;HelpFilesHarvestPath=$(SolutionDir)mRemoteNG\Resources\Help</DefineConstants>
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteV1\bin\Debug;HelpFilesHarvestPath=$(SolutionDir)mRemoteV1\Resources\Help</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug Portable|x86' ">
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteNG\bin\Debug Portable;HelpFilesHarvestPath=$(SolutionDir)mRemoteNG\Resources\Help</DefineConstants>
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteV1\bin\Debug Portable;HelpFilesHarvestPath=$(SolutionDir)mRemoteV1\Resources\Help</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release Portable|x86' ">
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteNG\bin\Release Portable;HelpFilesHarvestPath=$(SolutionDir)mRemoteNG\Resources\Help</DefineConstants>
|
||||
<DefineConstants>HarvestPath=$(SolutionDir)mRemoteV1\bin\Release Portable;HelpFilesHarvestPath=$(SolutionDir)mRemoteV1\Resources\Help</DefineConstants>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PreBuildEvent>REM Clean the TargetDir
|
||||
rmdir /S /Q "$(TargetDir)"
|
||||
|
||||
echo $(ConfigurationName) > buildenv.tmp
|
||||
|
||||
REM Harvest bin directory of the mRemoteV1 project
|
||||
"$(WIX)bin\heat.exe" dir "$(SolutionDir)mRemoteV1\bin\$(Configuration)" -ag -nologo -dr INSTALLDIR -var var.HarvestPath -srd -cg MandatoryComponents -template fragment -out "$(ProjectDir)Fragments\FilesFragment.wxs" -t "$(ProjectDir)Filters\Harvest_Filter.xslt"
|
||||
|
||||
REM Convert the license file "COPYING.TXT" to "License.rtf" to be shown in the installer GUI
|
||||
"$(ProjectDir)Resources\Pandoc\pandoc.exe" -s -t rtf -o "$(ProjectDir)\Resources\License.rtf" "$(SolutionDir)COPYING.TXT"</PreBuildEvent>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent>:: When passing paths to powershell scripts, check if the path ends with a backslash "\"
|
||||
@@ -122,16 +135,4 @@ set /p buildenv=<buildenv.tmp
|
||||
:: Call the post build powershell script
|
||||
powershell.exe -ExecutionPolicy Bypass -File "$(SolutionDir)Tools\postbuild_installer.ps1" -SolutionDir "$(SolutionDir)\" -TargetDir "%25cd%25" -TargetFileName "mRemoteNG.exe" -ConfigurationName "%25buildenv%25" -CertificatePath "$(CertPath)" -CertificatePassword "$(CertPassword)" -ExcludeFromSigning "PuTTYNG.exe"</PostBuildEvent>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PreBuildEvent>REM Clean the TargetDir
|
||||
rmdir /S /Q "$(TargetDir)"
|
||||
|
||||
echo $(ConfigurationName) > buildenv.tmp
|
||||
|
||||
REM Harvest bin directory of the mRemoteNG project
|
||||
"$(WIX)bin\heat.exe" dir "$(SolutionDir)mRemoteNG\bin\$(Configuration)" -ag -nologo -dr INSTALLDIR -var var.HarvestPath -srd -scom -sreg -cg MandatoryComponents -template fragment -out "$(ProjectDir)Fragments\FilesFragment.wxs" -t "$(ProjectDir)Filters\Harvest_Filter.xslt"
|
||||
|
||||
REM Convert the license file "COPYING.TXT" to "License.rtf" to be shown in the installer GUI
|
||||
"$(ProjectDir)Resources\Pandoc\pandoc.exe" -s -t rtf -o "$(ProjectDir)\Resources\License.rtf" "$(SolutionDir)COPYING.TXT"</PreBuildEvent>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
Before Width: | Height: | Size: 58 KiB After Width: | Height: | Size: 58 KiB |
|
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 2.3 KiB |
|
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 2.8 KiB |
@@ -9,7 +9,7 @@
|
||||
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
|
||||
<MajorUpgrade DowngradeErrorMessage="!(loc.Upgrade_NewerVersionInstalled)" Schedule="afterInstallExecute" />
|
||||
<MediaTemplate EmbedCab="yes" />
|
||||
<Binary Id="CustomActions.CA.dll" SourceFile="$(var.SolutionDir)mRemoteNGInstaller\CustomActions\bin\$(var.Configuration)\CustomActions.CA.dll" />
|
||||
<Binary Id="CustomActions.CA.dll" SourceFile="$(var.SolutionDir)InstallerProjects\CustomActions\bin\$(var.Configuration)\CustomActions.CA.dll" />
|
||||
<Property Id="MsiLogging" Value="v" />
|
||||
<Property Id="ARPPRODUCTICON" Value="AppIcon.ico" />
|
||||
<Property Id="ARPHELPLINK" Value="http://www.mremoteng.org" />
|
||||
@@ -2,7 +2,7 @@ node('windows') {
|
||||
def jobDir = pwd()
|
||||
def solutionFilePath = "\"${jobDir}\\mRemoteV1.sln\""
|
||||
def msBuild = "C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\MSBuild\\15.0\\Bin\\msbuild.exe"
|
||||
def nunitConsolePath = "${jobDir}\\packages\\NUnit.ConsoleRunner.3.10.0\\tools\\nunit3-console.exe"
|
||||
def nunitConsolePath = "${jobDir}\\packages\\NUnit.ConsoleRunner.3.7.0\\tools\\nunit3-console.exe"
|
||||
def openCoverPath = "${jobDir}\\packages\\OpenCover.4.6.519\\tools\\OpenCover.Console.exe"
|
||||
def testResultFilePrefix = "TestResult"
|
||||
def testResultFileNormal = "${testResultFilePrefix}_UnitTests_normal.xml"
|
||||
|
||||
171
README.MD
@@ -1,169 +1,49 @@
|
||||
**NOTICE: This project is currently stalled and we are transitioning to a new maintainer. Please see [this stickied issue](https://github.com/mRemoteNG/mRemoteNG/issues/1949) for more details. Development help would be greatly appreciated.**
|
||||
# Welcome to the mRemoteNG project!
|
||||
|
||||
<br/><br/>
|
||||
<p align="center">
|
||||
<img width="500" src="https://raw.githubusercontent.com/mRemoteNG/mRemoteNG/develop/Tools/img/logo.png">
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
An open source, multi-protocol, tabbed remote connections manager allowing you to view all of your connections in a simple yet powerful interface
|
||||
</p>
|
||||
[](https://twitter.com/intent/follow?screen_name=mRemoteNG)
|
||||
[](https://gitter.im/mRemoteNG/PublicChat)
|
||||
[](https://www.paypal.me/DavidSparer)
|
||||
|
||||
<p align="center">
|
||||
<img alt="GitHub All Releases" src="https://img.shields.io/github/downloads/mremoteng/mremoteng/total?label=Overall%20Downloads&style=for-the-badge">
|
||||
</p>
|
||||
[](https://github.com/mRemoteNG/mRemoteNG/releases/)
|
||||
|
||||
<p align="center">
|
||||
<a href="https://www.reddit.com/r/mRemoteNG/">
|
||||
<img alt="Subreddit subscribers" src="https://img.shields.io/reddit/subreddit-subscribers/mremoteng?label=Reddit&logo=Reddit&style=flat-square">
|
||||
</a>
|
||||
<a href="https://twitter.com/mremoteng">
|
||||
<img alt="Twitter Follow" src="https://img.shields.io/twitter/follow/mremoteng?color=%231DA1F2&label=Twitter&logo=Twitter&style=flat-square">
|
||||
</a>
|
||||
<a href="https://gitter.im/mRemoteNG/PublicChat">
|
||||
<img alt="Gitter" src="https://img.shields.io/gitter/room/mRemoteNG/PublicChat?label=Join%20the%20Chat&logo=Gitter&style=flat-square">
|
||||
</a>
|
||||
<a href="https://www.paypal.me/DavidSparer">
|
||||
<img alt="PayPal" src="https://img.shields.io/badge/%24-PayPal-blue.svg?label=Donate&logo=PayPal&style=flat-square">
|
||||
</a>
|
||||
<a href="bitcoin:16fUnHUM3k7W9Fvpc6dug7TAdfeGEcLbSg">
|
||||
<img alt="Bitcoin" src="https://img.shields.io/badge/%24-Bitcoin.svg?label=Donate&logo=bitcoin&style=flat-square">
|
||||
</a>
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://github.com/mRemoteNG/mRemoteNG/blob/develop/COPYING.TXT">
|
||||
<img alt="License" src="https://img.shields.io/github/license/mremoteng/mremoteng?label=License&style=flat">
|
||||
</a>
|
||||
<a href="https://bestpractices.coreinfrastructure.org/projects/529">
|
||||
<img alt="CII Best Practices" src="https://bestpractices.coreinfrastructure.org/projects/529/badge?style=flat">
|
||||
</a>
|
||||
<a href='https://mremoteng.readthedocs.io/en/latest/?badge=latest'>
|
||||
<img src='https://readthedocs.org/projects/mremoteng/badge/?version=latest' alt='Documentation Status' />
|
||||
</a>
|
||||
</p>
|
||||
|
||||
---
|
||||
[](https://bestpractices.coreinfrastructure.org/projects/529)
|
||||
[](https://mremoteng.readthedocs.io/en/latest/?badge=latest)
|
||||
|
||||
| Update Channel | Build Status | Downloads |
|
||||
| ---------------|--------------|-----------|
|
||||
| Stable | [](https://ci.appveyor.com/project/mremoteng/mremoteng/branch/master) | [](https://github.com/mRemoteNG/mRemoteNG/releases/tag/v1.76.20) |
|
||||
| Prerelease | [](https://ci.appveyor.com/project/mremoteng/mremoteng/branch/develop) | [](https://github.com/mRemoteNG/mRemoteNG/releases/tag/v1.77.1) |
|
||||
| Stable | [](https://ci.appveyor.com/project/mremoteng/mremoteng/branch/master) | [](https://github.com/mRemoteNG/mRemoteNG/releases/tag/v1.76.15) |
|
||||
| Beta | | [](https://github.com/mRemoteNG/mRemoteNG/releases/tag/v1.76.15) |
|
||||
| Development | [](https://ci.appveyor.com/project/mremoteng/mremoteng/branch/develop) | [](https://github.com/mRemoteNG/mRemoteNG/releases/tag/v1.76.15) |
|
||||
|
||||
mRemoteNG is the next generation of mRemote, a full-featured, multi-tab remote connections manager.
|
||||
|
||||
## Features
|
||||
|
||||
The following protocols are supported:
|
||||
mRemoteNG is a fork of mRemote: an open source, tabbed, multi-protocol, remote connections manager. mRemoteNG adds bug fixes and new features to mRemote.
|
||||
|
||||
* RDP (Remote Desktop Protocol)
|
||||
It allows you to view all of your remote connections in a simple yet powerful tabbed interface.
|
||||
|
||||
mRemoteNG supports the following protocols:
|
||||
|
||||
* RDP (Remote Desktop/Terminal Server)
|
||||
* VNC (Virtual Network Computing)
|
||||
* ICA (Citrix Independent Computing Architecture)
|
||||
* SSH (Secure Shell)
|
||||
* Telnet (TELecommunication NETwork)
|
||||
* HTTP/HTTPS (Hypertext Transfer Protocol)
|
||||
* rlogin (Remote Login)
|
||||
* Raw Socket Connections
|
||||
* Powershell remoting
|
||||
|
||||
For a detailed feature list and general usage support, refer to the [Documentation](https://mremoteng.readthedocs.io/en/latest/).
|
||||
For a detailed feature list and general usage support, refer to the [User Manual](https://github.com/mRemoteNG/mRemoteNG/wiki/User-Manual).
|
||||
|
||||
## Installation
|
||||
|
||||
### Supported Operating Systems
|
||||
mRemoteNG is supported on Windows 7 or later. Before installing make sure you fullfill all the [minimum requirements](https://mremoteng.readthedocs.io/en/latest/installation/minimum_requirements.html).
|
||||
|
||||
- [Windows 10](https://en.wikipedia.org/wiki/Windows_10)
|
||||
- [Windows 8.1](https://en.wikipedia.org/wiki/Windows_8.1)
|
||||
- [Windows Server 2019](https://en.wikipedia.org/wiki/Windows_Server_2019)
|
||||
- [Windows Server 2016](https://en.wikipedia.org/wiki/Windows_Server_2016)
|
||||
- [Windows Server 2012 R2](https://en.wikipedia.org/wiki/Windows_Server_2012_R2)
|
||||
|
||||
### Packaging
|
||||
|
||||
Downloads are provided in three different packages.
|
||||
|
||||
#### Binary package
|
||||
|
||||
The binary package of mRemoteNG is a compiled version of mRemoteNG which comes in an MSI installer.
|
||||
This is the most common way to install mRemoteNG and get up and running.
|
||||
|
||||
#### Portable package
|
||||
|
||||
The portable package contains a modified version of the executable which stores and loads all your settings from files in the application's directory.
|
||||
This package can be used to run mRemoteNG from a USB stick and preserve your configuration wherever you go.
|
||||
|
||||
#### Source package
|
||||
|
||||
This contains the source code from which mRemoteNG is build.
|
||||
You will need to compile it yourself using Visual Studio.
|
||||
|
||||
### Minimum Requirements
|
||||
|
||||
* [Microsoft Visual C++ Redistributable for Visual Studio 2015, 2017 and 2019](https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads)
|
||||
* [Microsoft .NET Framework 4.0](https://www.microsoft.com/en-us/download/details.aspx?id=17851)
|
||||
* Microsoft Terminal Service Client 6.0 or later
|
||||
* Needed if you use RDP. mstscax.dll and/or msrdp.ocx be registered.
|
||||
* [Citrix ICA Client](https://www.citrix.com/downloads/citrix-receiver.html)
|
||||
* Needed if you use ICA. wfica.ocx must be registered
|
||||
|
||||
### Download
|
||||
|
||||
mRemoteNG is available as a redistributable MSI package or as a portable ZIP package and can be downloaded from the following locations:
|
||||
mRemoteNG is available as a redistributable msi package, and can be downloaded from the following locations:
|
||||
* [GitHub](https://github.com/mRemoteNG/mRemoteNG/releases)
|
||||
* [Project Website](https://mremoteng.org/download)
|
||||
|
||||
### Command line install
|
||||
|
||||
The MSI package of mRemoteNG can be installed using the command line:
|
||||
|
||||
`msiexec /i C:\Path\To\mRemoteNG-Installer.exe [INSTALLDIR=value] [IGNOREPREREQUISITES=value]`
|
||||
|
||||
| Property | Value | Description |
|
||||
|-|-|-|
|
||||
| INSTALLDIR | `folder path` | This allows you to set the installation directory from the command line. For paths that contain spaces, enclose the path in double quotes (""). This overrides any value found in the registry. |
|
||||
| IGNOREPREREQUISITES | `0` or `1` | When set to `1`, the installer will not be halted if any prerequisite check is not met. You must still run the installer as administrator. |
|
||||
|
||||
#### Examples
|
||||
|
||||
**Install to a custom folder**
|
||||
|
||||
`msiexec /i C:\Path\To\mRemoteNG-Installer.msi INSTALLDIR="D:\Work Apps\mRemoteNG"`
|
||||
|
||||
**Ignore prerequisites during a normal install**
|
||||
|
||||
`msiexec /i C:\Path\To\mRemoteNG-Installer.msi IGNOREPREREQUISITES=1`
|
||||
|
||||
**Ignore prerequisites during a silent install**
|
||||
|
||||
`msiexec /i C:\Path\To\mRemoteNG-Installer.msi /qn IGNOREPREREQUISITES=1`
|
||||
|
||||
### Troubleshooting installation
|
||||
|
||||
Turn on verbose logging by using the `/lv* <log path>` argument at the command line.
|
||||
|
||||
`msiexec /i C:\Path\To\mRemoteNG-Installer.msi /l*v C:\mremoteng_install.log`
|
||||
|
||||
## Uninstall
|
||||
|
||||
### Standard Uninstall
|
||||
|
||||
mRemoteNG basic binary package can be uninstalled with Windows Control Panel. If for some reason it does not work please
|
||||
follow information provided below for Manual Uninstall.
|
||||
|
||||
### Manual Uninstall
|
||||
|
||||
_If you are using the Portable version, simply deleting the folder that contains mRemoteNG should be sufficient. These uninstall instructions are only necessary for the normal binary .MSI installed version of mRemoteNG_
|
||||
|
||||
* Delete the folder where mRemoteNG was installed. By default, this is:
|
||||
`%PROGRAMFILES%\mRemoteNG`
|
||||
|
||||
* Delete the mRemoteNG install entry from one of the following locations. Search for "mRemoteNG" in the DisplayName field:
|
||||
* x86: ``HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\``
|
||||
* x64: ``HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\``
|
||||
|
||||
* (Optional) If you would also like to delete user data remove `%LOCALAPPDATA%\mRemoteNG`
|
||||
|
||||
## Featured Projects
|
||||
|
||||
* [PSmRemoteNG](https://github.com/realslacker/PSmRemoteNG) A module to create mRemoteNG connection files from PowerShell.
|
||||
|
||||
## Contribute
|
||||
|
||||
If you find mRemoteNG useful and would like to contribute, it would be greatly appreciated. When you contribute, you make it possible for the team to cover the costs of producing mRemoteNG.
|
||||
@@ -172,9 +52,6 @@ If you find mRemoteNG useful and would like to contribute, it would be greatly a
|
||||
Check out the [Wiki page](https://github.com/mRemoteNG/mRemoteNG/wiki) on how to configure your development environment and submit a pull request.
|
||||
|
||||
### Translate
|
||||
Check out the [Wiki page](https://github.com/mRemoteNG/mRemoteNG/wiki) on how to help make mRemoteNG a polyglot.
|
||||
Check out the [Wiki page](https://github.com/mRemoteNG/mRemoteNG/wiki) on how to help make mRemoteNG a polyglot
|
||||
|
||||
</br>
|
||||
<p align="center">
|
||||
<img alt="Developed with ReSharper" src="https://raw.githubusercontent.com/mRemoteNG/mRemoteNG/develop/Tools/img/icon_ReSharper.png">
|
||||
</p>
|
||||
[](https://www.jetbrains.com/resharper/)
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
License for use and distribution
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Copyright (C) 1999-2019 Igor Pavlov.
|
||||
Copyright (C) 1999-2018 Igor Pavlov.
|
||||
|
||||
7-Zip Extra files are under the GNU LGPL license.
|
||||
|
||||
|
||||
@@ -5,21 +5,6 @@ This file contains only information about changes related to that package exclus
|
||||
The full history of changes is listed in history.txt in main 7-Zip program.
|
||||
|
||||
|
||||
19.00 2019-02-21
|
||||
-------------------------
|
||||
- Encryption strength for 7z archives was increased:
|
||||
the size of random initialization vector was increased from 64-bit to 128-bit,
|
||||
and the pseudo-random number generator was improved.
|
||||
- Some bugs were fixed.
|
||||
|
||||
|
||||
18.06 2018-12-30
|
||||
-------------------------
|
||||
- The speed for LZMA/LZMA2 compressing was increased by 3-10%,
|
||||
and there are minor changes in compression ratio.
|
||||
- Some bugs were fixed.
|
||||
|
||||
|
||||
18.05 2018-04-30
|
||||
-------------------------
|
||||
- The speed for LZMA/LZMA2 compressing was increased
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
7-Zip Extra 19.00
|
||||
7-Zip Extra 18.05
|
||||
-----------------
|
||||
|
||||
7-Zip Extra is package of extra modules of 7-Zip.
|
||||
|
||||
7-Zip Copyright (C) 1999-2019 Igor Pavlov.
|
||||
7-Zip Copyright (C) 1999-2018 Igor Pavlov.
|
||||
|
||||
7-Zip is free software. Read License.txt for more information about license.
|
||||
|
||||
|
||||
73
Tools/appveyor_after_build.ps1
Normal file
@@ -0,0 +1,73 @@
|
||||
if([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER)) {
|
||||
Write-Output "NOT running via Appveyor - Exiting"
|
||||
Exit
|
||||
}
|
||||
|
||||
$appvDir = $Env:APPVEYOR_BUILD_FOLDER
|
||||
|
||||
Write-Output "Appveyor Build Dir: '$($appvDir)'"
|
||||
$ConfigurationName = $Env:CONFIGURATION.Trim()
|
||||
Write-Output "Config Name (tirmmed): '$($ConfigurationName)'"
|
||||
|
||||
|
||||
$SIGCHECK="Tools\exes\sigcheck.exe"
|
||||
$SEVENZIP="Tools\7zip\7za.exe"
|
||||
|
||||
if ($ConfigurationName -eq "Release Portable") {
|
||||
Write-Output "Packaging Release Portable ZIP"
|
||||
|
||||
$version = & $SIGCHECK /accepteula -q -n "mRemoteV1\bin\$($ConfigurationName)\mRemoteNG.exe"
|
||||
|
||||
Write-Output "Version is $($version)"
|
||||
|
||||
$PortableZip="Release\mRemoteNG-Portable-$($version).zip"
|
||||
|
||||
Remove-Item -Recurse "mRemoteV1\bin\package" -ErrorAction SilentlyContinue | Out-Null
|
||||
New-Item "mRemoteV1\bin\package" -ItemType "directory" | Out-Null
|
||||
|
||||
Copy-Item "mRemoteV1\Resources\PuTTYNG.exe" -Destination "mRemoteV1\bin\package"
|
||||
|
||||
Copy-Item "mRemoteV1\bin\$ConfigurationName\*" -Destination "mRemoteV1\bin\package" -Recurse -Force -Exclude *.pdb
|
||||
Copy-Item "*.txt" -Destination "mRemoteV1\bin\package"
|
||||
|
||||
Write-Output "Creating portable ZIP file $($PortableZip)"
|
||||
Remove-Item -Force $PortableZip -ErrorAction SilentlyContinue
|
||||
& $SEVENZIP a -bt -bd -bb1 -mx=9 -tzip -y -r $PortableZip ".\mRemoteV1\bin\package\*.*"
|
||||
}
|
||||
else {
|
||||
Write-Output "We will not zip anything - this isnt a portable release build."
|
||||
}
|
||||
|
||||
Write-Output ""
|
||||
Write-Output ""
|
||||
|
||||
if ($ConfigurationName -match "Release" -And $ConfigurationName -ne "Release Installer") {
|
||||
Write-Output "Packaging debug symbols"
|
||||
|
||||
$version = & $SIGCHECK /accepteula -q -n "mRemoteV1\bin\$($ConfigurationName)\mRemoteNG.exe"
|
||||
|
||||
Write-Output "Version is $($version)"
|
||||
|
||||
if ($ConfigurationName -match "Portable") {
|
||||
$zipFilePrefix = "mRemoteNG-Portable-symbols"
|
||||
} else {
|
||||
$zipFilePrefix = "mRemoteNG-symbols"
|
||||
}
|
||||
|
||||
$outputZipPath="Release\$zipFilePrefix-$($version).zip"
|
||||
|
||||
Write-Output "Creating debug symbols ZIP file $($outputZipPath)"
|
||||
Remove-Item -Force $outputZipPath -ErrorAction SilentlyContinue
|
||||
$SymPath = (Join-Path -Path mRemoteV1\bin\$($ConfigurationName) -ChildPath "*.pdb")
|
||||
if(Test-Path "$SymPath") {
|
||||
& $SEVENZIP a -bt -bd -bb1 -mx=9 -tzip -y -r $outputZipPath "$SymPath"
|
||||
} else {
|
||||
Write-Output "No Debugging Symbols Found..."
|
||||
}
|
||||
|
||||
}
|
||||
else {
|
||||
Write-Output "We will not package debug symbols for this configuration $($ConfigurationName)"
|
||||
}
|
||||
|
||||
Write-Output ""
|
||||
83
Tools/appveyor_publish_build.ps1
Normal file
@@ -0,0 +1,83 @@
|
||||
if([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER)) {
|
||||
Write-Output "NOT running via Appveyor - Exiting"
|
||||
Throw "NOT running via Appveyor - Exiting"
|
||||
}
|
||||
|
||||
$appvDir = $Env:APPVEYOR_BUILD_FOLDER
|
||||
|
||||
$SIGCHECK="Tools\exes\sigcheck.exe"
|
||||
$SEVENZIP="Tools\7zip\7za.exe"
|
||||
|
||||
Write-Output "Appveyor Build Dir: '$($appvDir)'"
|
||||
|
||||
Write-Output "Decrypt Cert"
|
||||
& appveyor-tools\secure-file -decrypt "$($Env:cert_path).enc" -secret "$Env:cert_decrypt_pwd"
|
||||
|
||||
if(-Not (Test-Path $Env:cert_path)) {
|
||||
Write-Output "decrypt cert does not exist..."
|
||||
Throw "Could not decrypt cert"
|
||||
}
|
||||
|
||||
Write-Output "Restoring NuGets"
|
||||
& nuget restore
|
||||
|
||||
|
||||
Write-Output "Build Release Installer"
|
||||
& msbuild "$($appvDir)\mRemoteV1.sln" /nologo /t:Clean,Build /p:Configuration="Release Installer" /p:Platform=x86 /p:CertPath="$($Env:cert_path)" /p:CertPassword="$Env:cert_pwd" /m /verbosity:normal /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
|
||||
|
||||
Write-Output "Packaging debug symbols"
|
||||
|
||||
$version = & $SIGCHECK /accepteula -q -n "mRemoteV1\bin\Release\mRemoteNG.exe"
|
||||
|
||||
Write-Output "Version is $($version)"
|
||||
|
||||
$zipFilePrefix = "mRemoteNG-symbols"
|
||||
|
||||
|
||||
$outputZipPath="Release\$zipFilePrefix-$($version).zip"
|
||||
|
||||
Write-Output "Creating debug symbols ZIP file $($outputZipPath)"
|
||||
Remove-Item -Force $outputZipPath -ErrorAction SilentlyContinue
|
||||
$SymPath = (Join-Path -Path "mRemoteV1\bin\Release" -ChildPath "*.pdb")
|
||||
if(Test-Path "$SymPath") {
|
||||
& $SEVENZIP a -bt -bd -bb1 -mx=9 -tzip -y -r $outputZipPath "$SymPath"
|
||||
} else {
|
||||
Write-Output "No Debugging Symbols Found..."
|
||||
}
|
||||
|
||||
|
||||
Write-Output "Build Release Portable"
|
||||
& msbuild "$($appvDir)\mRemoteV1.sln" /nologo /t:Clean,Build /p:Configuration="Release Portable" /p:Platform=x86 /p:CertPath="$($Env:cert_path)" /p:CertPassword="$Env:cert_pwd" /m /verbosity:normal /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
|
||||
|
||||
|
||||
Write-Output "Packaging Release Portable ZIP"
|
||||
|
||||
$version = & $SIGCHECK /accepteula -q -n "mRemoteV1\bin\Release Portable\mRemoteNG.exe"
|
||||
|
||||
Write-Output "Version is $($version)"
|
||||
|
||||
$zipFilePrefix = "mRemoteNG-Portable-symbols"
|
||||
$outputZipPath="Release\$zipFilePrefix-$($version).zip"
|
||||
|
||||
Write-Output "Creating debug symbols ZIP file $($outputZipPath)"
|
||||
Remove-Item -Force $outputZipPath -ErrorAction SilentlyContinue
|
||||
$SymPath = (Join-Path -Path "mRemoteV1\bin\Release Portable" -ChildPath "*.pdb")
|
||||
if(Test-Path "$SymPath") {
|
||||
& $SEVENZIP a -bt -bd -bb1 -mx=9 -tzip -y -r $outputZipPath "$SymPath"
|
||||
} else {
|
||||
Write-Output "No Debugging Symbols Found..."
|
||||
}
|
||||
|
||||
$PortableZip="Release\mRemoteNG-Portable-$($version).zip"
|
||||
|
||||
Remove-Item -Recurse "mRemoteV1\bin\package" -ErrorAction SilentlyContinue | Out-Null
|
||||
New-Item "mRemoteV1\bin\package" -ItemType "directory" | Out-Null
|
||||
|
||||
Copy-Item "mRemoteV1\Resources\PuTTYNG.exe" -Destination "mRemoteV1\bin\package"
|
||||
|
||||
Copy-Item "mRemoteV1\bin\Release Portable\*" -Destination "mRemoteV1\bin\package" -Recurse -Force
|
||||
Copy-Item "*.txt" -Destination "mRemoteV1\bin\package"
|
||||
|
||||
Write-Output "Creating portable ZIP file $($PortableZip)"
|
||||
Remove-Item -Force $PortableZip -ErrorAction SilentlyContinue
|
||||
& $SEVENZIP a -bt -bd -bb1 -mx=9 -tzip -y -r $PortableZip ".\mRemoteV1\bin\package\*.*"
|
||||
45
Tools/build-relport.cmd
Normal file
@@ -0,0 +1,45 @@
|
||||
@echo off
|
||||
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
set SOLUTIONDIR=%~dp0..
|
||||
|
||||
rem Windows Sysinternals Sigcheck from http://technet.microsoft.com/en-us/sysinternals/bb897441
|
||||
set SIGCHECK="%SOLUTIONDIR%\Tools\exes\sigcheck.exe"
|
||||
set SEVENZIP="%SOLUTIONDIR%\Tools\7zip\7za.exe"
|
||||
|
||||
set VCVARSALL="%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\VC\vcvarsall.bat"
|
||||
call %VCVARSALL% x86
|
||||
|
||||
IF NOT "%~1"=="build" goto skipbuild
|
||||
echo Building...
|
||||
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe" "%SOLUTIONDIR%\mRemoteV1.sln" /Rebuild "Release Portable"
|
||||
|
||||
:skipbuild
|
||||
IF NOT EXIST "%SOLUTIONDIR%\mRemoteV1\bin\Release Portable\mRemoteNG.exe" echo Did you forget to build? && goto end
|
||||
set SIGCHECK=!SIGCHECK:"=^"!
|
||||
set SIGCHECK=!SIGCHECK: =^^ !
|
||||
set SIGCHECK=!SIGCHECK:(=^^(!
|
||||
set SIGCHECK=!SIGCHECK:)=^^)!
|
||||
for /F "usebackq delims=. tokens=1-4" %%i in (`!SIGCHECK! /accepteula -q -n "%SOLUTIONDIR%\mRemoteV1\bin\Release Portable\mRemoteNG.exe"`) do (
|
||||
set PRODUCT_VERSION_SHORT=%%i.%%j
|
||||
set PRODUCT_VERSION=%%i.%%j.%%k.%%l
|
||||
)
|
||||
echo Version is %PRODUCT_VERSION%
|
||||
|
||||
set PORTABLEZIP="%SOLUTIONDIR%\Release\mRemoteNG-Portable-%PRODUCT_VERSION%.zip"
|
||||
|
||||
rmdir /S /Q "%SOLUTIONDIR%\mRemoteV1\bin\package"
|
||||
mkdir "%SOLUTIONDIR%\mRemoteV1\bin\package"
|
||||
copy "%SOLUTIONDIR%\*.txt" "%SOLUTIONDIR%\mRemoteV1\bin\package"
|
||||
copy "%SOLUTIONDIR%\Installer Projects\Installer\Dependencies\PuTTYNG.exe" "%SOLUTIONDIR%\mRemoteV1\bin\package"
|
||||
|
||||
xcopy /S /Y "%SOLUTIONDIR%\mRemoteV1\bin\Release Portable" "%SOLUTIONDIR%\mRemoteV1\bin\package"
|
||||
|
||||
echo Creating portable ZIP file...
|
||||
echo %PORTABLEZIP%
|
||||
del /f /q %PORTABLEZIP% > nul 2>&1
|
||||
%SEVENZIP% a -bt -mx=9 -tzip -y -r %PORTABLEZIP% "%SOLUTIONDIR%\mRemoteV1\bin\package\*.*"
|
||||
%SEVENZIP% a -bt -mx=9 -tzip -y %PORTABLEZIP% "%SOLUTIONDIR%\*.TXT"
|
||||
|
||||
:end
|
||||
@@ -10,6 +10,6 @@ param (
|
||||
|
||||
Write-Output "===== Beginning $($PSCmdlet.MyInvocation.MyCommand) ====="
|
||||
Write-Output "Copying PUTTYNG to correct directory"
|
||||
Copy-Item -Path (Join-Path -Path $SolutionDir -ChildPath "mRemoteNG\Resources\PuTTYNG.exe") -Destination $TargetDir -Force
|
||||
Copy-Item -Path (Join-Path -Path $SolutionDir -ChildPath "mRemoteV1\Resources\PuTTYNG.exe") -Destination $TargetDir -Force
|
||||
|
||||
Write-Output ""
|
||||
@@ -11,7 +11,7 @@ param (
|
||||
Write-Output "===== Beginning $($PSCmdlet.MyInvocation.MyCommand) ====="
|
||||
Write-Output "Copying THEMES folder to output"
|
||||
|
||||
$sourceFiles = [io.path]::combine($SolutionDir , 'mRemoteNG\Resources\Themes' )
|
||||
$sourceFiles = [io.path]::combine($SolutionDir , 'mRemoteV1\Resources\Themes' )
|
||||
$DestinationDir = [io.path]::combine($TargetDir , 'Themes')
|
||||
|
||||
robocopy $sourceFiles $DestinationDir *.vstheme /s
|
||||
|
||||
@@ -11,7 +11,7 @@ param (
|
||||
Write-Output "===== Beginning $($PSCmdlet.MyInvocation.MyCommand) ====="
|
||||
Write-Output "Copying TILES folder to output"
|
||||
|
||||
$sourceFiles = [io.path]::combine($SolutionDir , 'mRemoteNG\Resources\Tiles' )
|
||||
$sourceFiles = [io.path]::combine($SolutionDir , 'mRemoteV1\Resources\Tiles' )
|
||||
robocopy $sourceFiles $TargetDir *.*
|
||||
|
||||
Write-Output ""
|
||||
|
Before Width: | Height: | Size: 28 KiB |
149
Tools/old/BUILD.CMD
Normal file
@@ -0,0 +1,149 @@
|
||||
@echo off
|
||||
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
set VERSIONTAG=
|
||||
|
||||
set VCVARSALL="%ProgramFiles(x86)%\Microsoft Visual Studio 10.0\VC\vcvarsall.bat"
|
||||
set DEVENV="devenv.exe"
|
||||
set MAKENSIS="%ProgramFiles(x86)%\NSIS\Unicode\makensis.exe"
|
||||
set RAR="%ProgramFiles%\WinRAR\WinRAR.exe"
|
||||
set SIGNCMD=signtool.exe sign /n "Astrospark Technologies, LLC" /sha1 "1cbd910dbd6e77f26506e7f600736972f700673f" /tr http://timestamp.comodoca.com/rfc3161
|
||||
|
||||
rem Windows Sysinternals Sigcheck from http://technet.microsoft.com/en-us/sysinternals/bb897441
|
||||
set SIGCHECK="%ProgramFiles(x86)%\Sigcheck\sigcheck.exe"
|
||||
|
||||
call %VCVARSALL% x86
|
||||
|
||||
rmdir /s /q "%~dp0\mRemoteV1\bin" > nul 2>&1
|
||||
rmdir /s /q "%~dp0\mRemoteV1\obj" > nul 2>&1
|
||||
|
||||
if exist "%~dp0\mRemoteV1\bin" goto ERROR_RMDIR
|
||||
if exist "%~dp0\mRemoteV1\obj" goto ERROR_RMDIR
|
||||
goto NOERROR_RMDIR
|
||||
|
||||
:ERROR_RMDIR
|
||||
echo.
|
||||
echo Could not clean output directories.
|
||||
echo.
|
||||
echo Build process failed.
|
||||
echo.
|
||||
goto END
|
||||
|
||||
:NOERROR_RMDIR
|
||||
|
||||
echo Building release version...
|
||||
%DEVENV% "%~dp0\mRemoteV1.sln" /build "Release"
|
||||
|
||||
echo Building portable version...
|
||||
%DEVENV% "%~dp0\mRemoteV1.sln" /build "Release Portable"
|
||||
|
||||
echo Signing binaries...
|
||||
%SIGNCMD% ^
|
||||
"%~dp0\mRemoteV1\bin\Release\de\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\el\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\en-US\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\es\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\es-AR\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\fr\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\hu\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\it\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\nb-NO\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\nl\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\pl\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\pt\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\pt-BR\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\ru\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\uk\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\zh-CN\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\zh-TW\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\AxInterop.MSTSCLib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\AxInterop.WFICALib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\Interop.EOLWTSCOM.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\Interop.MSTSCLib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\Interop.ShDocVw.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\Interop.WFICALib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release\mRemoteNG.exe" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\de\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\el\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\en-US\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\es\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\es-AR\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\fr\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\hu\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\it\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\nb-NO\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\nl\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\pl\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\pt\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\pt-BR\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\ru\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\uk\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\zh-CN\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\zh-TW\mRemoteNG.resources.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\AxInterop.MSTSCLib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\AxInterop.WFICALib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\Interop.EOLWTSCOM.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\Interop.MSTSCLib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\Interop.ShDocVw.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\Interop.WFICALib.dll" ^
|
||||
"%~dp0\mRemoteV1\bin\Release Portable\mRemoteNG.exe" ^
|
||||
|
||||
|
||||
rem Do not remove the two blank lines above this line.
|
||||
|
||||
mkdir "%~dp0\Release" > nul 2>&1
|
||||
|
||||
echo Getting product version...
|
||||
set VERSIONNSH="%~dp0\Release\Version.nsh"
|
||||
set SIGCHECK=!SIGCHECK:"=^"!
|
||||
set SIGCHECK=!SIGCHECK: =^^ !
|
||||
set SIGCHECK=!SIGCHECK:(=^^(!
|
||||
set SIGCHECK=!SIGCHECK:)=^^)!
|
||||
for /F "usebackq delims=. tokens=1-4" %%i in (`!SIGCHECK! /accepteula -q -n "%~dp0\mRemoteV1\bin\Release\mRemoteNG.exe"`) do (
|
||||
set PRODUCT_VERSION_SHORT=%%i.%%j
|
||||
echo ^^!define PRODUCT_VERSION "%%i.%%j.%%k.%%l" > %VERSIONNSH%
|
||||
echo ^^!define PRODUCT_VERSION_SHORT "%%i.%%j" >> %VERSIONNSH%
|
||||
echo ^^!define PRODUCT_VERSION_MAJOR "%%i" >> %VERSIONNSH%
|
||||
echo ^^!define PRODUCT_VERSION_MINOR "%%j" >> %VERSIONNSH%
|
||||
)
|
||||
echo Version is %PRODUCT_VERSION_SHORT%
|
||||
|
||||
echo Creating installer package...
|
||||
if defined VERSIONTAG (
|
||||
%MAKENSIS% /DPRODUCT_VERSION_TAG=%VERSIONTAG% "%~dp0\Installer\mRemote.nsi"
|
||||
|
||||
set INSTALLEREXE="%~dp0\Release\mRemoteNG-Installer-%PRODUCT_VERSION_SHORT%-%VERSIONTAG%.exe"
|
||||
set BINARYZIP="%~dp0\Release\mRemoteNG-%PRODUCT_VERSION_SHORT%-%VERSIONTAG%.zip"
|
||||
set PORTABLEZIP="%~dp0\Release\mRemoteNG-Portable-%PRODUCT_VERSION_SHORT%-%VERSIONTAG%.zip"
|
||||
) else (
|
||||
%MAKENSIS% "%~dp0\Installer\mRemote.nsi"
|
||||
|
||||
set INSTALLEREXE="%~dp0\Release\mRemoteNG-Installer-%PRODUCT_VERSION_SHORT%.exe"
|
||||
set BINARYZIP="%~dp0\Release\mRemoteNG-%PRODUCT_VERSION_SHORT%.zip"
|
||||
set PORTABLEZIP="%~dp0\Release\mRemoteNG-Portable-%PRODUCT_VERSION_SHORT%.zip"
|
||||
)
|
||||
|
||||
del %VERSIONNSH%
|
||||
|
||||
echo Signing installer package...
|
||||
%SIGNCMD% %INSTALLEREXE%
|
||||
|
||||
echo Creating release ZIP file...
|
||||
del /f /q %BINARYZIP% > nul 2>&1
|
||||
%RAR% a -m5 -r -ep1 -afzip -inul %BINARYZIP% "%~dp0\mRemoteV1\bin\Release\*.*"
|
||||
%RAR% a -m5 -r -ep1 -afzip -inul %BINARYZIP% "%~dp0\Installer\Dependencies\*.*"
|
||||
%RAR% a -m5 -ep -afzip -inul %BINARYZIP% "%~dp0\*.TXT"
|
||||
|
||||
echo Creating portable ZIP file...
|
||||
del /f /q %PORTABLEZIP% > nul 2>&1
|
||||
%RAR% a -m5 -r -ep1 -afzip -inul %PORTABLEZIP% "%~dp0\mRemoteV1\bin\Release Portable\*.*"
|
||||
%RAR% a -m5 -r -ep1 -afzip -inul %PORTABLEZIP% "%~dp0\Installer\Dependencies\*.*"
|
||||
%RAR% a -m5 -ep -afzip -inul %PORTABLEZIP% "%~dp0\*.TXT"
|
||||
|
||||
echo.
|
||||
echo Build process complete.
|
||||
echo.
|
||||
|
||||
:END
|
||||
pause
|
||||
26
Tools/old/Sort Language Files.cmd
Normal file
@@ -0,0 +1,26 @@
|
||||
@echo off
|
||||
|
||||
set TEMP_FOLDER="%TEMP%\Translations.tmp"
|
||||
set SORTRESX="%~dp0\Tools\SortRESX.exe"
|
||||
|
||||
echo.
|
||||
echo This script sorts the language files
|
||||
echo.
|
||||
|
||||
choice /m "Would you like to continue?"
|
||||
|
||||
echo.
|
||||
|
||||
rmdir /s /q %TEMP_FOLDER%
|
||||
mkdir %TEMP_FOLDER%
|
||||
copy "%~dp0\mRemoteV1\Language\*.resx" %TEMP_FOLDER%
|
||||
|
||||
pushd %TEMP_FOLDER%
|
||||
for %%f in (*) do %SORTRESX% %TEMP_FOLDER%\%%f "%~dp0\mRemoteV1\Language\%%f"
|
||||
popd
|
||||
|
||||
rmdir /s /q %TEMP_FOLDER%
|
||||
|
||||
echo Done.
|
||||
echo.
|
||||
pause
|
||||
BIN
Tools/old/SortRESX.exe
Normal file
55
Tools/old/Update Languages.cmd
Normal file
@@ -0,0 +1,55 @@
|
||||
@echo off
|
||||
|
||||
set ZIP_FILE="%~dp0\..\mremoteng.zip"
|
||||
set TEMP_FOLDER="%TEMP%\Translations.tmp"
|
||||
set SORTRESX="%~dp0\Tools\SortRESX.exe"
|
||||
set RAR="%ProgramFiles%\WinRAR\WinRAR.exe"
|
||||
|
||||
call :expand %ZIP_FILE%
|
||||
goto :skip
|
||||
:expand
|
||||
set ZIP_FILE="%~f1"
|
||||
exit /b
|
||||
:skip
|
||||
|
||||
echo.
|
||||
echo This script updates the language files with new translations from Crowdin
|
||||
echo.
|
||||
echo Download the latest translation file from Crowdin and place it here:
|
||||
echo.
|
||||
echo %ZIP_FILE%
|
||||
echo.
|
||||
|
||||
choice /m "Would you like to continue?"
|
||||
|
||||
echo.
|
||||
|
||||
mkdir %TEMP_FOLDER%
|
||||
%RAR% x -o+ %ZIP_FILE% *.* %TEMP_FOLDER%
|
||||
|
||||
%SORTRESX% %TEMP_FOLDER%\ar\Language.ar.resx "%~dp0\mRemoteV1\Language\Language.ar.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\bg\Language.bg.resx "%~dp0\mRemoteV1\Language\Language.bg.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\de\Language.de.resx "%~dp0\mRemoteV1\Language\Language.de.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\el\Language.el.resx "%~dp0\mRemoteV1\Language\Language.el.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\en-US\Language.en.resx "%~dp0\mRemoteV1\Language\Language.en-US.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\es-AR\Language.es.resx "%~dp0\mRemoteV1\Language\Language.es-AR.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\es-ES\Language.es.resx "%~dp0\mRemoteV1\Language\Language.es.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\fr\Language.fr.resx "%~dp0\mRemoteV1\Language\Language.fr.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\he\Language.he.resx "%~dp0\mRemoteV1\Language\Language.he.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\hu\Language.hu.resx "%~dp0\mRemoteV1\Language\Language.hu.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\it\Language.it.resx "%~dp0\mRemoteV1\Language\Language.it.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\nb\Language.nb.resx "%~dp0\mRemoteV1\Language\Language.nb-NO.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\nl\Language.nl.resx "%~dp0\mRemoteV1\Language\Language.nl.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\pl\Language.pl.resx "%~dp0\mRemoteV1\Language\Language.pl.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\pt-BR\Language.pt.resx "%~dp0\mRemoteV1\Language\Language.pt-BR.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\pt-PT\Language.pt.resx "%~dp0\mRemoteV1\Language\Language.pt.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\ru\Language.ru.resx "%~dp0\mRemoteV1\Language\Language.ru.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\uk\Language.uk.resx "%~dp0\mRemoteV1\Language\Language.uk.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\zh-CN\Language.zh.resx "%~dp0\mRemoteV1\Language\Language.zh-CN.resx"
|
||||
%SORTRESX% %TEMP_FOLDER%\zh-TW\Language.zh.resx "%~dp0\mRemoteV1\Language\Language.zh-TW.resx"
|
||||
|
||||
rmdir /s /q %TEMP_FOLDER%
|
||||
|
||||
echo Done.
|
||||
echo.
|
||||
pause
|
||||
@@ -26,7 +26,7 @@ param (
|
||||
)
|
||||
|
||||
Write-Output "+=================================================================+"
|
||||
Write-Output "| Beginning mRemoteNG Post Build |"
|
||||
Write-Output "| Beginning mRemoteV1 Post Build |"
|
||||
Write-Output "+=================================================================+"
|
||||
Format-Table -AutoSize -Wrap -InputObject @{
|
||||
"SolutionDir" = $SolutionDir
|
||||
@@ -8,7 +8,7 @@ $renameTarget = $SolutionDir + "InstallerProjects\Installer\bin\Release\en-US\mR
|
||||
Write-Host $SolutionDir
|
||||
Write-Host $renameTarget
|
||||
|
||||
$targetVersionedFile = "$SolutionDir\mRemoteNG\bin\Release\mRemoteNG.exe"
|
||||
$targetVersionedFile = "$SolutionDir\mRemoteV1\bin\Release\mRemoteNG.exe"
|
||||
$version = &"$SolutionDir\Tools\exes\sigcheck.exe" /accepteula -q -n $targetVersionedFile
|
||||
|
||||
|
||||
|
||||
@@ -13,21 +13,11 @@ Write-Output "===== Beginning $($PSCmdlet.MyInvocation.MyCommand) ====="
|
||||
Write-Output "Building HTML-Documentation with Sphinx"
|
||||
|
||||
$path_HelpFilesDir = Join-Path -Path $TargetDir -ChildPath "Help"
|
||||
$path_SphinxSourceDir = Join-Path -Path $SolutionDir -ChildPath "mRemoteNG\Documentation"
|
||||
|
||||
$path_SphinxSourceDir = Join-Path -Path $SolutionDir -ChildPath "mremoteV1\Documentation"
|
||||
# Remove stale Help files, if they exist
|
||||
if (Test-Path -Path $path_HelpFilesDir) {
|
||||
Remove-Item -Path $path_HelpFilesDir -Recurse -Force
|
||||
}
|
||||
|
||||
# Build docs
|
||||
sphinx-build $path_SphinxSourceDir $path_HelpFilesDir
|
||||
|
||||
# Place dummy html file if build failed
|
||||
if (-Not (Test-Path $path_HelpFilesDir\index.html -PathType Leaf)) {
|
||||
New-Item -Path $path_HelpFilesDir -ItemType "directory"
|
||||
New-Item $path_HelpFilesDir\index.html
|
||||
Set-Content $path_HelpFilesDir\index.html 'Welcome to mRemoteNG!'
|
||||
}
|
||||
|
||||
Write-Output ""
|
||||
@@ -33,21 +33,21 @@ $SEVENZIP="$($SolutionDir)Tools\7zip\7za.exe"
|
||||
if ($ConfigurationName -eq "Release Portable") {
|
||||
Write-Output "Packaging Release Portable ZIP"
|
||||
|
||||
$version = & $SIGCHECK /accepteula -q -n "$($SolutionDir)mRemoteNG\bin\$($ConfigurationName)\mRemoteNG.exe"
|
||||
$version = & $SIGCHECK /accepteula -q -n "$($SolutionDir)mRemoteV1\bin\$($ConfigurationName)\mRemoteNG.exe"
|
||||
|
||||
Write-Output "Version is $($version)"
|
||||
|
||||
$PortableZip="$($SolutionDir)Release\mRemoteNG-Portable-$($version).zip"
|
||||
|
||||
$tempFolderPath = Join-Path -Path $SolutionDir -ChildPath "mRemoteNG\bin\package"
|
||||
$tempFolderPath = Join-Path -Path $SolutionDir -ChildPath "mRemoteV1\bin\package"
|
||||
Remove-Item -Recurse $tempFolderPath -ErrorAction SilentlyContinue | Out-Null
|
||||
New-Item $tempFolderPath -ItemType "directory" | Out-Null
|
||||
|
||||
Copy-Item "$($SolutionDir)mRemoteNG\Resources\PuTTYNG.exe" -Destination $tempFolderPath
|
||||
Copy-Item "$($SolutionDir)mRemoteV1\Resources\PuTTYNG.exe" -Destination $tempFolderPath
|
||||
|
||||
#Write-Output "$($SolutionDir)mRemoteNG\bin\$ConfigurationName"
|
||||
#Write-Output "$($SolutionDir)mRemoteNG\bin\package"
|
||||
Copy-Item "$($SolutionDir)mRemoteNG\bin\$ConfigurationName\*" -Destination $tempFolderPath -Recurse -Force
|
||||
#Write-Output "$($SolutionDir)mRemoteV1\bin\$ConfigurationName"
|
||||
#Write-Output "$($SolutionDir)mRemoteV1\bin\package"
|
||||
Copy-Item "$($SolutionDir)mRemoteV1\bin\$ConfigurationName\*" -Destination $tempFolderPath -Recurse -Force
|
||||
# Delete any PDB files that accidentally get copied into the temp folder
|
||||
Get-ChildItem -Path $tempFolderPath -Filter "*.pdb" | Remove-Item
|
||||
Copy-Item "$($SolutionDir)*.txt" -Destination $tempFolderPath
|
||||
|
||||
@@ -33,7 +33,7 @@ $SEVENZIP="$($SolutionDir)Tools\7zip\7za.exe"
|
||||
if ($ConfigurationName -match "Release") {
|
||||
Write-Output "Packaging debug symbols"
|
||||
|
||||
$version = & $SIGCHECK /accepteula -q -n "$($SolutionDir)mRemoteNG\bin\$($ConfigurationName)\mRemoteNG.exe"
|
||||
$version = & $SIGCHECK /accepteula -q -n "$($SolutionDir)mRemoteV1\bin\$($ConfigurationName)\mRemoteNG.exe"
|
||||
|
||||
Write-Output "Version is $($version)"
|
||||
|
||||
|
||||
@@ -13,11 +13,11 @@
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="BouncyCastle.Crypto" publicKeyToken="0e99375e54769942" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.8.6.0" newVersion="1.8.6.0" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.8.5.0" newVersion="1.8.5.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Threading.Tasks.Extensions" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.2.0.1" newVersion="4.2.0.1" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.ValueTuple" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||
@@ -25,24 +25,12 @@
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Google.Protobuf" publicKeyToken="a7d26565bac4d604" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-3.12.1.0" newVersion="3.12.1.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.6.0" newVersion="4.0.6.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.1" newVersion="4.0.1.1" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Cucumber.Messages" publicKeyToken="b10c5988214f940c" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-6.0.2.0" newVersion="6.0.2.0" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-3.8.0.0" newVersion="3.8.0.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6" />
|
||||
</startup>
|
||||
|
||||
</configuration>
|
||||
</configuration>
|
||||
@@ -1,23 +1,24 @@
|
||||
// ------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by SpecFlow (https://www.specflow.org/).
|
||||
// SpecFlow Version:3.8.0.0
|
||||
// SpecFlow Generator Version:3.8.0.0
|
||||
// This code was generated by SpecFlow (http://www.specflow.org/).
|
||||
// SpecFlow Version:2.2.0.0
|
||||
// SpecFlow Generator Version:2.2.0.0
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// ------------------------------------------------------------------------------
|
||||
#region Designer generated code
|
||||
|
||||
using NUnit.Framework;
|
||||
|
||||
#pragma warning disable
|
||||
namespace mRemoteNGSpecs.Features
|
||||
namespace mRemoteNG.Specs.Features
|
||||
{
|
||||
using TechTalk.SpecFlow;
|
||||
using System;
|
||||
using System.Linq;
|
||||
|
||||
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "3.8.0.0")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "2.2.0.0")]
|
||||
[System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[NUnit.Framework.TestFixtureAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("CredentialRepository")]
|
||||
@@ -26,8 +27,6 @@ namespace mRemoteNGSpecs.Features
|
||||
|
||||
private TechTalk.SpecFlow.ITestRunner testRunner;
|
||||
|
||||
private string[] _featureTags = ((string[])(null));
|
||||
|
||||
#line 1 "CredentialRepository.feature"
|
||||
#line hidden
|
||||
|
||||
@@ -35,7 +34,7 @@ namespace mRemoteNGSpecs.Features
|
||||
public virtual void FeatureSetup()
|
||||
{
|
||||
testRunner = TechTalk.SpecFlow.TestRunnerManager.GetTestRunner();
|
||||
TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en-US"), "Features", "CredentialRepository", "\tAs a user with several environments\r\n\tI would like to load multiple credential r" +
|
||||
TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en-US"), "CredentialRepository", "\tAs a user with several environments\r\n\tI would like to load multiple credential r" +
|
||||
"epositories\r\n\tIn order to keep credentials separate", ProgrammingLanguage.CSharp, ((string[])(null)));
|
||||
testRunner.OnFeatureStart(featureInfo);
|
||||
}
|
||||
@@ -53,18 +52,12 @@ namespace mRemoteNGSpecs.Features
|
||||
}
|
||||
|
||||
[NUnit.Framework.TearDownAttribute()]
|
||||
public virtual void TestTearDown()
|
||||
public virtual void ScenarioTearDown()
|
||||
{
|
||||
testRunner.OnScenarioEnd();
|
||||
}
|
||||
|
||||
public virtual void ScenarioInitialize(TechTalk.SpecFlow.ScenarioInfo scenarioInfo)
|
||||
{
|
||||
testRunner.OnScenarioInitialize(scenarioInfo);
|
||||
testRunner.ScenarioContext.ScenarioContainer.RegisterInstanceAs<NUnit.Framework.TestContext>(NUnit.Framework.TestContext.CurrentContext);
|
||||
}
|
||||
|
||||
public virtual void ScenarioStart()
|
||||
public virtual void ScenarioSetup(TechTalk.SpecFlow.ScenarioInfo scenarioInfo)
|
||||
{
|
||||
testRunner.OnScenarioStart();
|
||||
}
|
||||
@@ -77,137 +70,66 @@ namespace mRemoteNGSpecs.Features
|
||||
[NUnit.Framework.TestAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("Load credential repository")]
|
||||
[NUnit.Framework.CategoryAttribute("credentials")]
|
||||
[Ignore("Cred Repo not implmented currently.")]
|
||||
public virtual void LoadCredentialRepository()
|
||||
{
|
||||
string[] tagsOfScenario = new string[] {
|
||||
"credentials"};
|
||||
System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary();
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Load credential repository", null, tagsOfScenario, argumentsOfScenario, this._featureTags);
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Load credential repository", "", new string[] {
|
||||
"credentials"});
|
||||
#line 7
|
||||
this.ScenarioInitialize(scenarioInfo);
|
||||
#line hidden
|
||||
bool isScenarioIgnored = default(bool);
|
||||
bool isFeatureIgnored = default(bool);
|
||||
if ((tagsOfScenario != null))
|
||||
{
|
||||
isScenarioIgnored = tagsOfScenario.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((this._featureTags != null))
|
||||
{
|
||||
isFeatureIgnored = this._featureTags.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((isScenarioIgnored || isFeatureIgnored))
|
||||
{
|
||||
testRunner.SkipScenario();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.ScenarioStart();
|
||||
this.ScenarioSetup(scenarioInfo);
|
||||
#line 8
|
||||
testRunner.Given("I have a credential repository", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given ");
|
||||
#line hidden
|
||||
#line 9
|
||||
testRunner.And("the credential repository is unloaded", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 10
|
||||
testRunner.When("I click load", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When ");
|
||||
#line hidden
|
||||
#line 11
|
||||
testRunner.Then("the credential repository is loaded", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then ");
|
||||
#line hidden
|
||||
}
|
||||
this.ScenarioCleanup();
|
||||
}
|
||||
|
||||
[NUnit.Framework.TestAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("Add credential record")]
|
||||
[Ignore("Cred Repo not implmented currently.")]
|
||||
public virtual void AddCredentialRecord()
|
||||
{
|
||||
string[] tagsOfScenario = ((string[])(null));
|
||||
System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary();
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Add credential record", null, tagsOfScenario, argumentsOfScenario, this._featureTags);
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Add credential record", "", ((string[])(null)));
|
||||
#line 13
|
||||
this.ScenarioInitialize(scenarioInfo);
|
||||
#line hidden
|
||||
bool isScenarioIgnored = default(bool);
|
||||
bool isFeatureIgnored = default(bool);
|
||||
if ((tagsOfScenario != null))
|
||||
{
|
||||
isScenarioIgnored = tagsOfScenario.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((this._featureTags != null))
|
||||
{
|
||||
isFeatureIgnored = this._featureTags.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((isScenarioIgnored || isFeatureIgnored))
|
||||
{
|
||||
testRunner.SkipScenario();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.ScenarioStart();
|
||||
this.ScenarioSetup(scenarioInfo);
|
||||
#line 14
|
||||
testRunner.Given("I have a credential repository", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given ");
|
||||
#line hidden
|
||||
#line 15
|
||||
testRunner.And("The credential repository is loaded", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 16
|
||||
testRunner.And("The repository has 0 credentials", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 17
|
||||
testRunner.When("I click add credential", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When ");
|
||||
#line hidden
|
||||
#line 18
|
||||
testRunner.Then("the repository has 1 credentials", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then ");
|
||||
#line hidden
|
||||
}
|
||||
this.ScenarioCleanup();
|
||||
}
|
||||
|
||||
[NUnit.Framework.TestAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("Unload credential repository")]
|
||||
[Ignore("Cred Repo not implmented currently.")]
|
||||
public virtual void UnloadCredentialRepository()
|
||||
{
|
||||
string[] tagsOfScenario = ((string[])(null));
|
||||
System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary();
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Unload credential repository", null, tagsOfScenario, argumentsOfScenario, this._featureTags);
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Unload credential repository", "", ((string[])(null)));
|
||||
#line 20
|
||||
this.ScenarioInitialize(scenarioInfo);
|
||||
#line hidden
|
||||
bool isScenarioIgnored = default(bool);
|
||||
bool isFeatureIgnored = default(bool);
|
||||
if ((tagsOfScenario != null))
|
||||
{
|
||||
isScenarioIgnored = tagsOfScenario.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((this._featureTags != null))
|
||||
{
|
||||
isFeatureIgnored = this._featureTags.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((isScenarioIgnored || isFeatureIgnored))
|
||||
{
|
||||
testRunner.SkipScenario();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.ScenarioStart();
|
||||
this.ScenarioSetup(scenarioInfo);
|
||||
#line 21
|
||||
testRunner.Given("I have a credential repository", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given ");
|
||||
#line hidden
|
||||
#line 22
|
||||
testRunner.And("The credential repository is loaded", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 23
|
||||
testRunner.And("The repository has 1 credentials", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 24
|
||||
testRunner.When("I click unload", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When ");
|
||||
#line hidden
|
||||
#line 25
|
||||
testRunner.Then("the credentials in the repository will no longer be available", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then ");
|
||||
#line hidden
|
||||
}
|
||||
this.ScenarioCleanup();
|
||||
}
|
||||
}
|
||||
@@ -1,33 +1,33 @@
|
||||
// ------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by SpecFlow (https://www.specflow.org/).
|
||||
// SpecFlow Version:3.8.0.0
|
||||
// SpecFlow Generator Version:3.8.0.0
|
||||
// This code was generated by SpecFlow (http://www.specflow.org/).
|
||||
// SpecFlow Version:2.2.0.0
|
||||
// SpecFlow Generator Version:2.2.0.0
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
// ------------------------------------------------------------------------------
|
||||
#region Designer generated code
|
||||
|
||||
using NUnit.Framework;
|
||||
|
||||
#pragma warning disable
|
||||
namespace mRemoteNGSpecs.Features
|
||||
namespace mRemoteNG.Specs.Features
|
||||
{
|
||||
using TechTalk.SpecFlow;
|
||||
using System;
|
||||
using System.Linq;
|
||||
|
||||
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "3.8.0.0")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "2.2.0.0")]
|
||||
[System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[NUnit.Framework.TestFixtureAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("CredentialRepositoryList")]
|
||||
[Ignore("Cred Repo not implmented currently.")]
|
||||
public partial class CredentialRepositoryListFeature
|
||||
{
|
||||
|
||||
private TechTalk.SpecFlow.ITestRunner testRunner;
|
||||
|
||||
private string[] _featureTags = ((string[])(null));
|
||||
|
||||
#line 1 "CredentialRepositoryList.feature"
|
||||
#line hidden
|
||||
|
||||
@@ -35,7 +35,7 @@ namespace mRemoteNGSpecs.Features
|
||||
public virtual void FeatureSetup()
|
||||
{
|
||||
testRunner = TechTalk.SpecFlow.TestRunnerManager.GetTestRunner();
|
||||
TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en-US"), "Features", "CredentialRepositoryList", "\tAs a user with several environments\r\n\tI would like to load multiple credential r" +
|
||||
TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en-US"), "CredentialRepositoryList", "\tAs a user with several environments\r\n\tI would like to load multiple credential r" +
|
||||
"epositories\r\n\tIn order to keep credentials separate", ProgrammingLanguage.CSharp, ((string[])(null)));
|
||||
testRunner.OnFeatureStart(featureInfo);
|
||||
}
|
||||
@@ -53,18 +53,12 @@ namespace mRemoteNGSpecs.Features
|
||||
}
|
||||
|
||||
[NUnit.Framework.TearDownAttribute()]
|
||||
public virtual void TestTearDown()
|
||||
public virtual void ScenarioTearDown()
|
||||
{
|
||||
testRunner.OnScenarioEnd();
|
||||
}
|
||||
|
||||
public virtual void ScenarioInitialize(TechTalk.SpecFlow.ScenarioInfo scenarioInfo)
|
||||
{
|
||||
testRunner.OnScenarioInitialize(scenarioInfo);
|
||||
testRunner.ScenarioContext.ScenarioContainer.RegisterInstanceAs<NUnit.Framework.TestContext>(NUnit.Framework.TestContext.CurrentContext);
|
||||
}
|
||||
|
||||
public virtual void ScenarioStart()
|
||||
public virtual void ScenarioSetup(TechTalk.SpecFlow.ScenarioInfo scenarioInfo)
|
||||
{
|
||||
testRunner.OnScenarioStart();
|
||||
}
|
||||
@@ -77,88 +71,42 @@ namespace mRemoteNGSpecs.Features
|
||||
[NUnit.Framework.TestAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("Add a new credential repository")]
|
||||
[NUnit.Framework.CategoryAttribute("credentials")]
|
||||
[Ignore("Cred Repo not implmented currently.")]
|
||||
public virtual void AddANewCredentialRepository()
|
||||
{
|
||||
string[] tagsOfScenario = new string[] {
|
||||
"credentials"};
|
||||
System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary();
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Add a new credential repository", null, tagsOfScenario, argumentsOfScenario, this._featureTags);
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Add a new credential repository", "", new string[] {
|
||||
"credentials"});
|
||||
#line 7
|
||||
this.ScenarioInitialize(scenarioInfo);
|
||||
#line hidden
|
||||
bool isScenarioIgnored = default(bool);
|
||||
bool isFeatureIgnored = default(bool);
|
||||
if ((tagsOfScenario != null))
|
||||
{
|
||||
isScenarioIgnored = tagsOfScenario.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((this._featureTags != null))
|
||||
{
|
||||
isFeatureIgnored = this._featureTags.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((isScenarioIgnored || isFeatureIgnored))
|
||||
{
|
||||
testRunner.SkipScenario();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.ScenarioStart();
|
||||
this.ScenarioSetup(scenarioInfo);
|
||||
#line 8
|
||||
testRunner.Given("I have a credential repository list", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given ");
|
||||
#line hidden
|
||||
#line 9
|
||||
testRunner.And("It has 0 repositories set up", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 10
|
||||
testRunner.When("I press add and complete the creation wizard", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When ");
|
||||
#line hidden
|
||||
#line 11
|
||||
testRunner.Then("I will have 1 credential repository", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then ");
|
||||
#line hidden
|
||||
}
|
||||
this.ScenarioCleanup();
|
||||
}
|
||||
|
||||
[NUnit.Framework.TestAttribute()]
|
||||
[NUnit.Framework.DescriptionAttribute("Remove a credential repository")]
|
||||
[Ignore("Cred Repo not implmented currently.")]
|
||||
public virtual void RemoveACredentialRepository()
|
||||
{
|
||||
string[] tagsOfScenario = ((string[])(null));
|
||||
System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary();
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Remove a credential repository", null, tagsOfScenario, argumentsOfScenario, this._featureTags);
|
||||
TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Remove a credential repository", "", ((string[])(null)));
|
||||
#line 13
|
||||
this.ScenarioInitialize(scenarioInfo);
|
||||
#line hidden
|
||||
bool isScenarioIgnored = default(bool);
|
||||
bool isFeatureIgnored = default(bool);
|
||||
if ((tagsOfScenario != null))
|
||||
{
|
||||
isScenarioIgnored = tagsOfScenario.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((this._featureTags != null))
|
||||
{
|
||||
isFeatureIgnored = this._featureTags.Where(__entry => __entry != null).Where(__entry => String.Equals(__entry, "ignore", StringComparison.CurrentCultureIgnoreCase)).Any();
|
||||
}
|
||||
if ((isScenarioIgnored || isFeatureIgnored))
|
||||
{
|
||||
testRunner.SkipScenario();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.ScenarioStart();
|
||||
this.ScenarioSetup(scenarioInfo);
|
||||
#line 14
|
||||
testRunner.Given("I have a credential repository list", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given ");
|
||||
#line hidden
|
||||
#line 15
|
||||
testRunner.And("It has 2 repositories set up", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And ");
|
||||
#line hidden
|
||||
#line 16
|
||||
testRunner.When("I remove the first repository", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When ");
|
||||
#line hidden
|
||||
#line 17
|
||||
testRunner.Then("I will have 1 credential repository", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then ");
|
||||
#line hidden
|
||||
}
|
||||
this.ScenarioCleanup();
|
||||
}
|
||||
}
|
||||
@@ -1,14 +1,15 @@
|
||||
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("mRemoteNGSpecs")]
|
||||
[assembly: AssemblyTitle("mRemoteNG.Specs")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("mRemoteNGSpecs")]
|
||||
[assembly: AssemblyProduct("mRemoteNG.Specs")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2017")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
@@ -1,10 +1,10 @@
|
||||
using System.Linq;
|
||||
using mRemoteNG.Credential.Repositories;
|
||||
using mRemoteNGSpecs.Utilities;
|
||||
using mRemoteNG.Specs.Utilities;
|
||||
using NUnit.Framework;
|
||||
using TechTalk.SpecFlow;
|
||||
|
||||
namespace mRemoteNGSpecs.StepDefinitions
|
||||
namespace mRemoteNG.Specs.StepDefinitions
|
||||
{
|
||||
[Binding]
|
||||
public class CredentialRepositoryListSteps
|
||||
@@ -1,11 +1,11 @@
|
||||
using System.Security;
|
||||
using mRemoteNG.Credential;
|
||||
using mRemoteNG.Security;
|
||||
using mRemoteNGSpecs.Utilities;
|
||||
using mRemoteNG.Specs.Utilities;
|
||||
using NUnit.Framework;
|
||||
using TechTalk.SpecFlow;
|
||||
|
||||
namespace mRemoteNGSpecs.StepDefinitions
|
||||
namespace mRemoteNG.Specs.StepDefinitions
|
||||
{
|
||||
[Binding]
|
||||
public class CredentialRepositorySteps
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace mRemoteNGSpecs.Utilities
|
||||
namespace mRemoteNG.Specs.Utilities
|
||||
{
|
||||
public class CredRepoXmlFileBuilder
|
||||
{
|
||||
@@ -7,7 +7,7 @@ using mRemoteNG.Credential.Repositories;
|
||||
using mRemoteNG.Security;
|
||||
using mRemoteNG.Security.SymmetricEncryption;
|
||||
|
||||
namespace mRemoteNGSpecs.Utilities
|
||||
namespace mRemoteNG.Specs.Utilities
|
||||
{
|
||||
public class XmlCredentialRepoBuilder
|
||||
{
|
||||
136
mRemoteNG.Specs/mRemoteNG.Specs.csproj
Normal file
@@ -0,0 +1,136 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.props" Condition="Exists('..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.props')" />
|
||||
<Import Project="..\packages\NUnit.3.12.0\build\NUnit.props" Condition="Exists('..\packages\NUnit.3.12.0\build\NUnit.props')" />
|
||||
<Import Project="..\packages\NUnit3TestAdapter.3.13.0\build\net35\NUnit3TestAdapter.props" Condition="Exists('..\packages\NUnit3TestAdapter.3.13.0\build\net35\NUnit3TestAdapter.props')" />
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>mRemoteNG.Specs</RootNamespace>
|
||||
<AssemblyName>mRemoteNG.Specs</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<TargetFrameworkProfile />
|
||||
<NuGetPackageImportStamp>
|
||||
</NuGetPackageImportStamp>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="BoDi, Version=1.4.1.0, Culture=neutral, PublicKeyToken=ff7cd5ea2744b496, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\BoDi.1.4.1\lib\net45\BoDi.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Gherkin, Version=6.0.0.0, Culture=neutral, PublicKeyToken=86496cfa5b4a5851, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Gherkin.6.0.0\lib\net45\Gherkin.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="nunit.framework, Version=3.12.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NUnit.3.12.0\lib\net45\nunit.framework.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Runtime.CompilerServices.Unsafe, Version=4.0.4.1, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Runtime.CompilerServices.Unsafe.4.5.2\lib\netstandard1.0\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Threading.Tasks.Extensions, Version=4.2.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Threading.Tasks.Extensions.4.5.2\lib\portable-net45+win8+wp8+wpa81\System.Threading.Tasks.Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.ValueTuple, Version=4.0.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.ValueTuple.4.5.0\lib\netstandard1.0\System.ValueTuple.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
<Reference Include="TechTalk.SpecFlow, Version=3.0.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\SpecFlow.3.0.224\lib\net45\TechTalk.SpecFlow.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="TechTalk.SpecFlow.NUnit.SpecFlowPlugin, Version=3.0.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\SpecFlow.NUnit.3.0.224\lib\net45\TechTalk.SpecFlow.NUnit.SpecFlowPlugin.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Utf8Json, Version=1.3.7.0, Culture=neutral, PublicKeyToken=8a73d3ba7e392e27, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Utf8Json.1.3.7\lib\net45\Utf8Json.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Features\CredentialRepository.feature.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>CredentialRepository.feature</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Features\CredentialRepositoryList.feature.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>CredentialRepositoryList.feature</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="StepDefinitions\CredentialRepositoryListSteps.cs" />
|
||||
<Compile Include="StepDefinitions\CredentialRepositorySteps.cs" />
|
||||
<Compile Include="Utilities\CredRepoXmlFileBuilder.cs" />
|
||||
<Compile Include="Utilities\XmlCredentialRepoBuilder.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="Features\CredentialRepository.feature">
|
||||
<Generator>SpecFlowSingleFileGenerator</Generator>
|
||||
<LastGenOutput>CredentialRepository.feature.cs</LastGenOutput>
|
||||
</None>
|
||||
<None Include="Features\CredentialRepositoryList.feature">
|
||||
<Generator>SpecFlowSingleFileGenerator</Generator>
|
||||
<LastGenOutput>CredentialRepositoryList.feature.cs</LastGenOutput>
|
||||
</None>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\mRemoteV1\mRemoteV1.csproj">
|
||||
<Project>{4934a491-40bc-4e5b-9166-ea1169a220f6}</Project>
|
||||
<Name>mRemoteV1</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup />
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
||||
</PropertyGroup>
|
||||
<Error Condition="!Exists('..\packages\NUnit3TestAdapter.3.13.0\build\net35\NUnit3TestAdapter.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\NUnit3TestAdapter.3.13.0\build\net35\NUnit3TestAdapter.props'))" />
|
||||
<Error Condition="!Exists('..\packages\NUnit.3.12.0\build\NUnit.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\NUnit.3.12.0\build\NUnit.props'))" />
|
||||
<Error Condition="!Exists('..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.props'))" />
|
||||
<Error Condition="!Exists('..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.targets'))" />
|
||||
</Target>
|
||||
<Import Project="..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.targets" Condition="Exists('..\packages\SpecFlow.NUnit.3.0.224\build\SpecFlow.NUnit.targets')" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
25
mRemoteNG.Specs/packages.config
Normal file
@@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="BoDi" version="1.4.1" targetFramework="net46" />
|
||||
<package id="Gherkin" version="6.0.0" targetFramework="net46" />
|
||||
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net46" />
|
||||
<package id="NUnit" version="3.12.0" targetFramework="net46" />
|
||||
<package id="NUnit.Console" version="3.10.0" targetFramework="net46" />
|
||||
<package id="NUnit.ConsoleRunner" version="3.10.0" targetFramework="net46" />
|
||||
<package id="NUnit.Extension.NUnitProjectLoader" version="3.6.0" targetFramework="net46" />
|
||||
<package id="NUnit.Extension.NUnitV2Driver" version="3.7.0" targetFramework="net46" />
|
||||
<package id="NUnit.Extension.NUnitV2ResultWriter" version="3.6.0" targetFramework="net46" />
|
||||
<package id="NUnit.Extension.TeamCityEventListener" version="1.0.6" targetFramework="net46" />
|
||||
<package id="NUnit.Extension.VSProjectLoader" version="3.8.0" targetFramework="net46" />
|
||||
<package id="NUnit.Runners" version="3.10.0" targetFramework="net46" />
|
||||
<package id="NUnit3TestAdapter" version="3.13.0" targetFramework="net46" />
|
||||
<package id="SpecFlow" version="3.0.224" targetFramework="net46" />
|
||||
<package id="SpecFlow.NUnit" version="3.0.224" targetFramework="net46" />
|
||||
<package id="SpecFlow.NUnit.Runners" version="3.0.224" targetFramework="net46" />
|
||||
<package id="System.Reflection.Emit" version="4.3.0" targetFramework="net46" />
|
||||
<package id="System.Reflection.Emit.Lightweight" version="4.3.0" targetFramework="net46" />
|
||||
<package id="System.Runtime.CompilerServices.Unsafe" version="4.5.2" targetFramework="net46" />
|
||||
<package id="System.Threading.Tasks.Extensions" version="4.5.2" targetFramework="net46" />
|
||||
<package id="System.ValueTuple" version="4.5.0" targetFramework="net46" />
|
||||
<package id="Utf8Json" version="1.3.7" targetFramework="net46" />
|
||||
</packages>
|
||||
@@ -1,547 +0,0 @@
|
||||
using System;
|
||||
using System.Drawing;
|
||||
using System.Runtime.ConstrainedExecution;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
|
||||
#pragma warning disable 649
|
||||
#pragma warning disable 169
|
||||
|
||||
namespace mRemoteNG.App
|
||||
{
|
||||
public static class NativeMethods
|
||||
{
|
||||
#region Functions
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern bool AppendMenu(IntPtr hMenu, int uFlags, IntPtr uIDNewItem, string lpNewItem);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr CreatePopupMenu();
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr FindWindowEx(IntPtr parentHandle,
|
||||
IntPtr childAfter,
|
||||
string lclassName,
|
||||
string windowTitle);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr GetForegroundWindow();
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr GetSystemMenu(IntPtr hWnd, bool bRevert);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern bool InsertMenu(IntPtr hMenu,
|
||||
int uPosition,
|
||||
int uFlags,
|
||||
IntPtr uIDNewItem,
|
||||
string lpNewItem);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern int IsIconic(IntPtr hWnd);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern bool MoveWindow(IntPtr hWnd, int x, int y, int cx, int cy, bool repaint);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern bool PostMessage(IntPtr hWnd, int Msg, IntPtr wParam, IntPtr lParam);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr SendMessage(IntPtr hWnd, int msg, IntPtr wparam, IntPtr lparam);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr SendMessage(IntPtr hWnd, uint Msg, IntPtr wParam, IntPtr lParam);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr PostMessage(IntPtr hWnd, uint Msg, IntPtr wParam, IntPtr lParam);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr SendMessage(IntPtr hWnd, uint Msg, IntPtr wParam, StringBuilder lParam);
|
||||
|
||||
[DllImport("user32.dll", CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr SendMessage(IntPtr hWnd, uint msg, IntPtr wParam, string lParam);
|
||||
|
||||
[DllImport("user32.dll", CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr SendMessage([In] IntPtr hWnd,
|
||||
[In] uint msg,
|
||||
[Out] StringBuilder wParam,
|
||||
[In] IntPtr lParam);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr SetClipboardViewer(IntPtr hWndNewViewer);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern bool SetForegroundWindow(IntPtr hWnd);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern bool SetMenuItemBitmaps(IntPtr hMenu,
|
||||
int uPosition,
|
||||
int uFlags,
|
||||
IntPtr hBitmapUnchecked,
|
||||
IntPtr hBitmapChecked);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern long SetParent(IntPtr hWndChild, IntPtr hWndNewParent);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern int SetWindowLong(IntPtr hWnd, int nIndex, int dwNewLong);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern int ShowWindow(IntPtr hWnd, int nCmdShow);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern IntPtr WindowFromPoint(Point point);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern int GetClassName(IntPtr hWnd, StringBuilder lpClassName, int nMaxCount);
|
||||
|
||||
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
|
||||
internal static extern int GetDlgCtrlID(IntPtr hwndCtl);
|
||||
|
||||
[DllImport("user32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
|
||||
internal static extern bool GetWindowPlacement(IntPtr hWnd, ref WINDOWPLACEMENT lpwndpl);
|
||||
|
||||
[DllImport("user32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
|
||||
internal static extern bool SetWindowPlacement(IntPtr hWnd, ref WINDOWPLACEMENT lpwndpl);
|
||||
|
||||
[DllImport("kernel32", SetLastError = true)]
|
||||
[ReliabilityContract(Consistency.WillNotCorruptState, Cer.MayFail)]
|
||||
internal static extern bool CloseHandle(IntPtr handle);
|
||||
|
||||
#endregion
|
||||
|
||||
#region Structures
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
internal struct WINDOWPOS
|
||||
{
|
||||
public IntPtr hwnd;
|
||||
public IntPtr hwndInsertAfter;
|
||||
public int x;
|
||||
public int y;
|
||||
public int cx;
|
||||
public int cy;
|
||||
public int flags;
|
||||
}
|
||||
|
||||
internal struct WINDOWPLACEMENT
|
||||
{
|
||||
public uint length;
|
||||
public uint flags;
|
||||
public uint showCmd;
|
||||
public POINT ptMinPosition;
|
||||
public POINT ptMaxPosition;
|
||||
public RECT rcNormalPosition;
|
||||
}
|
||||
|
||||
internal struct POINT
|
||||
{
|
||||
public long x;
|
||||
public long y;
|
||||
}
|
||||
|
||||
internal struct RECT
|
||||
{
|
||||
public long left;
|
||||
public long top;
|
||||
public long right;
|
||||
public long bottom;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Helpers
|
||||
|
||||
public static int MAKELONG(int wLow, int wHigh)
|
||||
{
|
||||
return wLow | wHigh << 16;
|
||||
}
|
||||
|
||||
public static int MAKELPARAM(ref int wLow, ref int wHigh)
|
||||
{
|
||||
return MAKELONG(wLow, wHigh);
|
||||
}
|
||||
|
||||
public static int LOWORD(int value)
|
||||
{
|
||||
return value & 0xFFFF;
|
||||
}
|
||||
|
||||
public static int LOWORD(IntPtr value)
|
||||
{
|
||||
return LOWORD(value.ToInt32());
|
||||
}
|
||||
|
||||
public static int HIWORD(int value)
|
||||
{
|
||||
return value >> 16;
|
||||
}
|
||||
|
||||
public static int HIWORD(IntPtr value)
|
||||
{
|
||||
return HIWORD(value.ToInt32());
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constants
|
||||
|
||||
public const int TRUE = 1;
|
||||
|
||||
#region GetWindowLong
|
||||
|
||||
public const int GWL_STYLE = (-16);
|
||||
|
||||
#endregion
|
||||
|
||||
#region AppendMenu / ModifyMenu / DeleteMenu / RemoveMenu
|
||||
|
||||
public const int MF_BYCOMMAND = 0x0;
|
||||
public const int MF_BYPOSITION = 0x400;
|
||||
public const int MF_STRING = 0x0;
|
||||
public const int MF_POPUP = 0x10;
|
||||
public const int MF_SEPARATOR = 0x800;
|
||||
|
||||
#endregion
|
||||
|
||||
#region WM_LBUTTONDOWN / WM_LBUTTONUP
|
||||
|
||||
public const int MK_LBUTTON = 0x1;
|
||||
|
||||
#endregion
|
||||
|
||||
#region ShowWindow
|
||||
|
||||
public const uint SW_HIDE = 0;
|
||||
public const uint SW_SHOWNORMAL = 1;
|
||||
public const uint SW_SHOWMINIMIZED = 2;
|
||||
public const uint SW_SHOWMAXIMIZED = 3;
|
||||
public const uint SW_MAXIMIZE = 3;
|
||||
public const uint SW_SHOWNOACTIVATE = 4;
|
||||
public const uint SW_SHOW = 5;
|
||||
public const uint SW_MINIMIZE = 6;
|
||||
public const uint SW_SHOWMINNOACTIVE = 7;
|
||||
public const uint SW_SHOWNA = 8;
|
||||
public const uint SW_RESTORE = 9;
|
||||
|
||||
#endregion
|
||||
|
||||
#region SetWindowPos / WM_WINDOWPOSCHANGING / WM_WINDOWPOSCHANGED
|
||||
|
||||
/// <summary>
|
||||
/// Retains the current size (ignores the cx and cy parameters).
|
||||
/// </summary>
|
||||
public const int SWP_NOSIZE = 0x1;
|
||||
|
||||
/// <summary>
|
||||
/// Retains the current position (ignores the x and y parameters).
|
||||
/// </summary>
|
||||
public const int SWP_NOMOVE = 0x2;
|
||||
|
||||
/// <summary>
|
||||
/// Retains the current Z order (ignores the hWndInsertAfter parameter).
|
||||
/// </summary>
|
||||
public const int SWP_NOZORDER = 0x4;
|
||||
|
||||
/// <summary>
|
||||
/// Does not redraw changes. If this flag is set, no repainting of any kind occurs. This applies to the client area, the nonclient area (including the title bar and scroll bars), and any part of the parent window uncovered as a result of the window being moved. When this flag is set, the application must explicitly invalidate or redraw any parts of the window and parent window that need redrawing.
|
||||
/// </summary>
|
||||
public const int SWP_NOREDRAW = 0x8;
|
||||
|
||||
/// <summary>
|
||||
/// Does not activate the window. If this flag is not set, the window is activated and moved to the top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter parameter).
|
||||
/// </summary>
|
||||
public const int SWP_NOACTIVATE = 0x10;
|
||||
|
||||
/// <summary>
|
||||
/// Draws a frame (defined in the window's class description) around the window.
|
||||
/// </summary>
|
||||
public const int SWP_DRAWFRAME = 0x20;
|
||||
|
||||
/// <summary>
|
||||
/// Sends a WM_NCCALCSIZE message to the window, even if the window's size is not being changed. If this flag is not specified, WM_NCCALCSIZE is sent only when the window's size is being changed.
|
||||
/// </summary>
|
||||
public const int SWP_FRAMECHANGED = 0x20;
|
||||
|
||||
/// <summary>
|
||||
/// Displays the window.
|
||||
/// </summary>
|
||||
public const int SWP_SHOWWINDOW = 0x40;
|
||||
|
||||
/// <summary>
|
||||
/// Hides the window.
|
||||
/// </summary>
|
||||
public const int SWP_HIDEWINDOW = 0x80;
|
||||
|
||||
/// <summary>
|
||||
/// Discards the entire contents of the client area. If this flag is not specified, the valid contents of the client area are saved and copied back into the client area after the window is sized or repositioned.
|
||||
/// </summary>
|
||||
public const int SWP_NOCOPYBITS = 0x100;
|
||||
|
||||
/// <summary>
|
||||
/// Does not change the owner window's position in the Z order.
|
||||
/// </summary>
|
||||
public const int SWP_NOOWNERZORDER = 0x200;
|
||||
|
||||
/// <summary>
|
||||
/// Prevents the window from receiving the WM_WINDOWPOSCHANGING message.
|
||||
/// </summary>
|
||||
public const int SWP_NOSENDCHANGING = 0x400;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public const int SWP_NOCLIENTSIZE = 0x800;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public const int SWP_NOCLIENTMOVE = 0x1000;
|
||||
|
||||
/// <summary>
|
||||
/// Prevents generation of the WM_SYNCPAINT message.
|
||||
/// </summary>
|
||||
public const int SWP_DEFERERASE = 0x2000;
|
||||
|
||||
/// <summary>
|
||||
/// If the calling thread and the thread that owns the window are attached to different input queues, the system posts the request to the thread that owns the window. This prevents the calling thread from blocking its execution while other threads process the request.
|
||||
/// </summary>
|
||||
public const int SWP_ASYNCWINDOWPOS = 0x4000;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public const int SWP_STATECHANGED = 0x8000;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Window Placement Flags (WPF)
|
||||
|
||||
public const uint WPF_SETMINPOSITION = 0x1;
|
||||
public const uint WPF_RESTORETOMAXIMIZED = 0x2;
|
||||
public const uint WPF_ASYNCWINDOWPLACEMENT = 0x4;
|
||||
|
||||
#endregion
|
||||
|
||||
#region WM_ACTIVATE
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public const int WA_INACTIVE = 0x0;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public const int WA_ACTIVE = 0x1;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to both the window being activated and the window being deactivated.
|
||||
/// If the windows use the same input queue, the message is sent synchronously, first to the window procedure of the
|
||||
/// top-level window being deactivated, then to the window procedure of the top-level window being activated. If the
|
||||
/// windows use different input queues, the message is sent asynchronously, so the window is activated immediately.
|
||||
/// </summary>
|
||||
public const int WA_CLICKACTIVE = 0x2;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Window Messages
|
||||
|
||||
/// <summary>
|
||||
/// Sent when an application requests that a window be created by calling the CreateWindowEx or CreateWindow function. (The message is sent before the function returns.) The window procedure of the new window receives this message after the window is created, but before the window becomes visible.
|
||||
/// </summary>
|
||||
public const int WM_CREATE = 0x1;
|
||||
|
||||
/// <summary>
|
||||
/// Sent when a window is being destroyed. It is sent to the window procedure of the window being destroyed after the window is removed from the screen. This message is sent first to the window being destroyed and then to the child windows(if any) as they are destroyed.During the processing of the message, it can be assumed that all child windows still exist.
|
||||
/// </summary>
|
||||
public const int WM_DESTROY = 0x2;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to both the window being activated and the window being deactivated. If the windows use the same input queue, the message is sent synchronously, first to the window procedure of the top-level window being deactivated, then to the window procedure of the top-level window being activated. If the windows use different input queues, the message is sent asynchronously, so the window is activated immediately.
|
||||
/// </summary>
|
||||
public const int WM_ACTIVATE = 0x6;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public const int WM_SETTEXT = 0xC;
|
||||
|
||||
/// <summary>
|
||||
/// Copies the text that corresponds to a window into a buffer provided by the caller.
|
||||
/// </summary>
|
||||
public const int WM_GETTEXT = 0xD;
|
||||
|
||||
/// <summary>
|
||||
/// Sent as a signal that a window or an application should terminate.
|
||||
/// </summary>
|
||||
public const int WM_CLOSE = 0x10;
|
||||
|
||||
/// <summary>
|
||||
/// Sent when a window belonging to a different application than the active window is about to be activated. The message is sent to the application whose window is being activated and to the application whose window is being deactivated.
|
||||
/// </summary>
|
||||
public const int WM_ACTIVATEAPP = 0x1C;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to a window if the mouse causes the cursor to move within a window and mouse input is not captured.
|
||||
/// </summary>
|
||||
public const int WM_SETCURSOR = 0x20;
|
||||
|
||||
/// <summary>
|
||||
/// Sent when the cursor is in an inactive window and the user presses a mouse button. The parent window receives this message only if the child window passes it to the DefWindowProc function.
|
||||
/// </summary>
|
||||
public const int WM_MOUSEACTIVATE = 0x21;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to a window when the size or position of the window is about to change. An application can use this message to override the window's default maximized size and position, or its default minimum or maximum tracking size.
|
||||
/// </summary>
|
||||
public const int WM_GETMINMAXINFO = 0x24;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to a window whose size, position, or place in the Z order is about to change as a result of a call to the SetWindowPos function or another window-management function.
|
||||
/// </summary>
|
||||
public const int WM_WINDOWPOSCHANGING = 0x46;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to a window whose size, position, or place in the Z order has changed as a result of a call to the SetWindowPos function or another window-management function.
|
||||
/// </summary>
|
||||
public const int WM_WINDOWPOSCHANGED = 0x47;
|
||||
|
||||
/// <summary>
|
||||
/// Posted to the window with the keyboard focus when a nonsystem key is pressed. A nonsystem key is a key that is pressed when the ALT key is not pressed.
|
||||
/// </summary>
|
||||
public const int WM_KEYDOWN = 0x100;
|
||||
|
||||
/// <summary>
|
||||
/// Posted to the window with the keyboard focus when a nonsystem key is released. A nonsystem key is a key that is pressed when the ALT key is not pressed, or a keyboard key that is pressed when a window has the keyboard focus.
|
||||
/// </summary>
|
||||
public const int WM_KEYUP = 0x101;
|
||||
|
||||
/// <summary>
|
||||
/// Posted to the window with the keyboard focus when a WM_KEYDOWN message is translated by the TranslateMessage function. The WM_CHAR message contains the character code of the key that was pressed.
|
||||
/// </summary>
|
||||
public const int WM_CHAR = 0x102;
|
||||
|
||||
/// <summary>
|
||||
/// Sent when the user selects a command item from a menu, when a control sends a notification message to its parent window, or when an accelerator keystroke is translated.
|
||||
/// </summary>
|
||||
public const int WM_COMMAND = 0x111;
|
||||
|
||||
/// <summary>
|
||||
/// A window receives this message when the user chooses a command from the Window menu (formerly known as the system or control menu) or when the user chooses the maximize button, minimize button, restore button, or close button.
|
||||
/// </summary>
|
||||
public const int WM_SYSCOMMAND = 0x112;
|
||||
|
||||
/// <summary>
|
||||
/// Posted to a window when the cursor moves. If the mouse is not captured, the message is posted to the window that contains the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_MOUSEMOVE = 0x200;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user presses the left mouse button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_LBUTTONDOWN = 0x201;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user releases the left mouse button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_LBUTTONUP = 0x202;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user presses the right mouse button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_RBUTTONDOWN = 0x204;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user releases the right mouse button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_RBUTTONUP = 0x205;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user presses the middle mouse button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_MBUTTONDOWN = 0x207;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user releases the middle mouse button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_MBUTTONUP = 0x208;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user presses the first or second X button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_XBUTTONDOWN = 0x20B;
|
||||
|
||||
/// <summary>
|
||||
/// Posted when the user releases the first or second X button while the cursor is in the client area of a window. If the mouse is not captured, the message is posted to the window beneath the cursor. Otherwise, the message is posted to the window that has captured the mouse.
|
||||
/// </summary>
|
||||
public const int WM_XBUTTONUP = 0x20C;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to a window when a significant action occurs on a descendant window. This message is now extended to include the WM_POINTERDOWN event. When the child window is being created, the system sends WM_PARENTNOTIFY just before the CreateWindow or CreateWindowEx function that creates the window returns. When the child window is being destroyed, the system sends the message before any processing to destroy the window takes place.
|
||||
/// </summary>
|
||||
public const int WM_PARENTNOTIFY = 0x210;
|
||||
|
||||
/// <summary>
|
||||
/// Sent one time to a window after it enters the moving or sizing modal loop. The window enters the moving or sizing modal loop when the user clicks the window's title bar or sizing border, or when the window passes the WM_SYSCOMMAND message to the DefWindowProc function and the wParam parameter of the message specifies the SC_MOVE or SC_SIZE value. The operation is complete when DefWindowProc returns.
|
||||
/// </summary>
|
||||
public const int WM_ENTERSIZEMOVE = 0x231;
|
||||
|
||||
/// <summary>
|
||||
/// Sent one time to a window, after it has exited the moving or sizing modal loop. The window enters the moving or sizing modal loop when the user clicks the window's title bar or sizing border, or when the window passes the WM_SYSCOMMAND message to the DefWindowProc function and the wParam parameter of the message specifies the SC_MOVE or SC_SIZE value. The operation is complete when DefWindowProc returns.
|
||||
/// </summary>
|
||||
public const int WM_EXITSIZEMOVE = 0x232;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to the first window in the clipboard viewer chain when the content of the clipboard changes. This enables a clipboard viewer window to display the new content of the clipboard.
|
||||
/// </summary>
|
||||
public const int WM_DRAWCLIPBOARD = 0x308;
|
||||
|
||||
/// <summary>
|
||||
/// Sent to the first window in the clipboard viewer chain when a window is being removed from the chain.
|
||||
/// </summary>
|
||||
public const int WM_CHANGECBCHAIN = 0x30D;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Window Styles
|
||||
|
||||
public const int WS_MAXIMIZE = 0x1000000;
|
||||
public const int WS_VISIBLE = 0x10000000;
|
||||
public const int WS_CHILD = 0x40000000;
|
||||
public const int WS_EX_MDICHILD = 0x40;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Virtual Key Codes
|
||||
|
||||
public const int VK_CONTROL = 0x11;
|
||||
public const int VK_C = 0x67;
|
||||
|
||||
#endregion
|
||||
|
||||
#region EM
|
||||
|
||||
public const uint ECM_FIRST = 0x1500;
|
||||
public const uint EM_SETCUEBANNER = ECM_FIRST + 1;
|
||||
public const uint EM_GETCUEBANNER = ECM_FIRST + 2;
|
||||
|
||||
#endregion
|
||||
|
||||
#region LB
|
||||
|
||||
public const int LB_ERR = -1;
|
||||
public const int LB_SELECTSTRING = 0x18C;
|
||||
|
||||
#endregion
|
||||
|
||||
#region TCM
|
||||
|
||||
internal const int TCM_ADJUSTRECT = 0x1328;
|
||||
|
||||
#endregion
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -1,256 +0,0 @@
|
||||
using System;
|
||||
using System.Security;
|
||||
using System.Xml.Linq;
|
||||
using mRemoteNG.Connection;
|
||||
using mRemoteNG.Container;
|
||||
using mRemoteNG.Security;
|
||||
|
||||
namespace mRemoteNG.Config.Serializers.ConnectionSerializers.Xml
|
||||
{
|
||||
// ReSharper disable once InconsistentNaming
|
||||
public class XmlConnectionNodeSerializer26 : ISerializer<ConnectionInfo, XElement>
|
||||
{
|
||||
private readonly ICryptographyProvider _cryptographyProvider;
|
||||
private readonly SecureString _encryptionKey;
|
||||
private readonly SaveFilter _saveFilter;
|
||||
|
||||
public Version Version { get; } = new Version(2, 6);
|
||||
|
||||
public XmlConnectionNodeSerializer26(ICryptographyProvider cryptographyProvider, SecureString encryptionKey, SaveFilter saveFilter)
|
||||
{
|
||||
if (cryptographyProvider == null)
|
||||
throw new ArgumentNullException(nameof(cryptographyProvider));
|
||||
if (encryptionKey == null)
|
||||
throw new ArgumentNullException(nameof(encryptionKey));
|
||||
if (saveFilter == null)
|
||||
throw new ArgumentNullException(nameof(saveFilter));
|
||||
|
||||
_cryptographyProvider = cryptographyProvider;
|
||||
_encryptionKey = encryptionKey;
|
||||
_saveFilter = saveFilter;
|
||||
}
|
||||
|
||||
public XElement Serialize(ConnectionInfo connectionInfo)
|
||||
{
|
||||
var element = new XElement(XName.Get("Node", ""));
|
||||
SetElementAttributes(element, connectionInfo);
|
||||
SetInheritanceAttributes(element, connectionInfo);
|
||||
return element;
|
||||
}
|
||||
|
||||
private void SetElementAttributes(XContainer element, ConnectionInfo connectionInfo)
|
||||
{
|
||||
var nodeAsContainer = connectionInfo as ContainerInfo;
|
||||
element.Add(new XAttribute("Name", connectionInfo.Name));
|
||||
element.Add(new XAttribute("Type", connectionInfo.GetTreeNodeType().ToString()));
|
||||
if (nodeAsContainer != null)
|
||||
element.Add(new XAttribute("Expanded", nodeAsContainer.IsExpanded.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("Descr", connectionInfo.Description));
|
||||
element.Add(new XAttribute("Icon", connectionInfo.Icon));
|
||||
element.Add(new XAttribute("Panel", connectionInfo.Panel));
|
||||
element.Add(new XAttribute("Id", connectionInfo.ConstantID));
|
||||
|
||||
element.Add(_saveFilter.SaveUsername
|
||||
? new XAttribute("Username", connectionInfo.Username)
|
||||
: new XAttribute("Username", ""));
|
||||
|
||||
element.Add(_saveFilter.SaveDomain
|
||||
? new XAttribute("Domain", connectionInfo.Domain)
|
||||
: new XAttribute("Domain", ""));
|
||||
|
||||
if (_saveFilter.SavePassword && !connectionInfo.Inheritance.Password)
|
||||
element.Add(new XAttribute("Password", _cryptographyProvider.Encrypt(connectionInfo.Password, _encryptionKey)));
|
||||
else
|
||||
element.Add(new XAttribute("Password", ""));
|
||||
|
||||
element.Add(new XAttribute("Hostname", connectionInfo.Hostname));
|
||||
element.Add(new XAttribute("Protocol", connectionInfo.Protocol));
|
||||
element.Add(new XAttribute("SSHTunnelConnectionName", connectionInfo.SSHTunnelConnectionName));
|
||||
element.Add(new XAttribute("SSHOptions", connectionInfo.SSHOptions));
|
||||
element.Add(new XAttribute("PuttySession", connectionInfo.PuttySession));
|
||||
element.Add(new XAttribute("Port", connectionInfo.Port));
|
||||
element.Add(new XAttribute("ConnectToConsole", connectionInfo.UseConsoleSession.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("UseCredSsp", connectionInfo.UseCredSsp.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RenderingEngine", connectionInfo.RenderingEngine));
|
||||
element.Add(new XAttribute("RDPAuthenticationLevel", connectionInfo.RDPAuthenticationLevel));
|
||||
element.Add(new XAttribute("RDPMinutesToIdleTimeout", connectionInfo.RDPMinutesToIdleTimeout));
|
||||
element.Add(new XAttribute("RDPAlertIdleTimeout", connectionInfo.RDPAlertIdleTimeout.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("LoadBalanceInfo", connectionInfo.LoadBalanceInfo));
|
||||
element.Add(new XAttribute("Colors", connectionInfo.Colors));
|
||||
element.Add(new XAttribute("Resolution", connectionInfo.Resolution));
|
||||
element.Add(new XAttribute("AutomaticResize", connectionInfo.AutomaticResize.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisplayWallpaper", connectionInfo.DisplayWallpaper.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisplayThemes", connectionInfo.DisplayThemes.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("EnableFontSmoothing", connectionInfo.EnableFontSmoothing.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("EnableDesktopComposition", connectionInfo.EnableDesktopComposition.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("CacheBitmaps", connectionInfo.CacheBitmaps.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectDiskDrives", connectionInfo.RedirectDiskDrives.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectPorts", connectionInfo.RedirectPorts.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectPrinters", connectionInfo.RedirectPrinters.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectClipboard", connectionInfo.RedirectClipboard.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectSmartCards", connectionInfo.RedirectSmartCards.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectSound", connectionInfo.RedirectSound.ToString()));
|
||||
element.Add(new XAttribute("SoundQuality", connectionInfo.SoundQuality.ToString()));
|
||||
element.Add(new XAttribute("RedirectKeys", connectionInfo.RedirectKeys.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("Connected", (connectionInfo.OpenConnections.Count > 0).ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("PreExtApp", connectionInfo.PreExtApp));
|
||||
element.Add(new XAttribute("PostExtApp", connectionInfo.PostExtApp));
|
||||
element.Add(new XAttribute("MacAddress", connectionInfo.MacAddress));
|
||||
element.Add(new XAttribute("UserField", connectionInfo.UserField));
|
||||
element.Add(new XAttribute("ExtApp", connectionInfo.ExtApp));
|
||||
element.Add(new XAttribute("StartProgram", connectionInfo.StartProgram));
|
||||
element.Add(new XAttribute("VNCCompression", connectionInfo.VNCCompression));
|
||||
element.Add(new XAttribute("VNCEncoding", connectionInfo.VNCEncoding));
|
||||
element.Add(new XAttribute("VNCAuthMode", connectionInfo.VNCAuthMode));
|
||||
element.Add(new XAttribute("VNCProxyType", connectionInfo.VNCProxyType));
|
||||
element.Add(new XAttribute("VNCProxyIP", connectionInfo.VNCProxyIP));
|
||||
element.Add(new XAttribute("VNCProxyPort", connectionInfo.VNCProxyPort));
|
||||
|
||||
element.Add(_saveFilter.SaveUsername
|
||||
? new XAttribute("VNCProxyUsername", connectionInfo.VNCProxyUsername)
|
||||
: new XAttribute("VNCProxyUsername", ""));
|
||||
|
||||
element.Add(_saveFilter.SavePassword
|
||||
? new XAttribute("VNCProxyPassword", _cryptographyProvider.Encrypt(connectionInfo.VNCProxyPassword, _encryptionKey))
|
||||
: new XAttribute("VNCProxyPassword", ""));
|
||||
|
||||
element.Add(new XAttribute("VNCColors", connectionInfo.VNCColors));
|
||||
element.Add(new XAttribute("VNCSmartSizeMode", connectionInfo.VNCSmartSizeMode));
|
||||
element.Add(new XAttribute("VNCViewOnly", connectionInfo.VNCViewOnly.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RDGatewayUsageMethod", connectionInfo.RDGatewayUsageMethod));
|
||||
element.Add(new XAttribute("RDGatewayHostname", connectionInfo.RDGatewayHostname));
|
||||
element.Add(new XAttribute("RDGatewayUseConnectionCredentials", connectionInfo.RDGatewayUseConnectionCredentials));
|
||||
|
||||
element.Add(_saveFilter.SaveUsername
|
||||
? new XAttribute("RDGatewayUsername", connectionInfo.RDGatewayUsername)
|
||||
: new XAttribute("RDGatewayUsername", ""));
|
||||
|
||||
element.Add(_saveFilter.SavePassword
|
||||
? new XAttribute("RDGatewayPassword", _cryptographyProvider.Encrypt(connectionInfo.RDGatewayPassword, _encryptionKey))
|
||||
: new XAttribute("RDGatewayPassword", ""));
|
||||
|
||||
element.Add(_saveFilter.SaveDomain
|
||||
? new XAttribute("RDGatewayDomain", connectionInfo.RDGatewayDomain)
|
||||
: new XAttribute("RDGatewayDomain", ""));
|
||||
}
|
||||
|
||||
private void SetInheritanceAttributes(XContainer element, IInheritable connectionInfo)
|
||||
{
|
||||
if (_saveFilter.SaveInheritance)
|
||||
{
|
||||
var inheritance = connectionInfo.Inheritance;
|
||||
|
||||
if (inheritance.CacheBitmaps)
|
||||
element.Add(new XAttribute("InheritCacheBitmaps", inheritance.CacheBitmaps.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Colors)
|
||||
element.Add(new XAttribute("InheritColors", inheritance.Colors.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Description)
|
||||
element.Add(new XAttribute("InheritDescription", inheritance.Description.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisplayThemes)
|
||||
element.Add(new XAttribute("InheritDisplayThemes", inheritance.DisplayThemes.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisplayWallpaper)
|
||||
element.Add(new XAttribute("InheritDisplayWallpaper", inheritance.DisplayWallpaper.ToString().ToLowerInvariant()));
|
||||
if (inheritance.EnableFontSmoothing)
|
||||
element.Add(new XAttribute("InheritEnableFontSmoothing", inheritance.EnableFontSmoothing.ToString().ToLowerInvariant()));
|
||||
if (inheritance.EnableDesktopComposition)
|
||||
element.Add(new XAttribute("InheritEnableDesktopComposition", inheritance.EnableDesktopComposition.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Domain)
|
||||
element.Add(new XAttribute("InheritDomain", inheritance.Domain.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Icon)
|
||||
element.Add(new XAttribute("InheritIcon", inheritance.Icon.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Panel)
|
||||
element.Add(new XAttribute("InheritPanel", inheritance.Panel.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Password)
|
||||
element.Add(new XAttribute("InheritPassword", inheritance.Password.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Port)
|
||||
element.Add(new XAttribute("InheritPort", inheritance.Port.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Protocol)
|
||||
element.Add(new XAttribute("InheritProtocol", inheritance.Protocol.ToString().ToLowerInvariant()));
|
||||
if (inheritance.SSHTunnelConnectionName)
|
||||
element.Add(new XAttribute("InheritSSHTunnelConnectionName", inheritance.SSHTunnelConnectionName.ToString().ToLowerInvariant()));
|
||||
if (inheritance.SSHOptions)
|
||||
element.Add(new XAttribute("InheritSSHOptions", inheritance.SSHOptions.ToString().ToLowerInvariant()));
|
||||
if (inheritance.PuttySession)
|
||||
element.Add(new XAttribute("InheritPuttySession", inheritance.PuttySession.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectDiskDrives)
|
||||
element.Add(new XAttribute("InheritRedirectDiskDrives", inheritance.RedirectDiskDrives.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectKeys)
|
||||
element.Add(new XAttribute("InheritRedirectKeys", inheritance.RedirectKeys.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectPorts)
|
||||
element.Add(new XAttribute("InheritRedirectPorts", inheritance.RedirectPorts.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectPrinters)
|
||||
element.Add(new XAttribute("InheritRedirectPrinters", inheritance.RedirectPrinters.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectSmartCards)
|
||||
element.Add(new XAttribute("InheritRedirectSmartCards", inheritance.RedirectSmartCards.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectSound)
|
||||
element.Add(new XAttribute("InheritRedirectSound", inheritance.RedirectSound.ToString().ToLowerInvariant()));
|
||||
if (inheritance.SoundQuality)
|
||||
element.Add(new XAttribute("InheritSoundQuality", inheritance.SoundQuality.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Resolution)
|
||||
element.Add(new XAttribute("InheritResolution", inheritance.Resolution.ToString().ToLowerInvariant()));
|
||||
if (inheritance.AutomaticResize)
|
||||
element.Add(new XAttribute("InheritAutomaticResize", inheritance.AutomaticResize.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UseConsoleSession)
|
||||
element.Add(new XAttribute("InheritUseConsoleSession", inheritance.UseConsoleSession.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UseCredSsp)
|
||||
element.Add(new XAttribute("InheritUseCredSsp", inheritance.UseCredSsp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RenderingEngine)
|
||||
element.Add(new XAttribute("InheritRenderingEngine", inheritance.RenderingEngine.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Username)
|
||||
element.Add(new XAttribute("InheritUsername", inheritance.Username.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDPAuthenticationLevel)
|
||||
element.Add(new XAttribute("InheritRDPAuthenticationLevel", inheritance.RDPAuthenticationLevel.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDPMinutesToIdleTimeout)
|
||||
element.Add(new XAttribute("InheritRDPMinutesToIdleTimeout", inheritance.RDPMinutesToIdleTimeout.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDPAlertIdleTimeout)
|
||||
element.Add(new XAttribute("InheritRDPAlertIdleTimeout", inheritance.RDPAlertIdleTimeout.ToString().ToLowerInvariant()));
|
||||
if (inheritance.LoadBalanceInfo)
|
||||
element.Add(new XAttribute("InheritLoadBalanceInfo", inheritance.LoadBalanceInfo.ToString().ToLowerInvariant()));
|
||||
if (inheritance.PreExtApp)
|
||||
element.Add(new XAttribute("InheritPreExtApp", inheritance.PreExtApp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.PostExtApp)
|
||||
element.Add(new XAttribute("InheritPostExtApp", inheritance.PostExtApp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.MacAddress)
|
||||
element.Add(new XAttribute("InheritMacAddress", inheritance.MacAddress.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UserField)
|
||||
element.Add(new XAttribute("InheritUserField", inheritance.UserField.ToString().ToLowerInvariant()));
|
||||
if (inheritance.ExtApp)
|
||||
element.Add(new XAttribute("InheritExtApp", inheritance.ExtApp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCCompression)
|
||||
element.Add(new XAttribute("InheritVNCCompression", inheritance.VNCCompression.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCEncoding)
|
||||
element.Add(new XAttribute("InheritVNCEncoding", inheritance.VNCEncoding.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCAuthMode)
|
||||
element.Add(new XAttribute("InheritVNCAuthMode", inheritance.VNCAuthMode.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyType)
|
||||
element.Add(new XAttribute("InheritVNCProxyType", inheritance.VNCProxyType.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyIP)
|
||||
element.Add(new XAttribute("InheritVNCProxyIP", inheritance.VNCProxyIP.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyPort)
|
||||
element.Add(new XAttribute("InheritVNCProxyPort", inheritance.VNCProxyPort.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyUsername)
|
||||
element.Add(new XAttribute("InheritVNCProxyUsername", inheritance.VNCProxyUsername.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyPassword)
|
||||
element.Add(new XAttribute("InheritVNCProxyPassword", inheritance.VNCProxyPassword.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCColors)
|
||||
element.Add(new XAttribute("InheritVNCColors", inheritance.VNCColors.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCSmartSizeMode)
|
||||
element.Add(new XAttribute("InheritVNCSmartSizeMode", inheritance.VNCSmartSizeMode.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCViewOnly)
|
||||
element.Add(new XAttribute("InheritVNCViewOnly", inheritance.VNCViewOnly.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayUsageMethod)
|
||||
element.Add(new XAttribute("InheritRDGatewayUsageMethod", inheritance.RDGatewayUsageMethod.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayHostname)
|
||||
element.Add(new XAttribute("InheritRDGatewayHostname", inheritance.RDGatewayHostname.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayUseConnectionCredentials)
|
||||
element.Add(new XAttribute("InheritRDGatewayUseConnectionCredentials", inheritance.RDGatewayUseConnectionCredentials.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayUsername)
|
||||
element.Add(new XAttribute("InheritRDGatewayUsername", inheritance.RDGatewayUsername.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayPassword)
|
||||
element.Add(new XAttribute("InheritRDGatewayPassword", inheritance.RDGatewayPassword.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayDomain)
|
||||
element.Add(new XAttribute("InheritRDGatewayDomain", inheritance.RDGatewayDomain.ToString().ToLowerInvariant()));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,294 +0,0 @@
|
||||
using System;
|
||||
using System.Security;
|
||||
using System.Xml.Linq;
|
||||
using mRemoteNG.App;
|
||||
using mRemoteNG.Connection;
|
||||
using mRemoteNG.Container;
|
||||
using mRemoteNG.Security;
|
||||
|
||||
namespace mRemoteNG.Config.Serializers.ConnectionSerializers.Xml
|
||||
{
|
||||
// ReSharper disable once InconsistentNaming
|
||||
public class XmlConnectionNodeSerializer27 : ISerializer<ConnectionInfo, XElement>
|
||||
{
|
||||
private readonly ICryptographyProvider _cryptographyProvider;
|
||||
private readonly SecureString _encryptionKey;
|
||||
private readonly SaveFilter _saveFilter;
|
||||
|
||||
public Version Version { get; } = new Version(2, 7);
|
||||
|
||||
public XmlConnectionNodeSerializer27(ICryptographyProvider cryptographyProvider,
|
||||
SecureString encryptionKey,
|
||||
SaveFilter saveFilter)
|
||||
{
|
||||
if (cryptographyProvider == null)
|
||||
throw new ArgumentNullException(nameof(cryptographyProvider));
|
||||
if (encryptionKey == null)
|
||||
throw new ArgumentNullException(nameof(encryptionKey));
|
||||
if (saveFilter == null)
|
||||
throw new ArgumentNullException(nameof(saveFilter));
|
||||
|
||||
_cryptographyProvider = cryptographyProvider;
|
||||
_encryptionKey = encryptionKey;
|
||||
_saveFilter = saveFilter;
|
||||
}
|
||||
|
||||
public XElement Serialize(ConnectionInfo connectionInfo)
|
||||
{
|
||||
var element = new XElement(XName.Get("Node", ""));
|
||||
SetElementAttributes(element, connectionInfo);
|
||||
SetInheritanceAttributes(element, connectionInfo);
|
||||
return element;
|
||||
}
|
||||
|
||||
private void SetElementAttributes(XContainer element, ConnectionInfo connectionInfo)
|
||||
{
|
||||
var nodeAsContainer = connectionInfo as ContainerInfo;
|
||||
element.Add(new XAttribute("Name", connectionInfo.Name));
|
||||
element.Add(new XAttribute("VmId", connectionInfo.VmId));
|
||||
element.Add(new XAttribute("UseVmId", connectionInfo.UseVmId));
|
||||
element.Add(new XAttribute("UseEnhancedMode", connectionInfo.UseVmId));
|
||||
element.Add(new XAttribute("Type", connectionInfo.GetTreeNodeType().ToString()));
|
||||
if (nodeAsContainer != null)
|
||||
element.Add(new XAttribute("Expanded", nodeAsContainer.IsExpanded.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("Descr", connectionInfo.Description));
|
||||
element.Add(new XAttribute("Icon", connectionInfo.Icon));
|
||||
element.Add(new XAttribute("Panel", connectionInfo.Panel));
|
||||
element.Add(new XAttribute("Id", connectionInfo.ConstantID));
|
||||
|
||||
if (!Runtime.UseCredentialManager)
|
||||
{
|
||||
element.Add(_saveFilter.SaveUsername
|
||||
? new XAttribute("Username", connectionInfo.Username)
|
||||
: new XAttribute("Username", ""));
|
||||
|
||||
element.Add(_saveFilter.SaveDomain
|
||||
? new XAttribute("Domain", connectionInfo.Domain)
|
||||
: new XAttribute("Domain", ""));
|
||||
|
||||
if (_saveFilter.SavePassword && !connectionInfo.Inheritance.Password)
|
||||
element.Add(new XAttribute("Password", _cryptographyProvider.Encrypt(connectionInfo.Password, _encryptionKey)));
|
||||
else
|
||||
element.Add(new XAttribute("Password", ""));
|
||||
}
|
||||
|
||||
element.Add(new XAttribute("Hostname", connectionInfo.Hostname));
|
||||
element.Add(new XAttribute("Protocol", connectionInfo.Protocol));
|
||||
element.Add(new XAttribute("RdpVersion", connectionInfo.RdpVersion.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("SSHTunnelConnectionName", connectionInfo.SSHTunnelConnectionName));
|
||||
element.Add(new XAttribute("SSHOptions", connectionInfo.SSHOptions));
|
||||
element.Add(new XAttribute("PuttySession", connectionInfo.PuttySession));
|
||||
element.Add(new XAttribute("Port", connectionInfo.Port));
|
||||
element.Add(new XAttribute("ConnectToConsole", connectionInfo.UseConsoleSession.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("UseCredSsp", connectionInfo.UseCredSsp.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RenderingEngine", connectionInfo.RenderingEngine));
|
||||
element.Add(new XAttribute("RDPAuthenticationLevel", connectionInfo.RDPAuthenticationLevel));
|
||||
element.Add(new XAttribute("RDPMinutesToIdleTimeout", connectionInfo.RDPMinutesToIdleTimeout));
|
||||
element.Add(new XAttribute("RDPAlertIdleTimeout", connectionInfo.RDPAlertIdleTimeout.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("LoadBalanceInfo", connectionInfo.LoadBalanceInfo));
|
||||
element.Add(new XAttribute("Colors", connectionInfo.Colors));
|
||||
element.Add(new XAttribute("Resolution", connectionInfo.Resolution));
|
||||
element.Add(new XAttribute("AutomaticResize", connectionInfo.AutomaticResize.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisplayWallpaper", connectionInfo.DisplayWallpaper.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisplayThemes", connectionInfo.DisplayThemes.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("EnableFontSmoothing", connectionInfo.EnableFontSmoothing.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("EnableDesktopComposition", connectionInfo.EnableDesktopComposition.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisableFullWindowDrag", connectionInfo.DisableFullWindowDrag.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisableMenuAnimations", connectionInfo.DisableMenuAnimations.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisableCursorShadow", connectionInfo.DisableCursorShadow.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("DisableCursorBlinking", connectionInfo.DisableCursorBlinking.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("CacheBitmaps", connectionInfo.CacheBitmaps.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectDiskDrives", connectionInfo.RedirectDiskDrives.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectPorts", connectionInfo.RedirectPorts.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectPrinters", connectionInfo.RedirectPrinters.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectClipboard", connectionInfo.RedirectClipboard.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectSmartCards", connectionInfo.RedirectSmartCards.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectSound", connectionInfo.RedirectSound.ToString()));
|
||||
element.Add(new XAttribute("SoundQuality", connectionInfo.SoundQuality.ToString()));
|
||||
element.Add(new XAttribute("RedirectAudioCapture", connectionInfo.RedirectAudioCapture.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RedirectKeys", connectionInfo.RedirectKeys.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("Connected", (connectionInfo.OpenConnections.Count > 0).ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("PreExtApp", connectionInfo.PreExtApp));
|
||||
element.Add(new XAttribute("PostExtApp", connectionInfo.PostExtApp));
|
||||
element.Add(new XAttribute("MacAddress", connectionInfo.MacAddress));
|
||||
element.Add(new XAttribute("UserField", connectionInfo.UserField));
|
||||
element.Add(new XAttribute("Favorite", connectionInfo.Favorite));
|
||||
element.Add(new XAttribute("ExtApp", connectionInfo.ExtApp));
|
||||
element.Add(new XAttribute("StartProgram", connectionInfo.StartProgram));
|
||||
element.Add(new XAttribute("VNCCompression", connectionInfo.VNCCompression));
|
||||
element.Add(new XAttribute("VNCEncoding", connectionInfo.VNCEncoding));
|
||||
element.Add(new XAttribute("VNCAuthMode", connectionInfo.VNCAuthMode));
|
||||
element.Add(new XAttribute("VNCProxyType", connectionInfo.VNCProxyType));
|
||||
element.Add(new XAttribute("VNCProxyIP", connectionInfo.VNCProxyIP));
|
||||
element.Add(new XAttribute("VNCProxyPort", connectionInfo.VNCProxyPort));
|
||||
|
||||
element.Add(_saveFilter.SaveUsername
|
||||
? new XAttribute("VNCProxyUsername", connectionInfo.VNCProxyUsername)
|
||||
: new XAttribute("VNCProxyUsername", ""));
|
||||
|
||||
element.Add(_saveFilter.SavePassword
|
||||
? new XAttribute("VNCProxyPassword", _cryptographyProvider.Encrypt(connectionInfo.VNCProxyPassword, _encryptionKey))
|
||||
: new XAttribute("VNCProxyPassword", ""));
|
||||
|
||||
element.Add(new XAttribute("VNCColors", connectionInfo.VNCColors));
|
||||
element.Add(new XAttribute("VNCSmartSizeMode", connectionInfo.VNCSmartSizeMode));
|
||||
element.Add(new XAttribute("VNCViewOnly", connectionInfo.VNCViewOnly.ToString().ToLowerInvariant()));
|
||||
element.Add(new XAttribute("RDGatewayUsageMethod", connectionInfo.RDGatewayUsageMethod));
|
||||
element.Add(new XAttribute("RDGatewayHostname", connectionInfo.RDGatewayHostname));
|
||||
element.Add(new XAttribute("RDGatewayUseConnectionCredentials", connectionInfo.RDGatewayUseConnectionCredentials));
|
||||
|
||||
element.Add(_saveFilter.SaveUsername
|
||||
? new XAttribute("RDGatewayUsername", connectionInfo.RDGatewayUsername)
|
||||
: new XAttribute("RDGatewayUsername", ""));
|
||||
|
||||
element.Add(_saveFilter.SavePassword
|
||||
? new XAttribute("RDGatewayPassword", _cryptographyProvider.Encrypt(connectionInfo.RDGatewayPassword, _encryptionKey))
|
||||
: new XAttribute("RDGatewayPassword", ""));
|
||||
|
||||
element.Add(_saveFilter.SaveDomain
|
||||
? new XAttribute("RDGatewayDomain", connectionInfo.RDGatewayDomain)
|
||||
: new XAttribute("RDGatewayDomain", ""));
|
||||
}
|
||||
|
||||
private void SetInheritanceAttributes(XContainer element, IInheritable connectionInfo)
|
||||
{
|
||||
if (_saveFilter.SaveInheritance)
|
||||
{
|
||||
var inheritance = connectionInfo.Inheritance;
|
||||
|
||||
if (inheritance.CacheBitmaps)
|
||||
element.Add(new XAttribute("InheritCacheBitmaps", inheritance.CacheBitmaps.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Colors)
|
||||
element.Add(new XAttribute("InheritColors", inheritance.Colors.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Description)
|
||||
element.Add(new XAttribute("InheritDescription", inheritance.Description.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisplayThemes)
|
||||
element.Add(new XAttribute("InheritDisplayThemes", inheritance.DisplayThemes.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisplayWallpaper)
|
||||
element.Add(new XAttribute("InheritDisplayWallpaper", inheritance.DisplayWallpaper.ToString().ToLowerInvariant()));
|
||||
if (inheritance.EnableFontSmoothing)
|
||||
element.Add(new XAttribute("InheritEnableFontSmoothing", inheritance.EnableFontSmoothing.ToString().ToLowerInvariant()));
|
||||
if (inheritance.EnableDesktopComposition)
|
||||
element.Add(new XAttribute("InheritEnableDesktopComposition", inheritance.EnableDesktopComposition.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisableFullWindowDrag)
|
||||
element.Add(new XAttribute("InheritDisableFullWindowDrag", inheritance.DisableFullWindowDrag.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisableMenuAnimations)
|
||||
element.Add(new XAttribute("InheritDisableMenuAnimations", inheritance.DisableMenuAnimations.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisableCursorShadow)
|
||||
element.Add(new XAttribute("InheritDisableCursorShadow", inheritance.DisableCursorShadow.ToString().ToLowerInvariant()));
|
||||
if (inheritance.DisableCursorBlinking)
|
||||
element.Add(new XAttribute("InheritDisableCursorBlinking", inheritance.DisableCursorBlinking.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Domain)
|
||||
element.Add(new XAttribute("InheritDomain", inheritance.Domain.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Icon)
|
||||
element.Add(new XAttribute("InheritIcon", inheritance.Icon.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Panel)
|
||||
element.Add(new XAttribute("InheritPanel", inheritance.Panel.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Password)
|
||||
element.Add(new XAttribute("InheritPassword", inheritance.Password.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Port)
|
||||
element.Add(new XAttribute("InheritPort", inheritance.Port.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Protocol)
|
||||
element.Add(new XAttribute("InheritProtocol", inheritance.Protocol.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RdpVersion)
|
||||
element.Add(new XAttribute("InheritRdpVersion", inheritance.RdpVersion.ToString().ToLowerInvariant()));
|
||||
if (inheritance.SSHTunnelConnectionName)
|
||||
element.Add(new XAttribute("InheritSSHTunnelConnectionName", inheritance.SSHTunnelConnectionName.ToString().ToLowerInvariant()));
|
||||
if (inheritance.SSHOptions)
|
||||
element.Add(new XAttribute("InheritSSHOptions", inheritance.SSHOptions.ToString().ToLowerInvariant()));
|
||||
if (inheritance.PuttySession)
|
||||
element.Add(new XAttribute("InheritPuttySession", inheritance.PuttySession.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectDiskDrives)
|
||||
element.Add(new XAttribute("InheritRedirectDiskDrives", inheritance.RedirectDiskDrives.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectKeys)
|
||||
element.Add(new XAttribute("InheritRedirectKeys", inheritance.RedirectKeys.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectPorts)
|
||||
element.Add(new XAttribute("InheritRedirectPorts", inheritance.RedirectPorts.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectPrinters)
|
||||
element.Add(new XAttribute("InheritRedirectPrinters", inheritance.RedirectPrinters.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectClipboard)
|
||||
element.Add(new XAttribute("InheritRedirectClipboard", inheritance.RedirectClipboard.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectSmartCards)
|
||||
element.Add(new XAttribute("InheritRedirectSmartCards", inheritance.RedirectSmartCards.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectSound)
|
||||
element.Add(new XAttribute("InheritRedirectSound", inheritance.RedirectSound.ToString().ToLowerInvariant()));
|
||||
if (inheritance.SoundQuality)
|
||||
element.Add(new XAttribute("InheritSoundQuality", inheritance.SoundQuality.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RedirectAudioCapture)
|
||||
element.Add(new XAttribute("InheritRedirectAudioCapture", inheritance.RedirectAudioCapture.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Resolution)
|
||||
element.Add(new XAttribute("InheritResolution", inheritance.Resolution.ToString().ToLowerInvariant()));
|
||||
if (inheritance.AutomaticResize)
|
||||
element.Add(new XAttribute("InheritAutomaticResize", inheritance.AutomaticResize.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UseConsoleSession)
|
||||
element.Add(new XAttribute("InheritUseConsoleSession", inheritance.UseConsoleSession.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UseCredSsp)
|
||||
element.Add(new XAttribute("InheritUseCredSsp", inheritance.UseCredSsp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RenderingEngine)
|
||||
element.Add(new XAttribute("InheritRenderingEngine", inheritance.RenderingEngine.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Username)
|
||||
element.Add(new XAttribute("InheritUsername", inheritance.Username.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDPAuthenticationLevel)
|
||||
element.Add(new XAttribute("InheritRDPAuthenticationLevel", inheritance.RDPAuthenticationLevel.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDPMinutesToIdleTimeout)
|
||||
element.Add(new XAttribute("InheritRDPMinutesToIdleTimeout", inheritance.RDPMinutesToIdleTimeout.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDPAlertIdleTimeout)
|
||||
element.Add(new XAttribute("InheritRDPAlertIdleTimeout", inheritance.RDPAlertIdleTimeout.ToString().ToLowerInvariant()));
|
||||
if (inheritance.LoadBalanceInfo)
|
||||
element.Add(new XAttribute("InheritLoadBalanceInfo", inheritance.LoadBalanceInfo.ToString().ToLowerInvariant()));
|
||||
if (inheritance.PreExtApp)
|
||||
element.Add(new XAttribute("InheritPreExtApp", inheritance.PreExtApp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.PostExtApp)
|
||||
element.Add(new XAttribute("InheritPostExtApp", inheritance.PostExtApp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.MacAddress)
|
||||
element.Add(new XAttribute("InheritMacAddress", inheritance.MacAddress.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UserField)
|
||||
element.Add(new XAttribute("InheritUserField", inheritance.UserField.ToString().ToLowerInvariant()));
|
||||
if (inheritance.Favorite)
|
||||
element.Add(new XAttribute("InheritFavorite", inheritance.Favorite.ToString().ToLowerInvariant()));
|
||||
if (inheritance.ExtApp)
|
||||
element.Add(new XAttribute("InheritExtApp", inheritance.ExtApp.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCCompression)
|
||||
element.Add(new XAttribute("InheritVNCCompression", inheritance.VNCCompression.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCEncoding)
|
||||
element.Add(new XAttribute("InheritVNCEncoding", inheritance.VNCEncoding.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCAuthMode)
|
||||
element.Add(new XAttribute("InheritVNCAuthMode", inheritance.VNCAuthMode.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyType)
|
||||
element.Add(new XAttribute("InheritVNCProxyType", inheritance.VNCProxyType.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyIP)
|
||||
element.Add(new XAttribute("InheritVNCProxyIP", inheritance.VNCProxyIP.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyPort)
|
||||
element.Add(new XAttribute("InheritVNCProxyPort", inheritance.VNCProxyPort.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyUsername)
|
||||
element.Add(new XAttribute("InheritVNCProxyUsername", inheritance.VNCProxyUsername.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCProxyPassword)
|
||||
element.Add(new XAttribute("InheritVNCProxyPassword", inheritance.VNCProxyPassword.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCColors)
|
||||
element.Add(new XAttribute("InheritVNCColors", inheritance.VNCColors.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCSmartSizeMode)
|
||||
element.Add(new XAttribute("InheritVNCSmartSizeMode", inheritance.VNCSmartSizeMode.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VNCViewOnly)
|
||||
element.Add(new XAttribute("InheritVNCViewOnly", inheritance.VNCViewOnly.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayUsageMethod)
|
||||
element.Add(new XAttribute("InheritRDGatewayUsageMethod", inheritance.RDGatewayUsageMethod.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayHostname)
|
||||
element.Add(new XAttribute("InheritRDGatewayHostname", inheritance.RDGatewayHostname.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayUseConnectionCredentials)
|
||||
element.Add(new XAttribute("InheritRDGatewayUseConnectionCredentials", inheritance.RDGatewayUseConnectionCredentials.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayUsername)
|
||||
element.Add(new XAttribute("InheritRDGatewayUsername", inheritance.RDGatewayUsername.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayPassword)
|
||||
element.Add(new XAttribute("InheritRDGatewayPassword", inheritance.RDGatewayPassword.ToString().ToLowerInvariant()));
|
||||
if (inheritance.RDGatewayDomain)
|
||||
element.Add(new XAttribute("InheritRDGatewayDomain", inheritance.RDGatewayDomain.ToString().ToLowerInvariant()));
|
||||
if (inheritance.VmId)
|
||||
element.Add(new XAttribute("InheritVmId", inheritance.VmId.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UseVmId)
|
||||
element.Add(new XAttribute("InheritUseVmId", inheritance.UseVmId.ToString().ToLowerInvariant()));
|
||||
if (inheritance.UseEnhancedMode)
|
||||
element.Add(new XAttribute("InheritUseEnhancedMode", inheritance.UseEnhancedMode.ToString().ToLowerInvariant()));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,64 +0,0 @@
|
||||
using mRemoteNG.App;
|
||||
using mRemoteNG.Config.DatabaseConnectors;
|
||||
using mRemoteNG.Messages;
|
||||
using System;
|
||||
using System.Data.Common;
|
||||
|
||||
namespace mRemoteNG.Config.Serializers.Versioning
|
||||
{
|
||||
public class SqlVersion27To28Upgrader : IVersionUpgrader
|
||||
{
|
||||
private readonly IDatabaseConnector _databaseConnector;
|
||||
|
||||
public SqlVersion27To28Upgrader(IDatabaseConnector databaseConnector)
|
||||
{
|
||||
_databaseConnector = databaseConnector ?? throw new ArgumentNullException(nameof(databaseConnector));
|
||||
}
|
||||
|
||||
public bool CanUpgrade(Version currentVersion)
|
||||
{
|
||||
return currentVersion.CompareTo(new Version(2, 7)) == 0;
|
||||
}
|
||||
|
||||
public Version Upgrade()
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg,
|
||||
"Upgrading database from version 2.7 to version 2.8.");
|
||||
|
||||
const string mySqlText = @"
|
||||
ALTER TABLE tblCons MODIFY COLUMN ID INT;
|
||||
ALTER TABLE tblCons DROP PRIMARY KEY, ADD PRIMARY KEY (ConstantID);
|
||||
ALTER TABLE tblCons ADD INDEX `id` (ID), MODIFY ID int auto_increment;
|
||||
ALTER TABLE tblCons MODIFY COLUMN ID INT AUTO_INCREMENT, ADD UNIQUE(ID);
|
||||
UPDATE tblRoot SET ConfVersion='2.8'";
|
||||
const string msSqlText1 = @"
|
||||
ALTER TABLE tblCons ADD DEFAULT 0 FOR UseEnhancedMode;
|
||||
ALTER TABLE tblCons ADD DEFAULT 0 FOR InheritUseEnhancedMode;
|
||||
UPDATE tblCons SET UseEnhancedMode = 0 WHERE UseEnhancedMode IS NULL;
|
||||
UPDATE tblCons SET InheritUseEnhancedMode = 0 WHERE InheritUseEnhancedMode IS NULL;
|
||||
ALTER TABLE tblCons ALTER COLUMN ConstantID varchar(128) NOT NULL;";
|
||||
const string msSqlText2 = @"
|
||||
ALTER TABLE tblCons ADD CONSTRAINT PK_tblCons PRIMARY KEY (ConstantID);
|
||||
UPDATE tblRoot SET ConfVersion='2.8';";
|
||||
DbCommand dbCommand;
|
||||
|
||||
if (_databaseConnector.GetType() == typeof(MSSqlDatabaseConnector))
|
||||
{
|
||||
dbCommand = _databaseConnector.DbCommand(msSqlText1);
|
||||
dbCommand.ExecuteNonQuery();
|
||||
dbCommand = _databaseConnector.DbCommand(msSqlText2);
|
||||
} else if (_databaseConnector.GetType() == typeof(MySqlDatabaseConnector))
|
||||
{
|
||||
dbCommand = _databaseConnector.DbCommand(mySqlText);
|
||||
} else
|
||||
{
|
||||
throw new Exception("Unknow database backend");
|
||||
}
|
||||
|
||||
|
||||
|
||||
dbCommand.ExecuteNonQuery();
|
||||
return new Version(2, 8);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,904 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using mRemoteNG.Connection.Protocol;
|
||||
using mRemoteNG.Connection.Protocol.Http;
|
||||
using mRemoteNG.Connection.Protocol.RDP;
|
||||
using mRemoteNG.Connection.Protocol.VNC;
|
||||
using mRemoteNG.Properties;
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
using mRemoteNG.Tools.Attributes;
|
||||
|
||||
|
||||
namespace mRemoteNG.Connection
|
||||
{
|
||||
public abstract class AbstractConnectionRecord : INotifyPropertyChanged
|
||||
{
|
||||
#region Fields
|
||||
|
||||
private string _name;
|
||||
private string _description;
|
||||
private string _icon;
|
||||
private string _panel;
|
||||
|
||||
private string _hostname;
|
||||
private string _username = "";
|
||||
private string _password = "";
|
||||
private string _domain = "";
|
||||
private string _vmId = "";
|
||||
private bool _useEnhancedMode;
|
||||
|
||||
private string _sshTunnelConnectionName = "";
|
||||
private ProtocolType _protocol;
|
||||
private RdpVersion _rdpProtocolVersion;
|
||||
private string _extApp;
|
||||
private int _port;
|
||||
private string _sshOptions = "";
|
||||
private string _puttySession;
|
||||
private bool _useConsoleSession;
|
||||
private AuthenticationLevel _rdpAuthenticationLevel;
|
||||
private int _rdpMinutesToIdleTimeout;
|
||||
private bool _rdpAlertIdleTimeout;
|
||||
private string _loadBalanceInfo;
|
||||
private HTTPBase.RenderingEngine _renderingEngine;
|
||||
private bool _useCredSsp;
|
||||
private bool _useVmId;
|
||||
|
||||
private RDGatewayUsageMethod _rdGatewayUsageMethod;
|
||||
private string _rdGatewayHostname;
|
||||
private RDGatewayUseConnectionCredentials _rdGatewayUseConnectionCredentials;
|
||||
private string _rdGatewayUsername;
|
||||
private string _rdGatewayPassword;
|
||||
private string _rdGatewayDomain;
|
||||
|
||||
private RDPResolutions _resolution;
|
||||
private bool _automaticResize;
|
||||
private RDPColors _colors;
|
||||
private bool _cacheBitmaps;
|
||||
private bool _displayWallpaper;
|
||||
private bool _displayThemes;
|
||||
private bool _enableFontSmoothing;
|
||||
private bool _enableDesktopComposition;
|
||||
private bool _disableFullWindowDrag;
|
||||
private bool _disableMenuAnimations;
|
||||
private bool _disableCursorShadow;
|
||||
private bool _disableCursorBlinking;
|
||||
|
||||
private bool _redirectKeys;
|
||||
private bool _redirectDiskDrives;
|
||||
private bool _redirectPrinters;
|
||||
private bool _redirectClipboard;
|
||||
private bool _redirectPorts;
|
||||
private bool _redirectSmartCards;
|
||||
private RDPSounds _redirectSound;
|
||||
private RDPSoundQuality _soundQuality;
|
||||
private bool _redirectAudioCapture;
|
||||
|
||||
private string _preExtApp;
|
||||
private string _postExtApp;
|
||||
private string _macAddress;
|
||||
private string _userField;
|
||||
private string _startProgram;
|
||||
private bool _favorite;
|
||||
|
||||
private ProtocolVNC.Compression _vncCompression;
|
||||
private ProtocolVNC.Encoding _vncEncoding;
|
||||
private ProtocolVNC.AuthMode _vncAuthMode;
|
||||
private ProtocolVNC.ProxyType _vncProxyType;
|
||||
private string _vncProxyIp;
|
||||
private int _vncProxyPort;
|
||||
private string _vncProxyUsername;
|
||||
private string _vncProxyPassword;
|
||||
private ProtocolVNC.Colors _vncColors;
|
||||
private ProtocolVNC.SmartSizeMode _vncSmartSizeMode;
|
||||
private bool _vncViewOnly;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Properties
|
||||
|
||||
#region Display
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display)),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Name)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionName))]
|
||||
public virtual string Name
|
||||
{
|
||||
get => _name;
|
||||
set => SetField(ref _name, value, "Name");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display)),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Description)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDescription))]
|
||||
public virtual string Description
|
||||
{
|
||||
get => GetPropertyValue("Description", _description);
|
||||
set => SetField(ref _description, value, "Description");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display)),
|
||||
TypeConverter(typeof(ConnectionIcon)),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Icon)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionIcon))]
|
||||
public virtual string Icon
|
||||
{
|
||||
get => GetPropertyValue("Icon", _icon);
|
||||
set => SetField(ref _icon, value, "Icon");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display)),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Panel)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionPanel))]
|
||||
public virtual string Panel
|
||||
{
|
||||
get => GetPropertyValue("Panel", _panel);
|
||||
set => SetField(ref _panel, value, "Panel");
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Connection
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.HostnameIp)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionHostnameIp)),
|
||||
AttributeUsedInAllProtocolsExcept()]
|
||||
public virtual string Hostname
|
||||
{
|
||||
get => _hostname.Trim();
|
||||
set => SetField(ref _hostname, value?.Trim(), "Hostname");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Port)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionPort)),
|
||||
AttributeUsedInAllProtocolsExcept()]
|
||||
public virtual int Port
|
||||
{
|
||||
get => GetPropertyValue("Port", _port);
|
||||
set => SetField(ref _port, value, "Port");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Username)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionUsername)),
|
||||
AttributeUsedInAllProtocolsExcept(ProtocolType.VNC, ProtocolType.Telnet, ProtocolType.Rlogin, ProtocolType.RAW)]
|
||||
public virtual string Username
|
||||
{
|
||||
get => GetPropertyValue("Username", _username);
|
||||
set => SetField(ref _username, Settings.Default.DoNotTrimUsername ? value : value?.Trim(), "Username");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Password)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionPassword)),
|
||||
PasswordPropertyText(true),
|
||||
AttributeUsedInAllProtocolsExcept(ProtocolType.Telnet, ProtocolType.Rlogin, ProtocolType.RAW)]
|
||||
public virtual string Password
|
||||
{
|
||||
get => GetPropertyValue("Password", _password);
|
||||
set => SetField(ref _password, value, "Password");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Domain)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDomain)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP, ProtocolType.IntApp, ProtocolType.PowerShell)]
|
||||
public string Domain
|
||||
{
|
||||
get => GetPropertyValue("Domain", _domain).Trim();
|
||||
set => SetField(ref _domain, value?.Trim(), "Domain");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.VmId)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionVmId)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public string VmId
|
||||
{
|
||||
get => GetPropertyValue("VmId", _vmId).Trim();
|
||||
set => SetField(ref _vmId, value?.Trim(), "VmId");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.SshTunnel)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionSshTunnel)),
|
||||
TypeConverter(typeof(SshTunnelTypeConverter)),
|
||||
AttributeUsedInAllProtocolsExcept()]
|
||||
public string SSHTunnelConnectionName
|
||||
{
|
||||
get => GetPropertyValue("SSHTunnelConnectionName", _sshTunnelConnectionName).Trim();
|
||||
set => SetField(ref _sshTunnelConnectionName, value?.Trim(), "SSHTunnelConnectionName");
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Protocol
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Protocol)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionProtocol)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter))]
|
||||
public virtual ProtocolType Protocol
|
||||
{
|
||||
get => GetPropertyValue("Protocol", _protocol);
|
||||
set => SetField(ref _protocol, value, "Protocol");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpVersion)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRdpVersion)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public virtual RdpVersion RdpVersion
|
||||
{
|
||||
get => GetPropertyValue("RdpVersion", _rdpProtocolVersion);
|
||||
set => SetField(ref _rdpProtocolVersion, value, nameof(RdpVersion));
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ExternalTool)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionExternalTool)),
|
||||
TypeConverter(typeof(ExternalToolsTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.IntApp)]
|
||||
public string ExtApp
|
||||
{
|
||||
get => GetPropertyValue("ExtApp", _extApp);
|
||||
set => SetField(ref _extApp, value, "ExtApp");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.PuttySession)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionPuttySession)),
|
||||
TypeConverter(typeof(Config.Putty.PuttySessionsManager.SessionList)),
|
||||
AttributeUsedInProtocol(ProtocolType.SSH1, ProtocolType.SSH2, ProtocolType.Telnet,
|
||||
ProtocolType.RAW, ProtocolType.Rlogin)]
|
||||
public virtual string PuttySession
|
||||
{
|
||||
get => GetPropertyValue("PuttySession", _puttySession);
|
||||
set => SetField(ref _puttySession, value, "PuttySession");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.SshOptions)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionSshOptions)),
|
||||
AttributeUsedInProtocol(ProtocolType.SSH1, ProtocolType.SSH2)]
|
||||
public virtual string SSHOptions
|
||||
{
|
||||
get => GetPropertyValue("SSHOptions", _sshOptions);
|
||||
set => SetField(ref _sshOptions, value, "SSHOptions");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.UseConsoleSession)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionUseConsoleSession)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool UseConsoleSession
|
||||
{
|
||||
get => GetPropertyValue("UseConsoleSession", _useConsoleSession);
|
||||
set => SetField(ref _useConsoleSession, value, "UseConsoleSession");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.AuthenticationLevel)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionAuthenticationLevel)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public AuthenticationLevel RDPAuthenticationLevel
|
||||
{
|
||||
get => GetPropertyValue("RDPAuthenticationLevel", _rdpAuthenticationLevel);
|
||||
set => SetField(ref _rdpAuthenticationLevel, value, "RDPAuthenticationLevel");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.MinutesToIdleTimeout)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRDPMinutesToIdleTimeout)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public virtual int RDPMinutesToIdleTimeout
|
||||
{
|
||||
get => GetPropertyValue("RDPMinutesToIdleTimeout", _rdpMinutesToIdleTimeout);
|
||||
set
|
||||
{
|
||||
if (value < 0)
|
||||
value = 0;
|
||||
else if (value > 240)
|
||||
value = 240;
|
||||
SetField(ref _rdpMinutesToIdleTimeout, value, "RDPMinutesToIdleTimeout");
|
||||
}
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.MinutesToIdleTimeout)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRDPAlertIdleTimeout)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RDPAlertIdleTimeout
|
||||
{
|
||||
get => GetPropertyValue("RDPAlertIdleTimeout", _rdpAlertIdleTimeout);
|
||||
set => SetField(ref _rdpAlertIdleTimeout, value, "RDPAlertIdleTimeout");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.LoadBalanceInfo)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionLoadBalanceInfo)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public string LoadBalanceInfo
|
||||
{
|
||||
get => GetPropertyValue("LoadBalanceInfo", _loadBalanceInfo).Trim();
|
||||
set => SetField(ref _loadBalanceInfo, value?.Trim(), "LoadBalanceInfo");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RenderingEngine)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRenderingEngine)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.HTTP, ProtocolType.HTTPS)]
|
||||
public HTTPBase.RenderingEngine RenderingEngine
|
||||
{
|
||||
get => GetPropertyValue("RenderingEngine", _renderingEngine);
|
||||
set => SetField(ref _renderingEngine, value, "RenderingEngine");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.UseCredSsp)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionUseCredSsp)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool UseCredSsp
|
||||
{
|
||||
get => GetPropertyValue("UseCredSsp", _useCredSsp);
|
||||
set => SetField(ref _useCredSsp, value, "UseCredSsp");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.UseVmId)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionUseVmId)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool UseVmId
|
||||
{
|
||||
get => GetPropertyValue("UseVmId", _useVmId);
|
||||
set => SetField(ref _useVmId, value, "UseVmId");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 3),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.UseEnhancedMode)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionUseEnhancedMode)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool UseEnhancedMode
|
||||
{
|
||||
get => GetPropertyValue("UseEnhancedMode", _useEnhancedMode);
|
||||
set => SetField(ref _useEnhancedMode, value, "UseEnhancedMode");
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region RD Gateway
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 4),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpGatewayUsageMethod)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRdpGatewayUsageMethod)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public RDGatewayUsageMethod RDGatewayUsageMethod
|
||||
{
|
||||
get => GetPropertyValue("RDGatewayUsageMethod", _rdGatewayUsageMethod);
|
||||
set => SetField(ref _rdGatewayUsageMethod, value, "RDGatewayUsageMethod");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 4),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpGatewayHostname)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRDGatewayHostname)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public string RDGatewayHostname
|
||||
{
|
||||
get => GetPropertyValue("RDGatewayHostname", _rdGatewayHostname).Trim();
|
||||
set => SetField(ref _rdGatewayHostname, value?.Trim(), "RDGatewayHostname");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 4),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpGatewayUseConnectionCredentials)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRDGatewayUseConnectionCredentials)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public RDGatewayUseConnectionCredentials RDGatewayUseConnectionCredentials
|
||||
{
|
||||
get => GetPropertyValue("RDGatewayUseConnectionCredentials", _rdGatewayUseConnectionCredentials);
|
||||
set => SetField(ref _rdGatewayUseConnectionCredentials, value, "RDGatewayUseConnectionCredentials");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 4),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpGatewayUsername)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRDGatewayUsername)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public string RDGatewayUsername
|
||||
{
|
||||
get => GetPropertyValue("RDGatewayUsername", _rdGatewayUsername).Trim();
|
||||
set => SetField(ref _rdGatewayUsername, value?.Trim(), "RDGatewayUsername");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 4),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpGatewayPassword)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRdpGatewayPassword)),
|
||||
PasswordPropertyText(true),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public string RDGatewayPassword
|
||||
{
|
||||
get => GetPropertyValue("RDGatewayPassword", _rdGatewayPassword);
|
||||
set => SetField(ref _rdGatewayPassword, value, "RDGatewayPassword");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 4),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RdpGatewayDomain)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRDGatewayDomain)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public string RDGatewayDomain
|
||||
{
|
||||
get => GetPropertyValue("RDGatewayDomain", _rdGatewayDomain).Trim();
|
||||
set => SetField(ref _rdGatewayDomain, value?.Trim(), "RDGatewayDomain");
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Appearance
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Resolution)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionResolution)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public RDPResolutions Resolution
|
||||
{
|
||||
get => GetPropertyValue("Resolution", _resolution);
|
||||
set => SetField(ref _resolution, value, "Resolution");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.AutomaticResize)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionAutomaticResize)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool AutomaticResize
|
||||
{
|
||||
get => GetPropertyValue("AutomaticResize", _automaticResize);
|
||||
set => SetField(ref _automaticResize, value, "AutomaticResize");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Colors)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionColors)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public RDPColors Colors
|
||||
{
|
||||
get => GetPropertyValue("Colors", _colors);
|
||||
set => SetField(ref _colors, value, "Colors");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.CacheBitmaps)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionCacheBitmaps)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool CacheBitmaps
|
||||
{
|
||||
get => GetPropertyValue("CacheBitmaps", _cacheBitmaps);
|
||||
set => SetField(ref _cacheBitmaps, value, "CacheBitmaps");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.DisplayWallpaper)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDisplayWallpaper)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool DisplayWallpaper
|
||||
{
|
||||
get => GetPropertyValue("DisplayWallpaper", _displayWallpaper);
|
||||
set => SetField(ref _displayWallpaper, value, "DisplayWallpaper");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.DisplayThemes)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDisplayThemes)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool DisplayThemes
|
||||
{
|
||||
get => GetPropertyValue("DisplayThemes", _displayThemes);
|
||||
set => SetField(ref _displayThemes, value, "DisplayThemes");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.FontSmoothing)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionEnableFontSmoothing)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool EnableFontSmoothing
|
||||
{
|
||||
get => GetPropertyValue("EnableFontSmoothing", _enableFontSmoothing);
|
||||
set => SetField(ref _enableFontSmoothing, value, "EnableFontSmoothing");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.EnableDesktopComposition)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionEnableDesktopComposition)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool EnableDesktopComposition
|
||||
{
|
||||
get => GetPropertyValue("EnableDesktopComposition", _enableDesktopComposition);
|
||||
set => SetField(ref _enableDesktopComposition, value, "EnableDesktopComposition");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.DisableFullWindowDrag)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDisableFullWindowDrag)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool DisableFullWindowDrag
|
||||
{
|
||||
get => GetPropertyValue("DisableFullWindowDrag", _disableFullWindowDrag);
|
||||
set => SetField(ref _disableFullWindowDrag, value, "DisableFullWindowDrag");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.DisableMenuAnimations)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDisableMenuAnimations)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool DisableMenuAnimations
|
||||
{
|
||||
get => GetPropertyValue("DisableMenuAnimations", _disableMenuAnimations);
|
||||
set => SetField(ref _disableMenuAnimations, value, "DisableMenuAnimations");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.DisableCursorShadow)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDisableCursorShadow)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool DisableCursorShadow
|
||||
{
|
||||
get => GetPropertyValue("DisableCursorShadow", _disableCursorShadow);
|
||||
set => SetField(ref _disableCursorShadow, value, "DisableCursorShadow");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.DisableCursorShadow)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionDisableCursorShadow)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool DisableCursorBlinking
|
||||
{
|
||||
get => GetPropertyValue("DisableCursorBlinking", _disableCursorBlinking);
|
||||
set => SetField(ref _disableCursorBlinking, value, "DisableCursorBlinking");
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Redirect
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.RedirectKeys)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectKeys)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectKeys
|
||||
{
|
||||
get => GetPropertyValue("RedirectKeys", _redirectKeys);
|
||||
set => SetField(ref _redirectKeys, value, "RedirectKeys");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Redirect)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectDrives)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectDiskDrives
|
||||
{
|
||||
get => GetPropertyValue("RedirectDiskDrives", _redirectDiskDrives);
|
||||
set => SetField(ref _redirectDiskDrives, value, "RedirectDiskDrives");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Printers)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectPrinters)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectPrinters
|
||||
{
|
||||
get => GetPropertyValue("RedirectPrinters", _redirectPrinters);
|
||||
set => SetField(ref _redirectPrinters, value, "RedirectPrinters");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Clipboard)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectClipboard)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectClipboard
|
||||
{
|
||||
get => GetPropertyValue("RedirectClipboard", _redirectClipboard);
|
||||
set => SetField(ref _redirectClipboard, value, "RedirectClipboard");
|
||||
}
|
||||
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Ports)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectPorts)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectPorts
|
||||
{
|
||||
get => GetPropertyValue("RedirectPorts", _redirectPorts);
|
||||
set => SetField(ref _redirectPorts, value, "RedirectPorts");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Redirect)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectSmartCards)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectSmartCards
|
||||
{
|
||||
get => GetPropertyValue("RedirectSmartCards", _redirectSmartCards);
|
||||
set => SetField(ref _redirectSmartCards, value, "RedirectSmartCards");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Sounds)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectSounds)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public RDPSounds RedirectSound
|
||||
{
|
||||
get => GetPropertyValue("RedirectSound", _redirectSound);
|
||||
set => SetField(ref _redirectSound, value, "RedirectSound");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.SoundQuality)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionSoundQuality)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public RDPSoundQuality SoundQuality
|
||||
{
|
||||
get => GetPropertyValue("SoundQuality", _soundQuality);
|
||||
set => SetField(ref _soundQuality, value, "SoundQuality");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 6),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.AudioCapture)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionRedirectAudioCapture)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public bool RedirectAudioCapture
|
||||
{
|
||||
get => GetPropertyValue("RedirectAudioCapture", _redirectAudioCapture);
|
||||
set => SetField(ref _redirectAudioCapture, value, nameof(RedirectAudioCapture));
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Misc
|
||||
|
||||
[Browsable(false)] public string ConstantID { get; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ExternalToolBefore)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionExternalToolBefore)),
|
||||
TypeConverter(typeof(ExternalToolsTypeConverter))]
|
||||
public virtual string PreExtApp
|
||||
{
|
||||
get => GetPropertyValue("PreExtApp", _preExtApp);
|
||||
set => SetField(ref _preExtApp, value, "PreExtApp");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ExternalToolAfter)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionExternalToolAfter)),
|
||||
TypeConverter(typeof(ExternalToolsTypeConverter))]
|
||||
public virtual string PostExtApp
|
||||
{
|
||||
get => GetPropertyValue("PostExtApp", _postExtApp);
|
||||
set => SetField(ref _postExtApp, value, "PostExtApp");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.MacAddress)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionMACAddress))]
|
||||
public virtual string MacAddress
|
||||
{
|
||||
get => GetPropertyValue("MacAddress", _macAddress);
|
||||
set => SetField(ref _macAddress, value, "MacAddress");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.UserField)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionUser1))]
|
||||
public virtual string UserField
|
||||
{
|
||||
get => GetPropertyValue("UserField", _userField);
|
||||
set => SetField(ref _userField, value, "UserField");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Favorite)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionFavorite)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public virtual bool Favorite
|
||||
{
|
||||
get => GetPropertyValue("Favorite", _favorite);
|
||||
set => SetField(ref _favorite, value, "Favorite");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.StartProgram)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionStartProgram)),
|
||||
AttributeUsedInProtocol(ProtocolType.RDP)]
|
||||
public virtual string StartProgram
|
||||
{
|
||||
get => GetPropertyValue("StartProgram", _startProgram);
|
||||
set => SetField(ref _startProgram, value, "StartProgram");
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region VNC
|
||||
// TODO: it seems all these VNC properties were added and serialized but
|
||||
// never hooked up to the VNC protocol or shown to the user
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Compression)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionCompression)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public ProtocolVNC.Compression VNCCompression
|
||||
{
|
||||
get => GetPropertyValue("VNCCompression", _vncCompression);
|
||||
set => SetField(ref _vncCompression, value, "VNCCompression");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Encoding)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionEncoding)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public ProtocolVNC.Encoding VNCEncoding
|
||||
{
|
||||
get => GetPropertyValue("VNCEncoding", _vncEncoding);
|
||||
set => SetField(ref _vncEncoding, value, "VNCEncoding");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 2),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.AuthenticationMode)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionAuthenticationMode)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public ProtocolVNC.AuthMode VNCAuthMode
|
||||
{
|
||||
get => GetPropertyValue("VNCAuthMode", _vncAuthMode);
|
||||
set => SetField(ref _vncAuthMode, value, "VNCAuthMode");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ProxyType)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionVNCProxyType)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public ProtocolVNC.ProxyType VNCProxyType
|
||||
{
|
||||
get => GetPropertyValue("VNCProxyType", _vncProxyType);
|
||||
set => SetField(ref _vncProxyType, value, "VNCProxyType");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ProxyAddress)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionVNCProxyAddress)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public string VNCProxyIP
|
||||
{
|
||||
get => GetPropertyValue("VNCProxyIP", _vncProxyIp);
|
||||
set => SetField(ref _vncProxyIp, value, "VNCProxyIP");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ProxyPort)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionVNCProxyPort)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public int VNCProxyPort
|
||||
{
|
||||
get => GetPropertyValue("VNCProxyPort", _vncProxyPort);
|
||||
set => SetField(ref _vncProxyPort, value, "VNCProxyPort");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ProxyUsername)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionVNCProxyUsername)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public string VNCProxyUsername
|
||||
{
|
||||
get => GetPropertyValue("VNCProxyUsername", _vncProxyUsername);
|
||||
set => SetField(ref _vncProxyUsername, value, "VNCProxyUsername");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 7),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ProxyPassword)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionVNCProxyPassword)),
|
||||
PasswordPropertyText(true),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public string VNCProxyPassword
|
||||
{
|
||||
get => GetPropertyValue("VNCProxyPassword", _vncProxyPassword);
|
||||
set => SetField(ref _vncProxyPassword, value, "VNCProxyPassword");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.Colors)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionColors)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC),
|
||||
Browsable(false)]
|
||||
public ProtocolVNC.Colors VNCColors
|
||||
{
|
||||
get => GetPropertyValue("VNCColors", _vncColors);
|
||||
set => SetField(ref _vncColors, value, "VNCColors");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.SmartSizeMode)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionSmartSizeMode)),
|
||||
TypeConverter(typeof(MiscTools.EnumTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC)]
|
||||
public ProtocolVNC.SmartSizeMode VNCSmartSizeMode
|
||||
{
|
||||
get => GetPropertyValue("VNCSmartSizeMode", _vncSmartSizeMode);
|
||||
set => SetField(ref _vncSmartSizeMode, value, "VNCSmartSizeMode");
|
||||
}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 5),
|
||||
LocalizedAttributes.LocalizedDisplayName(nameof(Language.ViewOnly)),
|
||||
LocalizedAttributes.LocalizedDescription(nameof(Language.PropertyDescriptionViewOnly)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter)),
|
||||
AttributeUsedInProtocol(ProtocolType.VNC)]
|
||||
public bool VNCViewOnly
|
||||
{
|
||||
get => GetPropertyValue("VNCViewOnly", _vncViewOnly);
|
||||
set => SetField(ref _vncViewOnly, value, "VNCViewOnly");
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#endregion
|
||||
|
||||
protected AbstractConnectionRecord(string uniqueId)
|
||||
{
|
||||
ConstantID = uniqueId.ThrowIfNullOrEmpty(nameof(uniqueId));
|
||||
}
|
||||
|
||||
protected virtual TPropertyType GetPropertyValue<TPropertyType>(string propertyName, TPropertyType value)
|
||||
{
|
||||
return (TPropertyType)GetType().GetProperty(propertyName)?.GetValue(this, null);
|
||||
}
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
protected virtual void RaisePropertyChangedEvent(object sender, PropertyChangedEventArgs args)
|
||||
{
|
||||
PropertyChanged?.Invoke(sender, new PropertyChangedEventArgs(args.PropertyName));
|
||||
}
|
||||
|
||||
protected void SetField<T>(ref T field, T value, string propertyName = null)
|
||||
{
|
||||
if (EqualityComparer<T>.Default.Equals(field, value)) return;
|
||||
field = value;
|
||||
RaisePropertyChangedEvent(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,557 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection
|
||||
{
|
||||
public class ConnectionInfoInheritance
|
||||
{
|
||||
private ConnectionInfoInheritance _tempInheritanceStorage;
|
||||
|
||||
#region Public Properties
|
||||
|
||||
#region General
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.General)),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.All)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionAll)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool EverythingInherited
|
||||
{
|
||||
get => EverythingIsInherited();
|
||||
set => SetAllValues(value);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Display
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display), 2),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Description)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDescription)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Description { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display), 2),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Icon)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionIcon)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Icon { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Display), 2),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Panel)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionPanel)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Panel { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Connection
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 3),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Username)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionUsername)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
[Browsable(true)]
|
||||
public bool Username { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 3),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.VmId)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionVmId)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
[Browsable(true)]
|
||||
public bool VmId { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 3),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Password)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionPassword)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
[Browsable(true)]
|
||||
public bool Password { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 3),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Domain)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDomain)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
[Browsable(true)]
|
||||
public bool Domain { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 3),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Port)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionPort)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Port { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 3),
|
||||
LocalizedAttributes.LocalizedDisplayNameInheritAttribute(nameof(Language.SshTunnel)),
|
||||
LocalizedAttributes.LocalizedDescriptionInheritAttribute(nameof(Language.PropertyDescriptionSshTunnel)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
[Browsable(true)]
|
||||
public bool SSHTunnelConnectionName { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Protocol
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Protocol)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionProtocol)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Protocol { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpVersion)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRdpVersion)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RdpVersion { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ExternalTool)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionExternalTool)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool ExtApp { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.PuttySession)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionPuttySession)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool PuttySession { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.SshOptions)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionSshOptions)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool SSHOptions { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.AuthenticationLevel)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionAuthenticationLevel)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDPAuthenticationLevel { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.MinutesToIdleTimeout)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRDPMinutesToIdleTimeout)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDPMinutesToIdleTimeout { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.MinutesToIdleTimeout)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRDPAlertIdleTimeout)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDPAlertIdleTimeout { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.LoadBalanceInfo)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionLoadBalanceInfo)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool LoadBalanceInfo { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RenderingEngine)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRenderingEngine)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RenderingEngine { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.UseConsoleSession)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionUseConsoleSession)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool UseConsoleSession { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.UseCredSsp)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionUseCredSsp)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool UseCredSsp { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.UseVmId)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionUseVmId)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool UseVmId { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Protocol), 4),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.UseEnhancedMode)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionUseEnhancedMode)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool UseEnhancedMode { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region RD Gateway
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 5),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpGatewayUsageMethod)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRdpGatewayUsageMethod)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDGatewayUsageMethod { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 5),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpGatewayHostname)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRDGatewayHostname)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDGatewayHostname { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 5),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpGatewayUseConnectionCredentials)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRDGatewayUseConnectionCredentials)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDGatewayUseConnectionCredentials { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 5),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpGatewayUsername)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRDGatewayUsername)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDGatewayUsername { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 5),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpGatewayPassword)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRdpGatewayPassword)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDGatewayPassword { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Gateway), 5),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RdpGatewayDomain)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRDGatewayDomain)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RDGatewayDomain { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Appearance
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Resolution)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionResolution)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Resolution { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.AutomaticResize)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionAutomaticResize)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool AutomaticResize { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Colors)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionColors)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Colors { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.CacheBitmaps)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionCacheBitmaps)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool CacheBitmaps { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DisplayWallpaper)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDisplayWallpaper)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool DisplayWallpaper { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DisplayThemes)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDisplayThemes)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool DisplayThemes { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.FontSmoothing)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionEnableFontSmoothing)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool EnableFontSmoothing { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.EnableDesktopComposition)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionEnableDesktopComposition)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool EnableDesktopComposition { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DisableFullWindowDrag)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDisableFullWindowDrag)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool DisableFullWindowDrag { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DisableMenuAnimations)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDisableMenuAnimations)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool DisableMenuAnimations { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DisableCursorShadow)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDisableCursorShadow)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool DisableCursorShadow { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 6),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DisableCursorBlinking)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionDisableCursorBlinking)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool DisableCursorBlinking { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Redirect
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.RedirectKeys)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectKeys)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectKeys { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.DiskDrives)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectDrives)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectDiskDrives { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Printers)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectPrinters)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectPrinters { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Clipboard)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectClipboard)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectClipboard { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Redirect)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectPorts)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectPorts { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Redirect)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectSmartCards)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectSmartCards { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Sounds)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectSounds)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectSound { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.SoundQuality)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionSoundQuality)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool SoundQuality { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Redirect), 7),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.AudioCapture)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionRedirectAudioCapture)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool RedirectAudioCapture { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Misc
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 8),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ExternalToolBefore)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionExternalToolBefore)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool PreExtApp { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 8),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ExternalToolAfter)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionExternalToolAfter)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool PostExtApp { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 8),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.MacAddress)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionMACAddress)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool MacAddress { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 8),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.UserField)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionUser1)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool UserField { get; set; }
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Miscellaneous), 8),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Favorite)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionFavorite)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]
|
||||
public bool Favorite { get; set; }
|
||||
#endregion
|
||||
|
||||
#region VNC
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Compression)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionCompression)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCCompression {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Encoding)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionEncoding)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCEncoding {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Connection), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.AuthenticationMode)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionAuthenticationMode)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCAuthMode {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ProxyType)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionVNCProxyType)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCProxyType {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ProxyAddress)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionVNCProxyAddress)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCProxyIP {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ProxyPort)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionVNCProxyPort)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCProxyPort {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ProxyUsername)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionVNCProxyUsername)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCProxyUsername {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Proxy), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ProxyPassword)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionVNCProxyPassword)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCProxyPassword {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.Colors)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionColors)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCColors {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.SmartSizeMode)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionSmartSizeMode)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCSmartSizeMode {get; set;}
|
||||
|
||||
[LocalizedAttributes.LocalizedCategory(nameof(Language.Appearance), 9),
|
||||
LocalizedAttributes.LocalizedDisplayNameInherit(nameof(Language.ViewOnly)),
|
||||
LocalizedAttributes.LocalizedDescriptionInherit(nameof(Language.PropertyDescriptionViewOnly)),
|
||||
TypeConverter(typeof(MiscTools.YesNoTypeConverter))]public bool VNCViewOnly {get; set;}
|
||||
#endregion
|
||||
|
||||
[Browsable(false)] public ConnectionInfo Parent { get; private set; }
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
public ConnectionInfoInheritance(ConnectionInfo parent, bool ignoreDefaultInheritance = false)
|
||||
{
|
||||
Parent = parent;
|
||||
if (!ignoreDefaultInheritance)
|
||||
SetAllValues(DefaultConnectionInheritance.Instance);
|
||||
}
|
||||
|
||||
|
||||
public ConnectionInfoInheritance Clone(ConnectionInfo parent)
|
||||
{
|
||||
var newInheritance = (ConnectionInfoInheritance)MemberwiseClone();
|
||||
newInheritance.Parent = parent;
|
||||
newInheritance._tempInheritanceStorage = null;
|
||||
return newInheritance;
|
||||
}
|
||||
|
||||
public void EnableInheritance()
|
||||
{
|
||||
if (_tempInheritanceStorage != null)
|
||||
UnstashInheritanceData();
|
||||
}
|
||||
|
||||
private void UnstashInheritanceData()
|
||||
{
|
||||
SetAllValues(_tempInheritanceStorage);
|
||||
_tempInheritanceStorage = null;
|
||||
}
|
||||
|
||||
public void DisableInheritance()
|
||||
{
|
||||
StashInheritanceData();
|
||||
TurnOffInheritanceCompletely();
|
||||
}
|
||||
|
||||
private void StashInheritanceData()
|
||||
{
|
||||
_tempInheritanceStorage = Clone(Parent);
|
||||
}
|
||||
|
||||
public void TurnOnInheritanceCompletely()
|
||||
{
|
||||
SetAllValues(true);
|
||||
}
|
||||
|
||||
public void TurnOffInheritanceCompletely()
|
||||
{
|
||||
SetAllValues(false);
|
||||
}
|
||||
|
||||
private bool EverythingIsInherited()
|
||||
{
|
||||
var inheritanceProperties = GetProperties();
|
||||
var everythingInherited = inheritanceProperties.All((p) => (bool)p.GetValue(this, null));
|
||||
return everythingInherited;
|
||||
}
|
||||
|
||||
public IEnumerable<PropertyInfo> GetProperties()
|
||||
{
|
||||
var properties = typeof(ConnectionInfoInheritance).GetProperties();
|
||||
var filteredProperties = properties.Where(FilterProperty);
|
||||
return filteredProperties;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the name of all properties where inheritance is turned on
|
||||
/// (set to True).
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public IEnumerable<string> GetEnabledInheritanceProperties()
|
||||
{
|
||||
return GetProperties()
|
||||
.Where(property => (bool)property.GetValue(this))
|
||||
.Select(property => property.Name)
|
||||
.ToList();
|
||||
}
|
||||
|
||||
private bool FilterProperty(PropertyInfo propertyInfo)
|
||||
{
|
||||
var exclusions = new[] {"EverythingInherited", "Parent"};
|
||||
var valueShouldNotBeFiltered = !exclusions.Contains(propertyInfo.Name);
|
||||
return valueShouldNotBeFiltered;
|
||||
}
|
||||
|
||||
private void SetAllValues(bool value)
|
||||
{
|
||||
var properties = GetProperties();
|
||||
foreach (var property in properties)
|
||||
{
|
||||
if (property.PropertyType.Name == typeof(bool).Name)
|
||||
property.SetValue(this, value, null);
|
||||
}
|
||||
}
|
||||
|
||||
private void SetAllValues(ConnectionInfoInheritance otherInheritanceObject)
|
||||
{
|
||||
var properties = GetProperties();
|
||||
foreach (var property in properties)
|
||||
{
|
||||
var newPropertyValue = property.GetValue(otherInheritanceObject, null);
|
||||
property.SetValue(this, newPropertyValue, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,454 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Windows.Forms;
|
||||
using mRemoteNG.App;
|
||||
using mRemoteNG.Connection.Protocol;
|
||||
using mRemoteNG.Container;
|
||||
using mRemoteNG.Messages;
|
||||
using mRemoteNG.Properties;
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.UI.Forms;
|
||||
using mRemoteNG.UI.Panels;
|
||||
using mRemoteNG.UI.Tabs;
|
||||
using mRemoteNG.UI.Window;
|
||||
using WeifenLuo.WinFormsUI.Docking;
|
||||
|
||||
|
||||
namespace mRemoteNG.Connection
|
||||
{
|
||||
public class ConnectionInitiator : IConnectionInitiator
|
||||
{
|
||||
private readonly PanelAdder _panelAdder = new PanelAdder();
|
||||
private readonly List<string> _activeConnections = new List<string>();
|
||||
|
||||
public IEnumerable<string> ActiveConnections => _activeConnections;
|
||||
|
||||
public bool SwitchToOpenConnection(ConnectionInfo connectionInfo)
|
||||
{
|
||||
var interfaceControl = FindConnectionContainer(connectionInfo);
|
||||
if (interfaceControl == null) return false;
|
||||
var connT = (ConnectionTab)interfaceControl.FindForm();
|
||||
connT?.Focus();
|
||||
var findForm = (ConnectionTab)interfaceControl.FindForm();
|
||||
findForm?.Show(findForm.DockPanel);
|
||||
return true;
|
||||
}
|
||||
|
||||
public void OpenConnection(
|
||||
ContainerInfo containerInfo,
|
||||
ConnectionInfo.Force force = ConnectionInfo.Force.None,
|
||||
ConnectionWindow conForm = null)
|
||||
{
|
||||
if (containerInfo == null || containerInfo.Children.Count == 0)
|
||||
return;
|
||||
|
||||
foreach (var child in containerInfo.Children)
|
||||
{
|
||||
if (child is ContainerInfo childAsContainer)
|
||||
OpenConnection(childAsContainer, force, conForm);
|
||||
else
|
||||
OpenConnection(child, force, conForm);
|
||||
}
|
||||
}
|
||||
|
||||
// async is necessary so UI can update while OpenConnection waits for tunnel connection to get ready in case of connection through SSH tunnel
|
||||
public async void OpenConnection(
|
||||
ConnectionInfo connectionInfo,
|
||||
ConnectionInfo.Force force = ConnectionInfo.Force.None,
|
||||
ConnectionWindow conForm = null)
|
||||
{
|
||||
if (connectionInfo == null)
|
||||
return;
|
||||
|
||||
try
|
||||
{
|
||||
if (connectionInfo.Hostname == "" && connectionInfo.Protocol != ProtocolType.IntApp)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
Language.ConnectionOpenFailedNoHostname);
|
||||
return;
|
||||
}
|
||||
|
||||
StartPreConnectionExternalApp(connectionInfo);
|
||||
|
||||
if (!force.HasFlag(ConnectionInfo.Force.DoNotJump))
|
||||
{
|
||||
if (SwitchToOpenConnection(connectionInfo))
|
||||
return;
|
||||
}
|
||||
|
||||
var protocolFactory = new ProtocolFactory();
|
||||
var connectionPanel = SetConnectionPanel(connectionInfo, force);
|
||||
if (string.IsNullOrEmpty(connectionPanel)) return;
|
||||
var connectionForm = SetConnectionForm(conForm, connectionPanel);
|
||||
Control connectionContainer = null;
|
||||
|
||||
// Handle connection through SSH tunnel:
|
||||
// in case of connection through SSH tunnel, connectionInfo gets cloned, so that modification of its name, hostname and port do not modify the original connection info
|
||||
// connectionInfoOriginal points to the original connection info in either case, for where its needed later on.
|
||||
var connectionInfoOriginal = connectionInfo;
|
||||
ConnectionInfo connectionInfoSshTunnel = null; // SSH tunnel connection info will be set if SSH tunnel connection is configured, can be found and connected.
|
||||
if (!string.IsNullOrEmpty(connectionInfoOriginal.SSHTunnelConnectionName))
|
||||
{
|
||||
// Find the connection info specified as SSH tunnel in the connections tree
|
||||
connectionInfoSshTunnel = getSSHConnectionInfoByName(Runtime.ConnectionsService.ConnectionTreeModel.RootNodes, connectionInfoOriginal.SSHTunnelConnectionName);
|
||||
if (connectionInfoSshTunnel == null)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
string.Format(Language.SshTunnelConfigProblem, connectionInfoOriginal.Name, connectionInfoOriginal.SSHTunnelConnectionName));
|
||||
return;
|
||||
}
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.DebugMsg,
|
||||
$"SSH Tunnel connection '{connectionInfoOriginal.SSHTunnelConnectionName}' configured for '{connectionInfoOriginal.Name}' found. Finding free local port for use as local tunnel port ...");
|
||||
// determine a free local port to use as local tunnel port
|
||||
var l = new System.Net.Sockets.TcpListener(System.Net.IPAddress.Loopback, 0);
|
||||
l.Start();
|
||||
var localSshTunnelPort = ((System.Net.IPEndPoint)l.LocalEndpoint).Port;
|
||||
l.Stop();
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.DebugMsg,
|
||||
$"{localSshTunnelPort} will be used as local tunnel port. Establishing SSH connection to '{connectionInfoSshTunnel.Hostname}' with additional tunnel options for target connection ...");
|
||||
|
||||
// clone SSH tunnel connection as tunnel options will be added to it, and those changes shall not be saved to the configuration
|
||||
connectionInfoSshTunnel = connectionInfoSshTunnel.Clone();
|
||||
connectionInfoSshTunnel.SSHOptions += " -L " + localSshTunnelPort + ":" + connectionInfoOriginal.Hostname + ":" + connectionInfoOriginal.Port;
|
||||
|
||||
// clone target connection info as its hostname will be changed to localhost and port to local tunnel port to establish connection through tunnel, and those changes shall not be saved to the configuration
|
||||
connectionInfo = connectionInfoOriginal.Clone();
|
||||
connectionInfo.Name += " via " + connectionInfoSshTunnel.Name;
|
||||
connectionInfo.Hostname = "localhost";
|
||||
connectionInfo.Port = localSshTunnelPort;
|
||||
|
||||
// connect the SSH connection to setup the tunnel
|
||||
var protocolSshTunnel = protocolFactory.CreateProtocol(connectionInfoSshTunnel);
|
||||
if (!(protocolSshTunnel is PuttyBase puttyBaseSshTunnel))
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
string.Format(Language.SshTunnelIsNotPutty, connectionInfoOriginal.Name, connectionInfoSshTunnel.Name));
|
||||
return;
|
||||
}
|
||||
|
||||
SetConnectionFormEventHandlers(protocolSshTunnel, connectionForm);
|
||||
SetConnectionEventHandlers(protocolSshTunnel);
|
||||
connectionContainer = SetConnectionContainer(connectionInfo, connectionForm);
|
||||
BuildConnectionInterfaceController(connectionInfoSshTunnel, protocolSshTunnel, connectionContainer);
|
||||
protocolSshTunnel.InterfaceControl.OriginalInfo = connectionInfoSshTunnel;
|
||||
|
||||
if (protocolSshTunnel.Initialize() == false)
|
||||
{
|
||||
protocolSshTunnel.Close();
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
string.Format(Language.SshTunnelNotInitialized, connectionInfoOriginal.Name, connectionInfoSshTunnel.Name));
|
||||
return;
|
||||
}
|
||||
|
||||
if (protocolSshTunnel.Connect() == false)
|
||||
{
|
||||
protocolSshTunnel.Close();
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
string.Format(Language.SshTunnelNotConnected, connectionInfoOriginal.Name, connectionInfoSshTunnel.Name));
|
||||
return;
|
||||
}
|
||||
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.DebugMsg,
|
||||
"Putty started for SSH connection for tunnel. Waiting for local tunnel port to become available ...");
|
||||
|
||||
// wait until SSH tunnel connection is ready, by checking if local port can be connected to, but max 60 sec.
|
||||
var testsock = new System.Net.Sockets.Socket(System.Net.Sockets.SocketType.Stream, System.Net.Sockets.ProtocolType.Tcp);
|
||||
var stopwatch = System.Diagnostics.Stopwatch.StartNew();
|
||||
while (stopwatch.ElapsedMilliseconds < 60000)
|
||||
{
|
||||
// confirm that SSH connection is still active
|
||||
// works only if putty is connfigured to always close window on exit
|
||||
// else, if connection attempt fails, window remains open and putty process remains running, and we cannot know that connection is already doomed
|
||||
// in this case the timeout will expire and the log message below will be created
|
||||
// awkward for user as he has already acknowledged the putty popup some seconds again when the below notification comes....
|
||||
if (!puttyBaseSshTunnel.isRunning())
|
||||
{
|
||||
protocolSshTunnel.Close();
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
string.Format(Language.SshTunnelFailed, connectionInfoOriginal.Name, connectionInfoSshTunnel.Name));
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
testsock.Connect(System.Net.IPAddress.Loopback, localSshTunnelPort);
|
||||
testsock.Close();
|
||||
break;
|
||||
}
|
||||
catch
|
||||
{
|
||||
await System.Threading.Tasks.Task.Delay(1000);
|
||||
}
|
||||
}
|
||||
|
||||
if (stopwatch.ElapsedMilliseconds >= 60000)
|
||||
{
|
||||
protocolSshTunnel.Close();
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg,
|
||||
string.Format(Language.SshTunnelPortNotReadyInTime, connectionInfoOriginal.Name, connectionInfoSshTunnel.Name));
|
||||
return;
|
||||
}
|
||||
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.DebugMsg,
|
||||
"Local tunnel port is now available. Hiding putty display and setting up target connection via local tunnel port ...");
|
||||
|
||||
// hide the display of the SSH tunnel connection which has been shown until this time, such that password can be entered if required or errors be seen
|
||||
// it stays invisible in the container however which will be reused for the actual connection and such that if the container is closed the SSH tunnel connection is closed as well
|
||||
protocolSshTunnel.InterfaceControl.Hide();
|
||||
}
|
||||
|
||||
var newProtocol = protocolFactory.CreateProtocol(connectionInfo);
|
||||
SetConnectionFormEventHandlers(newProtocol, connectionForm);
|
||||
SetConnectionEventHandlers(newProtocol);
|
||||
// in case of connection through SSH tunnel the container is already defined and must be use, else it needs to be created here
|
||||
if (connectionContainer == null) connectionContainer = SetConnectionContainer(connectionInfo, connectionForm);
|
||||
BuildConnectionInterfaceController(connectionInfo, newProtocol, connectionContainer);
|
||||
// in case of connection through SSH tunnel the connectionInfo was modified but connectionInfoOriginal in all cases retains the original info
|
||||
// and is stored in interface control for further use
|
||||
newProtocol.InterfaceControl.OriginalInfo = connectionInfoOriginal;
|
||||
// SSH tunnel connection is stored in Interface Control to be used in log messages etc
|
||||
newProtocol.InterfaceControl.SSHTunnelInfo = connectionInfoSshTunnel;
|
||||
|
||||
newProtocol.Force = force;
|
||||
|
||||
if (newProtocol.Initialize() == false)
|
||||
{
|
||||
newProtocol.Close();
|
||||
return;
|
||||
}
|
||||
|
||||
if (newProtocol.Connect() == false)
|
||||
{
|
||||
newProtocol.Close();
|
||||
return;
|
||||
}
|
||||
|
||||
connectionInfoOriginal.OpenConnections.Add(newProtocol);
|
||||
_activeConnections.Add(connectionInfo.ConstantID);
|
||||
FrmMain.Default.SelectedConnection = connectionInfo;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionStackTrace(Language.ConnectionOpenFailed, ex);
|
||||
}
|
||||
}
|
||||
|
||||
// recursively traverse the tree to find ConnectionInfo of a specific name
|
||||
private ConnectionInfo getSSHConnectionInfoByName(IEnumerable<ConnectionInfo> rootnodes, string SSHTunnelConnectionName)
|
||||
{
|
||||
ConnectionInfo result = null;
|
||||
foreach (var node in rootnodes)
|
||||
{
|
||||
if (node is ContainerInfo container)
|
||||
{
|
||||
result = getSSHConnectionInfoByName(container.Children, SSHTunnelConnectionName);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (node.Name == SSHTunnelConnectionName && (node.Protocol == ProtocolType.SSH1 || node.Protocol == ProtocolType.SSH2)) result = node;
|
||||
}
|
||||
if (result != null) break;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
#region Private
|
||||
private static void StartPreConnectionExternalApp(ConnectionInfo connectionInfo)
|
||||
{
|
||||
if (connectionInfo.PreExtApp == "") return;
|
||||
var extA = Runtime.ExternalToolsService.GetExtAppByName(connectionInfo.PreExtApp);
|
||||
extA?.Start(connectionInfo);
|
||||
}
|
||||
|
||||
private static InterfaceControl FindConnectionContainer(ConnectionInfo connectionInfo)
|
||||
{
|
||||
if (connectionInfo.OpenConnections.Count <= 0) return null;
|
||||
for (var i = 0; i <= Runtime.WindowList.Count - 1; i++)
|
||||
{
|
||||
// the new structure is ConnectionWindow.Controls[0].ActiveDocument.Controls[0]
|
||||
// DockPanel InterfaceControl
|
||||
if (!(Runtime.WindowList[i] is ConnectionWindow connectionWindow)) continue;
|
||||
if (connectionWindow.Controls.Count < 1) continue;
|
||||
if (!(connectionWindow.Controls[0] is DockPanel cwDp)) continue;
|
||||
foreach (var dockContent in cwDp.Documents)
|
||||
{
|
||||
var tab = (ConnectionTab)dockContent;
|
||||
var ic = InterfaceControl.FindInterfaceControl(tab);
|
||||
if (ic == null) continue;
|
||||
if (ic.Info == connectionInfo || ic.OriginalInfo == connectionInfo)
|
||||
return ic;
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
private static string SetConnectionPanel(ConnectionInfo connectionInfo, ConnectionInfo.Force force)
|
||||
{
|
||||
if (connectionInfo.Panel != "" &&
|
||||
!force.HasFlag(ConnectionInfo.Force.OverridePanel) &&
|
||||
!Settings.Default.AlwaysShowPanelSelectionDlg)
|
||||
return connectionInfo.Panel;
|
||||
|
||||
var frmPnl = new FrmChoosePanel();
|
||||
return frmPnl.ShowDialog() == DialogResult.OK
|
||||
? frmPnl.Panel
|
||||
: null;
|
||||
}
|
||||
|
||||
private ConnectionWindow SetConnectionForm(ConnectionWindow conForm, string connectionPanel)
|
||||
{
|
||||
var connectionForm = conForm ?? Runtime.WindowList.FromString(connectionPanel) as ConnectionWindow;
|
||||
|
||||
if (connectionForm == null)
|
||||
connectionForm = _panelAdder.AddPanel(connectionPanel);
|
||||
else
|
||||
connectionForm.Show(FrmMain.Default.pnlDock);
|
||||
|
||||
connectionForm.Focus();
|
||||
return connectionForm;
|
||||
}
|
||||
|
||||
private static Control SetConnectionContainer(ConnectionInfo connectionInfo, ConnectionWindow connectionForm)
|
||||
{
|
||||
Control connectionContainer = connectionForm.AddConnectionTab(connectionInfo);
|
||||
|
||||
if (connectionInfo.Protocol != ProtocolType.IntApp) return connectionContainer;
|
||||
|
||||
var extT = Runtime.ExternalToolsService.GetExtAppByName(connectionInfo.ExtApp);
|
||||
|
||||
if (extT == null) return connectionContainer;
|
||||
|
||||
if (extT.Icon != null)
|
||||
((ConnectionTab)connectionContainer).Icon = extT.Icon;
|
||||
|
||||
return connectionContainer;
|
||||
}
|
||||
|
||||
private static void SetConnectionFormEventHandlers(ProtocolBase newProtocol, Form connectionForm)
|
||||
{
|
||||
newProtocol.Closed += ((ConnectionWindow)connectionForm).Prot_Event_Closed;
|
||||
}
|
||||
|
||||
private void SetConnectionEventHandlers(ProtocolBase newProtocol)
|
||||
{
|
||||
newProtocol.Disconnected += Prot_Event_Disconnected;
|
||||
newProtocol.Connected += Prot_Event_Connected;
|
||||
newProtocol.Closed += Prot_Event_Closed;
|
||||
newProtocol.ErrorOccured += Prot_Event_ErrorOccured;
|
||||
}
|
||||
|
||||
private static void BuildConnectionInterfaceController(ConnectionInfo connectionInfo,
|
||||
ProtocolBase newProtocol,
|
||||
Control connectionContainer)
|
||||
{
|
||||
newProtocol.InterfaceControl = new InterfaceControl(connectionContainer, newProtocol, connectionInfo);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Event handlers
|
||||
|
||||
private static void Prot_Event_Disconnected(object sender, string disconnectedMessage, int? reasonCode)
|
||||
{
|
||||
try
|
||||
{
|
||||
var prot = (ProtocolBase)sender;
|
||||
var msgClass = MessageClass.InformationMsg;
|
||||
|
||||
if (prot.InterfaceControl.Info.Protocol == ProtocolType.RDP)
|
||||
{
|
||||
if (reasonCode > 3)
|
||||
{
|
||||
msgClass = MessageClass.WarningMsg;
|
||||
}
|
||||
}
|
||||
|
||||
var strHostname = prot.InterfaceControl.OriginalInfo.Hostname;
|
||||
if (prot.InterfaceControl.SSHTunnelInfo != null)
|
||||
{
|
||||
strHostname += " via SSH Tunnel " + prot.InterfaceControl.SSHTunnelInfo.Name;
|
||||
}
|
||||
Runtime.MessageCollector.AddMessage(msgClass,
|
||||
string.Format(
|
||||
Language.ProtocolEventDisconnected,
|
||||
disconnectedMessage,
|
||||
strHostname,
|
||||
prot.InterfaceControl.Info.Protocol.ToString()));
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionStackTrace(Language.ProtocolEventDisconnectFailed, ex);
|
||||
}
|
||||
}
|
||||
|
||||
private void Prot_Event_Closed(object sender)
|
||||
{
|
||||
try
|
||||
{
|
||||
var prot = (ProtocolBase)sender;
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg, Language.ConnenctionCloseEvent,
|
||||
true);
|
||||
string connDetail;
|
||||
if (prot.InterfaceControl.OriginalInfo.Hostname == "" &&
|
||||
prot.InterfaceControl.Info.Protocol == ProtocolType.IntApp)
|
||||
connDetail = prot.InterfaceControl.Info.ExtApp;
|
||||
else if (prot.InterfaceControl.OriginalInfo.Hostname != "")
|
||||
connDetail = prot.InterfaceControl.OriginalInfo.Hostname;
|
||||
else
|
||||
connDetail = "UNKNOWN";
|
||||
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg,
|
||||
string.Format(Language.ConnenctionClosedByUser, connDetail,
|
||||
prot.InterfaceControl.Info.Protocol,
|
||||
Environment.UserName));
|
||||
prot.InterfaceControl.OriginalInfo.OpenConnections.Remove(prot);
|
||||
if (_activeConnections.Contains(prot.InterfaceControl.Info.ConstantID))
|
||||
_activeConnections.Remove(prot.InterfaceControl.Info.ConstantID);
|
||||
|
||||
if (prot.InterfaceControl.Info.PostExtApp == "") return;
|
||||
var extA = Runtime.ExternalToolsService.GetExtAppByName(prot.InterfaceControl.Info.PostExtApp);
|
||||
extA?.Start(prot.InterfaceControl.OriginalInfo);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionStackTrace(Language.ConnenctionCloseEventFailed, ex);
|
||||
}
|
||||
}
|
||||
|
||||
private static void Prot_Event_Connected(object sender)
|
||||
{
|
||||
var prot = (ProtocolBase)sender;
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg, Language.ConnectionEventConnected,
|
||||
true);
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg,
|
||||
string.Format(Language.ConnectionEventConnectedDetail,
|
||||
prot.InterfaceControl.OriginalInfo.Hostname,
|
||||
prot.InterfaceControl.Info.Protocol, Environment.UserName,
|
||||
prot.InterfaceControl.Info.Description,
|
||||
prot.InterfaceControl.Info.UserField));
|
||||
}
|
||||
|
||||
private static void Prot_Event_ErrorOccured(object sender, string errorMessage, int? errorCode)
|
||||
{
|
||||
try
|
||||
{
|
||||
var prot = (ProtocolBase)sender;
|
||||
|
||||
var msg = string.Format(
|
||||
Language.ConnectionEventErrorOccured,
|
||||
errorMessage,
|
||||
prot.InterfaceControl.OriginalInfo.Hostname,
|
||||
errorCode?.ToString() ?? "-");
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.WarningMsg, msg);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionStackTrace(Language.ConnectionFailed, ex);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -1,34 +0,0 @@
|
||||
// Copyright © 2013 The CefSharp Authors. All rights reserved.
|
||||
//
|
||||
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
|
||||
|
||||
using CefSharp;
|
||||
using System;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.Http
|
||||
{
|
||||
public class DownloadHandler : IDownloadHandler
|
||||
{
|
||||
public event EventHandler<DownloadItem> OnBeforeDownloadFired;
|
||||
|
||||
public event EventHandler<DownloadItem> OnDownloadUpdatedFired;
|
||||
|
||||
public void OnBeforeDownload(IWebBrowser chromiumWebBrowser, IBrowser browser, DownloadItem downloadItem, IBeforeDownloadCallback callback)
|
||||
{
|
||||
OnBeforeDownloadFired?.Invoke(this, downloadItem);
|
||||
|
||||
if (!callback.IsDisposed)
|
||||
{
|
||||
using (callback)
|
||||
{
|
||||
callback.Continue(downloadItem.SuggestedFileName, showDialog: true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void OnDownloadUpdated(IWebBrowser chromiumWebBrowser, IBrowser browser, DownloadItem downloadItem, IDownloadItemCallback callback)
|
||||
{
|
||||
OnDownloadUpdatedFired?.Invoke(this, downloadItem);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,68 +0,0 @@
|
||||
using CefSharp;
|
||||
using System.Diagnostics;
|
||||
using System.Security.Cryptography.X509Certificates;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.Http
|
||||
{
|
||||
partial class RequestHandler : IRequestHandler
|
||||
{
|
||||
public bool GetAuthCredentials(IWebBrowser chromiumWebBrowser, IBrowser browser, string originUrl, bool isProxy, string host, int port, string realm, string scheme, IAuthCallback callback)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public IResourceRequestHandler GetResourceRequestHandler(IWebBrowser chromiumWebBrowser, IBrowser browser, IFrame frame, IRequest request, bool isNavigation, bool isDownload, string requestInitiator, ref bool disableDefaultHandling)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
public bool OnBeforeBrowse(IWebBrowser chromiumWebBrowser, IBrowser browser, IFrame frame, IRequest request, bool userGesture, bool isRedirect)
|
||||
{
|
||||
if (request.Url.StartsWith(Cef.CefCommitHash))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
Process.Start(request.Url);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
public void OnDocumentAvailableInMainFrame(IWebBrowser chromiumWebBrowser, IBrowser browser)
|
||||
{
|
||||
}
|
||||
|
||||
public bool OnCertificateError(IWebBrowser chromiumWebBrowser, IBrowser browser, CefErrorCode errorCode, string requestUrl, ISslInfo sslInfo, IRequestCallback callback)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public bool OnOpenUrlFromTab(IWebBrowser chromiumWebBrowser, IBrowser browser, IFrame frame, string targetUrl, WindowOpenDisposition targetDisposition, bool userGesture)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public void OnPluginCrashed(IWebBrowser chromiumWebBrowser, IBrowser browser, string pluginPath)
|
||||
{
|
||||
}
|
||||
|
||||
public bool OnQuotaRequest(IWebBrowser chromiumWebBrowser, IBrowser browser, string originUrl, long newSize, IRequestCallback callback)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public void OnRenderProcessTerminated(IWebBrowser chromiumWebBrowser, IBrowser browser, CefTerminationStatus status)
|
||||
{
|
||||
}
|
||||
|
||||
public void OnRenderViewReady(IWebBrowser chromiumWebBrowser, IBrowser browser)
|
||||
{
|
||||
}
|
||||
|
||||
public bool OnSelectClientCertificate(IWebBrowser chromiumWebBrowser, IBrowser browser, bool isProxy, string host, int port, X509Certificate2Collection certificates, ISelectClientCertificateCallback callback)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,101 +0,0 @@
|
||||
using System;
|
||||
using System.Drawing;
|
||||
using System.Windows.Forms;
|
||||
using mRemoteNG.App;
|
||||
using mRemoteNG.Messages;
|
||||
using mRemoteNG.Resources.Language;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.PowerShell
|
||||
{
|
||||
public class ProtocolPowerShell : ProtocolBase
|
||||
{
|
||||
#region Private Fields
|
||||
|
||||
private IntPtr _handle;
|
||||
private readonly ConnectionInfo _connectionInfo;
|
||||
private ConsoleControl.ConsoleControl _consoleControl;
|
||||
|
||||
public ProtocolPowerShell(ConnectionInfo connectionInfo)
|
||||
{
|
||||
_connectionInfo = connectionInfo;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Public Methods
|
||||
|
||||
public override bool Connect()
|
||||
{
|
||||
try
|
||||
{
|
||||
Runtime.MessageCollector?.AddMessage(MessageClass.InformationMsg,
|
||||
"Attempting to start remote PowerShell session.", true);
|
||||
|
||||
_consoleControl = new ConsoleControl.ConsoleControl
|
||||
{
|
||||
Dock = DockStyle.Fill,
|
||||
BackColor = ColorTranslator.FromHtml("#012456"),
|
||||
ForeColor = Color.White,
|
||||
IsInputEnabled = true,
|
||||
Padding = new Padding(0, 20, 0, 0)
|
||||
};
|
||||
|
||||
_consoleControl.StartProcess(@"C:\Windows\system32\WindowsPowerShell\v1.0\PowerShell.exe",
|
||||
$@"-NoExit -Command ""$password = ConvertTo-SecureString '{_connectionInfo.Password}' -AsPlainText -Force; $cred = New-Object System.Management.Automation.PSCredential -ArgumentList @('{_connectionInfo.Domain}\{_connectionInfo.Username}', $password); Enter-PSSession -ComputerName {_connectionInfo.Hostname} -Credential $cred""");
|
||||
|
||||
while (!_consoleControl.IsHandleCreated) break;
|
||||
_handle = _consoleControl.Handle;
|
||||
NativeMethods.SetParent(_handle, InterfaceControl.Handle);
|
||||
|
||||
Resize(this, new EventArgs());
|
||||
base.Connect();
|
||||
return true;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector?.AddExceptionMessage(Language.ConnectionFailed, ex);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Focus()
|
||||
{
|
||||
try
|
||||
{
|
||||
NativeMethods.SetForegroundWindow(_handle);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionMessage(Language.IntAppFocusFailed, ex);
|
||||
}
|
||||
}
|
||||
|
||||
public override void Resize(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (InterfaceControl.Size == Size.Empty) return;
|
||||
NativeMethods.MoveWindow(_handle, -SystemInformation.FrameBorderSize.Width,
|
||||
-(SystemInformation.CaptionHeight + SystemInformation.FrameBorderSize.Height),
|
||||
InterfaceControl.Width + SystemInformation.FrameBorderSize.Width * 2,
|
||||
InterfaceControl.Height + SystemInformation.CaptionHeight +
|
||||
SystemInformation.FrameBorderSize.Height * 2, true);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionMessage(Language.IntAppResizeFailed, ex);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Enumerations
|
||||
|
||||
public enum Defaults
|
||||
{
|
||||
Port = 5985
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -1,41 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol
|
||||
{
|
||||
public enum ProtocolType
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rdp))]
|
||||
RDP = 0,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Vnc))]
|
||||
VNC = 1,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.SshV1))]
|
||||
SSH1 = 2,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.SshV2))]
|
||||
SSH2 = 3,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Telnet))]
|
||||
Telnet = 4,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rlogin))]
|
||||
Rlogin = 5,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Raw))]
|
||||
RAW = 6,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Http))]
|
||||
HTTP = 7,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Https))]
|
||||
HTTPS = 8,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.PowerShell))]
|
||||
PowerShell = 10,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.ExternalTool))]
|
||||
IntApp = 20
|
||||
}
|
||||
}
|
||||
@@ -1,317 +0,0 @@
|
||||
using mRemoteNG.App;
|
||||
using mRemoteNG.Messages;
|
||||
using mRemoteNG.Security.SymmetricEncryption;
|
||||
using mRemoteNG.Tools;
|
||||
using mRemoteNG.Tools.Cmdline;
|
||||
using mRemoteNG.UI;
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.Drawing;
|
||||
using System.Threading;
|
||||
using System.Windows.Forms;
|
||||
using mRemoteNG.Properties;
|
||||
using mRemoteNG.Resources.Language;
|
||||
|
||||
// ReSharper disable ArrangeAccessorOwnerBody
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol
|
||||
{
|
||||
public class PuttyBase : ProtocolBase
|
||||
{
|
||||
private const int IDM_RECONF = 0x50; // PuTTY Settings Menu ID
|
||||
private bool _isPuttyNg;
|
||||
private readonly DisplayProperties _display = new DisplayProperties();
|
||||
|
||||
#region Public Properties
|
||||
|
||||
protected Putty_Protocol PuttyProtocol { private get; set; }
|
||||
|
||||
protected Putty_SSHVersion PuttySSHVersion { private get; set; }
|
||||
|
||||
public IntPtr PuttyHandle { get; set; }
|
||||
|
||||
private Process PuttyProcess { get; set; }
|
||||
|
||||
public static string PuttyPath { get; set; }
|
||||
|
||||
public bool Focused => NativeMethods.GetForegroundWindow() == PuttyHandle;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Private Events & Handlers
|
||||
|
||||
private void ProcessExited(object sender, EventArgs e)
|
||||
{
|
||||
Event_Closed(this);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Public Methods
|
||||
|
||||
public bool isRunning()
|
||||
{
|
||||
return !PuttyProcess.HasExited;
|
||||
}
|
||||
|
||||
public override bool Connect()
|
||||
{
|
||||
try
|
||||
{
|
||||
_isPuttyNg = PuttyTypeDetector.GetPuttyType() == PuttyTypeDetector.PuttyType.PuttyNg;
|
||||
|
||||
PuttyProcess = new Process
|
||||
{
|
||||
StartInfo =
|
||||
{
|
||||
UseShellExecute = false,
|
||||
FileName = PuttyPath
|
||||
}
|
||||
};
|
||||
|
||||
var arguments = new CommandLineArguments {EscapeForShell = false};
|
||||
|
||||
arguments.Add("-load", InterfaceControl.Info.PuttySession);
|
||||
|
||||
if (!(InterfaceControl.Info is PuttySessionInfo))
|
||||
{
|
||||
arguments.Add("-" + PuttyProtocol);
|
||||
|
||||
if (PuttyProtocol == Putty_Protocol.ssh)
|
||||
{
|
||||
var username = "";
|
||||
var password = "";
|
||||
|
||||
if (!string.IsNullOrEmpty(InterfaceControl.Info?.Username))
|
||||
{
|
||||
username = InterfaceControl.Info.Username;
|
||||
}
|
||||
else
|
||||
{
|
||||
// ReSharper disable once SwitchStatementMissingSomeCases
|
||||
switch (Settings.Default.EmptyCredentials)
|
||||
{
|
||||
case "windows":
|
||||
username = Environment.UserName;
|
||||
break;
|
||||
case "custom":
|
||||
username = Settings.Default.DefaultUsername;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(InterfaceControl.Info?.Password))
|
||||
{
|
||||
password = InterfaceControl.Info.Password;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (Settings.Default.EmptyCredentials == "custom")
|
||||
{
|
||||
var cryptographyProvider = new LegacyRijndaelCryptographyProvider();
|
||||
password = cryptographyProvider.Decrypt(Settings.Default.DefaultPassword,
|
||||
Runtime.EncryptionKey);
|
||||
}
|
||||
}
|
||||
|
||||
arguments.Add("-" + (int)PuttySSHVersion);
|
||||
|
||||
if (!Force.HasFlag(ConnectionInfo.Force.NoCredentials))
|
||||
{
|
||||
if (!string.IsNullOrEmpty(username))
|
||||
{
|
||||
arguments.Add("-l", username);
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(password))
|
||||
{
|
||||
arguments.Add("-pw", password);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
arguments.Add("-P", InterfaceControl.Info.Port.ToString());
|
||||
arguments.Add(InterfaceControl.Info.Hostname);
|
||||
}
|
||||
|
||||
if (_isPuttyNg)
|
||||
{
|
||||
arguments.Add("-hwndparent", InterfaceControl.Handle.ToString());
|
||||
}
|
||||
|
||||
PuttyProcess.StartInfo.Arguments = arguments.ToString();
|
||||
// add additional SSH options, f.e. tunnel or noshell parameters that may be specified for the the connnection
|
||||
if (!string.IsNullOrEmpty(InterfaceControl.Info.SSHOptions))
|
||||
{
|
||||
PuttyProcess.StartInfo.Arguments += " " + InterfaceControl.Info.SSHOptions;
|
||||
}
|
||||
|
||||
PuttyProcess.EnableRaisingEvents = true;
|
||||
PuttyProcess.Exited += ProcessExited;
|
||||
|
||||
PuttyProcess.Start();
|
||||
PuttyProcess.WaitForInputIdle(Settings.Default.MaxPuttyWaitTime * 1000);
|
||||
|
||||
var startTicks = Environment.TickCount;
|
||||
while (PuttyHandle.ToInt32() == 0 &
|
||||
Environment.TickCount < startTicks + Settings.Default.MaxPuttyWaitTime * 1000)
|
||||
{
|
||||
if (_isPuttyNg)
|
||||
{
|
||||
PuttyHandle = NativeMethods.FindWindowEx(
|
||||
InterfaceControl.Handle, new IntPtr(0), null, null);
|
||||
}
|
||||
else
|
||||
{
|
||||
PuttyProcess.Refresh();
|
||||
PuttyHandle = PuttyProcess.MainWindowHandle;
|
||||
}
|
||||
|
||||
if (PuttyHandle.ToInt32() == 0)
|
||||
{
|
||||
Thread.Sleep(0);
|
||||
}
|
||||
}
|
||||
|
||||
if (!_isPuttyNg)
|
||||
{
|
||||
NativeMethods.SetParent(PuttyHandle, InterfaceControl.Handle);
|
||||
}
|
||||
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg, Language.PuttyStuff, true);
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg,
|
||||
string.Format(Language.PuttyHandle, PuttyHandle), true);
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg,
|
||||
string.Format(Language.PuttyTitle, PuttyProcess.MainWindowTitle),
|
||||
true);
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.InformationMsg,
|
||||
string.Format(Language.PanelHandle,
|
||||
InterfaceControl.Parent.Handle), true);
|
||||
|
||||
Resize(this, new EventArgs());
|
||||
base.Connect();
|
||||
return true;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.ErrorMsg,
|
||||
Language.ConnectionFailed + Environment.NewLine +
|
||||
ex.Message);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Focus()
|
||||
{
|
||||
try
|
||||
{
|
||||
NativeMethods.SetForegroundWindow(PuttyHandle);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.ErrorMsg,
|
||||
Language.PuttyFocusFailed + Environment.NewLine + ex.Message,
|
||||
true);
|
||||
}
|
||||
}
|
||||
|
||||
public override void Resize(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (InterfaceControl.Size == Size.Empty)
|
||||
return;
|
||||
|
||||
if (_isPuttyNg)
|
||||
{
|
||||
// PuTTYNG 0.70.0.1 and later doesn't have any window borders
|
||||
NativeMethods.MoveWindow(PuttyHandle, 0, 0, InterfaceControl.Width, InterfaceControl.Height, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
var scaledFrameBorderHeight = _display.ScaleHeight(SystemInformation.FrameBorderSize.Height);
|
||||
var scaledFrameBorderWidth = _display.ScaleWidth(SystemInformation.FrameBorderSize.Width);
|
||||
|
||||
NativeMethods.MoveWindow(PuttyHandle, -scaledFrameBorderWidth,
|
||||
-(SystemInformation.CaptionHeight + scaledFrameBorderHeight),
|
||||
InterfaceControl.Width + scaledFrameBorderWidth * 2,
|
||||
InterfaceControl.Height + SystemInformation.CaptionHeight +
|
||||
scaledFrameBorderHeight * 2,
|
||||
true);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.ErrorMsg,
|
||||
Language.PuttyResizeFailed + Environment.NewLine + ex.Message,
|
||||
true);
|
||||
}
|
||||
}
|
||||
|
||||
public override void Close()
|
||||
{
|
||||
try
|
||||
{
|
||||
if (PuttyProcess.HasExited == false)
|
||||
{
|
||||
PuttyProcess.Kill();
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.ErrorMsg,
|
||||
Language.PuttyKillFailed + Environment.NewLine + ex.Message,
|
||||
true);
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
PuttyProcess.Dispose();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.ErrorMsg,
|
||||
Language.PuttyDisposeFailed + Environment.NewLine + ex.Message,
|
||||
true);
|
||||
}
|
||||
|
||||
base.Close();
|
||||
}
|
||||
|
||||
public void ShowSettingsDialog()
|
||||
{
|
||||
try
|
||||
{
|
||||
NativeMethods.PostMessage(PuttyHandle, NativeMethods.WM_SYSCOMMAND, (IntPtr)IDM_RECONF, (IntPtr)0);
|
||||
NativeMethods.SetForegroundWindow(PuttyHandle);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddMessage(MessageClass.ErrorMsg,
|
||||
Language.PuttyShowSettingsDialogFailed + Environment.NewLine +
|
||||
ex.Message, true);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Enums
|
||||
|
||||
protected enum Putty_Protocol
|
||||
{
|
||||
ssh = 0,
|
||||
telnet = 1,
|
||||
rlogin = 2,
|
||||
raw = 3,
|
||||
serial = 4
|
||||
}
|
||||
|
||||
protected enum Putty_SSHVersion
|
||||
{
|
||||
ssh1 = 1,
|
||||
ssh2 = 2
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.RDP
|
||||
{
|
||||
public enum AuthenticationLevel
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.AlwaysConnectEvenIfAuthFails))]
|
||||
NoAuth = 0,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.DontConnectWhenAuthFails))]
|
||||
AuthRequired = 1,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.WarnIfAuthFails))]
|
||||
WarnOnFailedAuth = 2
|
||||
}
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.RDP
|
||||
{
|
||||
public enum RDGatewayUsageMethod
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Never))]
|
||||
Never = 0, // TSC_PROXY_MODE_NONE_DIRECT
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Always))]
|
||||
Always = 1, // TSC_PROXY_MODE_DIRECT
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Detect))]
|
||||
Detect = 2 // TSC_PROXY_MODE_DETECT
|
||||
}
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.RDP
|
||||
{
|
||||
public enum RDGatewayUseConnectionCredentials
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.UseDifferentUsernameAndPassword))]
|
||||
No = 0,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.UseSameUsernameAndPassword))]
|
||||
Yes = 1,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.UseSmartCard))]
|
||||
SmartCard = 2
|
||||
}
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.RDP
|
||||
{
|
||||
public enum RDPColors
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rdp256Colors))]
|
||||
Colors256 = 8,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rdp32768Colors))]
|
||||
Colors15Bit = 15,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rdp65536Colors))]
|
||||
Colors16Bit = 16,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rdp16777216Colors))]
|
||||
Colors24Bit = 24,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Rdp4294967296Colors))]
|
||||
Colors32Bit = 32
|
||||
}
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.RDP
|
||||
{
|
||||
public enum RDPSoundQuality
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Dynamic))]
|
||||
Dynamic = 0,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.Medium))]
|
||||
Medium = 1,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.High))]
|
||||
High = 2
|
||||
}
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
using mRemoteNG.Resources.Language;
|
||||
using mRemoteNG.Tools;
|
||||
|
||||
namespace mRemoteNG.Connection.Protocol.RDP
|
||||
{
|
||||
public enum RDPSounds
|
||||
{
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.RdpSoundBringToThisComputer))]
|
||||
BringToThisComputer = 0,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.RdpSoundLeaveAtRemoteComputer))]
|
||||
LeaveAtRemoteComputer = 1,
|
||||
|
||||
[LocalizedAttributes.LocalizedDescription(nameof(Language.DoNotPlay))]
|
||||
DoNotPlay = 2
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
using mRemoteNG.Connection.Protocol;
|
||||
using mRemoteNG.Resources.Language;
|
||||
|
||||
namespace mRemoteNG.Connection
|
||||
{
|
||||
public class WebHelper
|
||||
{
|
||||
public static void GoToUrl(string url)
|
||||
{
|
||||
var connectionInfo = new ConnectionInfo();
|
||||
connectionInfo.CopyFrom(DefaultConnectionInfo.Instance);
|
||||
|
||||
connectionInfo.Name = "";
|
||||
connectionInfo.Hostname = url;
|
||||
connectionInfo.Protocol = url.StartsWith("https:") ? ProtocolType.HTTPS : ProtocolType.HTTP;
|
||||
connectionInfo.SetDefaultPort();
|
||||
if (string.IsNullOrEmpty(connectionInfo.Panel))
|
||||
connectionInfo.Panel = Language.General;
|
||||
connectionInfo.IsQuickConnect = true;
|
||||
var connectionInitiator = new ConnectionInitiator();
|
||||
connectionInitiator.OpenConnection(connectionInfo, ConnectionInfo.Force.DoNotJump);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
*************
|
||||
SSH Tunneling
|
||||
*************
|
||||
|
||||
You can use any configured SSH connection to be used as a tunnel server for another connection.
|
||||
|
||||
.. figure:: /images/ssh_tunnel.png
|
||||
|
||||
If an SSH Tunnel is configured the connection is searched and if found a free local TCP port determined. The SSH tunnel connection
|
||||
is setup with additional parameters for the tunnel. The original connection info is copied and the copy is modified to connect
|
||||
to local host and the local TCP port and the target connection is opened.
|
||||
You can use the SSH connection attribute for additional SSH options. It can be used by all
|
||||
normal SSH connections as well to specify any additional options, e.g. to not start a shell which some SSH servers.
|
||||
|
Before Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 3.9 KiB |
|
Before Width: | Height: | Size: 10 KiB |
@@ -1,175 +0,0 @@
|
||||
if exists (select * from dbo.sysobjects
|
||||
where id = object_id(N'[dbo].[tblCons]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
|
||||
drop table [dbo].[tblCons]
|
||||
GO
|
||||
|
||||
if exists (select * from dbo.sysobjects
|
||||
where id = object_id(N'[dbo].[tblRoot]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
|
||||
drop table [dbo].[tblRoot]
|
||||
GO
|
||||
|
||||
if exists (select * from dbo.sysobjects
|
||||
where id = object_id(N'[dbo].[tblUpdate]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
|
||||
drop table [dbo].[tblUpdate]
|
||||
GO
|
||||
|
||||
CREATE TABLE [dbo].[tblCons] (
|
||||
[ID] int NOT NULL IDENTITY(1,1),
|
||||
[ConstantID] varchar(128) NOT NULL PRIMARY KEY,
|
||||
[PositionID] int NOT NULL,
|
||||
[ParentID] varchar(128),
|
||||
[LastChange] datetime NOT NULL,
|
||||
[Name] varchar(128) NOT NULL,
|
||||
[Type] varchar(32) NOT NULL,
|
||||
[Expanded] bit NOT NULL,
|
||||
[AutomaticResize] bit DEFAULT ((1)) NOT NULL,
|
||||
[CacheBitmaps] bit NOT NULL,
|
||||
[Colors] varchar(32) NOT NULL,
|
||||
[ConnectToConsole] bit NOT NULL,
|
||||
[Connected] bit NOT NULL,
|
||||
[Description] varchar(1024),
|
||||
[DisableCursorBlinking] bit NOT NULL,
|
||||
[DisableCursorShadow] bit NOT NULL,
|
||||
[DisableFullWindowDrag] bit NOT NULL,
|
||||
[DisableMenuAnimations] bit NOT NULL,
|
||||
[DisplayThemes] bit NOT NULL,
|
||||
[DisplayWallpaper] bit NOT NULL,
|
||||
[Domain] varchar(512),
|
||||
[EnableDesktopComposition] bit NOT NULL,
|
||||
[EnableFontSmoothing] bit NOT NULL,
|
||||
[ExtApp] varchar(256),
|
||||
[Favorite] tinyint NOT NULL,
|
||||
[Hostname] varchar(512),
|
||||
[ICAEncryptionStrength] varchar(32) NOT NULL,
|
||||
[Icon] varchar(128) NOT NULL,
|
||||
[LoadBalanceInfo] varchar(1024),
|
||||
[MacAddress] varchar(32),
|
||||
[Panel] varchar(128) NOT NULL,
|
||||
[Password] varchar(1024),
|
||||
[Port] int NOT NULL,
|
||||
[PostExtApp] varchar(256),
|
||||
[PreExtApp] varchar(256),
|
||||
[Protocol] varchar(32) NOT NULL,
|
||||
[PuttySession] varchar(128),
|
||||
[RDGatewayDomain] varchar(512),
|
||||
[RDGatewayHostname] varchar(512),
|
||||
[RDGatewayPassword] varchar(1024),
|
||||
[RDGatewayUsageMethod] varchar(32) NOT NULL,
|
||||
[RDGatewayUseConnectionCredentials] varchar(32) NOT NULL,
|
||||
[RDGatewayUsername] varchar(512),
|
||||
[RDPAlertIdleTimeout] bit NOT NULL,
|
||||
[RDPAuthenticationLevel] varchar(32) NOT NULL,
|
||||
[RDPMinutesToIdleTimeout] int NOT NULL,
|
||||
[RdpVersion] varchar(10),
|
||||
[RedirectAudioCapture] bit NOT NULL,
|
||||
[RedirectClipboard] bit DEFAULT ((0)) NOT NULL,
|
||||
[RedirectDiskDrives] bit NOT NULL,
|
||||
[RedirectKeys] bit NOT NULL,
|
||||
[RedirectPorts] bit NOT NULL,
|
||||
[RedirectPrinters] bit NOT NULL,
|
||||
[RedirectSmartCards] bit NOT NULL,
|
||||
[RedirectSound] varchar(64) NOT NULL,
|
||||
[RenderingEngine] varchar(10),
|
||||
[Resolution] varchar(32) NOT NULL,
|
||||
[SSHOptions] varchar(1024) NOT NULL,
|
||||
[SSHTunnelConnectionName] varchar(128) NOT NULL,
|
||||
[SoundQuality] varchar(20) NOT NULL,
|
||||
[UseCredSsp] bit NOT NULL,
|
||||
[UseEnhancedMode] bit DEFAULT ((0)),
|
||||
[UseVmId] bit,
|
||||
[UserField] varchar(256),
|
||||
[Username] varchar(512),
|
||||
[VNCAuthMode] varchar(10),
|
||||
[VNCColors] varchar(10),
|
||||
[VNCCompression] varchar(10),
|
||||
[VNCEncoding] varchar(20),
|
||||
[VNCProxyIP] varchar(128),
|
||||
[VNCProxyPassword] varchar(1024),
|
||||
[VNCProxyPort] int,
|
||||
[VNCProxyType] varchar(20),
|
||||
[VNCProxyUsername] varchar(512),
|
||||
[VNCSmartSizeMode] varchar(20),
|
||||
[VNCViewOnly] bit NOT NULL,
|
||||
[VmId] varchar(100),
|
||||
[InheritAutomaticResize] bit DEFAULT ((0)) NOT NULL,
|
||||
[InheritCacheBitmaps] bit NOT NULL,
|
||||
[InheritColors] bit NOT NULL,
|
||||
[InheritDescription] bit NOT NULL,
|
||||
[InheritDisableCursorBlinking] bit NOT NULL,
|
||||
[InheritDisableCursorShadow] bit NOT NULL,
|
||||
[InheritDisableFullWindowDrag] bit NOT NULL,
|
||||
[InheritDisableMenuAnimations] bit NOT NULL,
|
||||
[InheritDisplayThemes] bit NOT NULL,
|
||||
[InheritDisplayWallpaper] bit NOT NULL,
|
||||
[InheritDomain] bit NOT NULL,
|
||||
[InheritEnableDesktopComposition] bit NOT NULL,
|
||||
[InheritEnableFontSmoothing] bit NOT NULL,
|
||||
[InheritExtApp] bit NOT NULL,
|
||||
[InheritFavorite] bit NOT NULL,
|
||||
[InheritICAEncryptionStrength] bit NOT NULL,
|
||||
[InheritIcon] bit NOT NULL,
|
||||
[InheritLoadBalanceInfo] bit DEFAULT ((0)) NOT NULL,
|
||||
[InheritMacAddress] bit NOT NULL,
|
||||
[InheritPanel] bit NOT NULL,
|
||||
[InheritPassword] bit NOT NULL,
|
||||
[InheritPort] bit NOT NULL,
|
||||
[InheritPostExtApp] bit NOT NULL,
|
||||
[InheritPreExtApp] bit NOT NULL,
|
||||
[InheritProtocol] bit NOT NULL,
|
||||
[InheritPuttySession] bit NOT NULL,
|
||||
[InheritRDGatewayDomain] bit NOT NULL,
|
||||
[InheritRDGatewayHostname] bit NOT NULL,
|
||||
[InheritRDGatewayPassword] bit NOT NULL,
|
||||
[InheritRDGatewayUsageMethod] bit NOT NULL,
|
||||
[InheritRDGatewayUseConnectionCredentials] bit NOT NULL,
|
||||
[InheritRDGatewayUsername] bit NOT NULL,
|
||||
[InheritRDPAlertIdleTimeout] bit NOT NULL,
|
||||
[InheritRDPAuthenticationLevel] bit NOT NULL,
|
||||
[InheritRDPMinutesToIdleTimeout] bit NOT NULL,
|
||||
[InheritRdpVersion] bit DEFAULT ((0)) NOT NULL,
|
||||
[InheritRedirectAudioCapture] bit NOT NULL,
|
||||
[InheritRedirectClipboard] bit DEFAULT ((0)) NOT NULL,
|
||||
[InheritRedirectDiskDrives] bit NOT NULL,
|
||||
[InheritRedirectKeys] bit NOT NULL,
|
||||
[InheritRedirectPorts] bit NOT NULL,
|
||||
[InheritRedirectPrinters] bit NOT NULL,
|
||||
[InheritRedirectSmartCards] bit NOT NULL,
|
||||
[InheritRedirectSound] bit NOT NULL,
|
||||
[InheritRenderingEngine] bit NOT NULL,
|
||||
[InheritResolution] bit NOT NULL,
|
||||
[InheritSSHOptions] bit NOT NULL,
|
||||
[InheritSSHTunnelConnectionName] bit NOT NULL,
|
||||
[InheritSoundQuality] bit NOT NULL,
|
||||
[InheritUseConsoleSession] bit NOT NULL,
|
||||
[InheritUseCredSsp] bit NOT NULL,
|
||||
[InheritUseEnhancedMode] bit DEFAULT ((0)),
|
||||
[InheritUseVmId] bit,
|
||||
[InheritUserField] bit NOT NULL,
|
||||
[InheritUsername] bit NOT NULL,
|
||||
[InheritVNCAuthMode] bit NOT NULL,
|
||||
[InheritVNCColors] bit NOT NULL,
|
||||
[InheritVNCCompression] bit NOT NULL,
|
||||
[InheritVNCEncoding] bit NOT NULL,
|
||||
[InheritVNCProxyIP] bit NOT NULL,
|
||||
[InheritVNCProxyPassword] bit NOT NULL,
|
||||
[InheritVNCProxyPort] bit NOT NULL,
|
||||
[InheritVNCProxyType] bit NOT NULL,
|
||||
[InheritVNCProxyUsername] bit NOT NULL,
|
||||
[InheritVNCSmartSizeMode] bit NOT NULL,
|
||||
[InheritVNCViewOnly] bit NOT NULL,
|
||||
[InheritVmId] bit
|
||||
) ON [PRIMARY]
|
||||
GO
|
||||
|
||||
CREATE TABLE [dbo].[tblRoot] (
|
||||
[Name] [varchar] (2048) NOT NULL ,
|
||||
[Export] [bit] NOT NULL ,
|
||||
[Protected] [varchar] (4048) NOT NULL ,
|
||||
[ConfVersion] [float] NOT NULL
|
||||
) ON [PRIMARY]
|
||||
GO
|
||||
|
||||
CREATE TABLE [dbo].[tblUpdate] (
|
||||
[LastUpdate] [datetime] NULL
|
||||
) ON [PRIMARY]
|
||||
GO
|
||||
@@ -1,205 +0,0 @@
|
||||
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||
/*!40101 SET NAMES utf8 */;
|
||||
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
|
||||
/*!40103 SET TIME_ZONE='+00:00' */;
|
||||
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
|
||||
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
|
||||
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
|
||||
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
|
||||
|
||||
--
|
||||
-- Table structure for table `tblCons`
|
||||
--
|
||||
|
||||
DROP TABLE IF EXISTS `tblCons`;
|
||||
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||
/*!40101 SET character_set_client = utf8 */;
|
||||
CREATE TABLE `tblCons` (
|
||||
`ID` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`ConstantID` varchar(128) NOT NULL,
|
||||
`PositionID` int(11) NOT NULL,
|
||||
`ParentID` varchar(128) DEFAULT NULL,
|
||||
`LastChange` datetime NOT NULL,
|
||||
`Name` varchar(128) NOT NULL,
|
||||
`Type` varchar(32) NOT NULL,
|
||||
`Expanded` tinyint(1) NOT NULL,
|
||||
`AutomaticResize` tinyint(1) NOT NULL DEFAULT 1,
|
||||
`CacheBitmaps` tinyint(1) NOT NULL,
|
||||
`Colors` varchar(32) NOT NULL,
|
||||
`ConnectToConsole` tinyint(1) NOT NULL,
|
||||
`Connected` tinyint(1) NOT NULL,
|
||||
`Description` varchar(1024) DEFAULT NULL,
|
||||
`DisableCursorBlinking` tinyint(1) NOT NULL,
|
||||
`DisableCursorShadow` tinyint(1) NOT NULL,
|
||||
`DisableFullWindowDrag` tinyint(1) NOT NULL,
|
||||
`DisableMenuAnimations` tinyint(1) NOT NULL,
|
||||
`DisplayThemes` tinyint(1) NOT NULL,
|
||||
`DisplayWallpaper` tinyint(1) NOT NULL,
|
||||
`Domain` varchar(512) DEFAULT NULL,
|
||||
`EnableDesktopComposition` tinyint(1) NOT NULL,
|
||||
`EnableFontSmoothing` tinyint(1) NOT NULL,
|
||||
`ExtApp` varchar(256) DEFAULT NULL,
|
||||
`Favorite` tinyint(1) NOT NULL,
|
||||
`Hostname` varchar(512) DEFAULT NULL,
|
||||
`LoadBalanceInfo` varchar(1024) DEFAULT NULL,
|
||||
`MacAddress` varchar(32) DEFAULT NULL,
|
||||
`Panel` varchar(128) NOT NULL,
|
||||
`Password` varchar(1024) DEFAULT NULL,
|
||||
`Port` int(11) NOT NULL,
|
||||
`PostExtApp` varchar(256) DEFAULT NULL,
|
||||
`PreExtApp` varchar(256) DEFAULT NULL,
|
||||
`Protocol` varchar(32) NOT NULL,
|
||||
`PuttySession` varchar(128) DEFAULT NULL,
|
||||
`RDGatewayDomain` varchar(512) DEFAULT NULL,
|
||||
`RDGatewayHostname` varchar(512) DEFAULT NULL,
|
||||
`RDGatewayPassword` varchar(1024) DEFAULT NULL,
|
||||
`RDGatewayUsageMethod` varchar(32) NOT NULL,
|
||||
`RDGatewayUseConnectionCredentials` varchar(32) NOT NULL,
|
||||
`RDGatewayUsername` varchar(512) DEFAULT NULL,
|
||||
`RDPAlertIdleTimeout` tinyint(1) NOT NULL,
|
||||
`RDPAuthenticationLevel` varchar(32) NOT NULL,
|
||||
`RDPMinutesToIdleTimeout` int(11) NOT NULL,
|
||||
`RdpVersion` varchar(10) DEFAULT NULL,
|
||||
`RedirectAudioCapture` tinyint(1) NOT NULL,
|
||||
`RedirectClipboard` tinyint(1) NOT NULL DEFAULT 0,
|
||||
`RedirectDiskDrives` tinyint(1) NOT NULL,
|
||||
`RedirectKeys` tinyint(1) NOT NULL,
|
||||
`RedirectPorts` tinyint(1) NOT NULL,
|
||||
`RedirectPrinters` tinyint(1) NOT NULL,
|
||||
`RedirectSmartCards` tinyint(1) NOT NULL,
|
||||
`RedirectSound` varchar(64) NOT NULL,
|
||||
`RenderingEngine` varchar(10) DEFAULT NULL,
|
||||
`Resolution` varchar(32) NOT NULL,
|
||||
`SSHOptions` varchar(1024) NOT NULL,
|
||||
`SSHTunnelConnectionName` varchar(128) NOT NULL,
|
||||
`SoundQuality` varchar(20) NOT NULL,
|
||||
`UseCredSsp` tinyint(1) NOT NULL,
|
||||
`UseEnhancedMode` tinyint(1) DEFAULT NULL,
|
||||
`UseVmId` tinyint(1) DEFAULT NULL,
|
||||
`UserField` varchar(256) DEFAULT NULL,
|
||||
`Username` varchar(512) DEFAULT NULL,
|
||||
`VNCAuthMode` varchar(10) DEFAULT NULL,
|
||||
`VNCColors` varchar(10) DEFAULT NULL,
|
||||
`VNCCompression` varchar(10) DEFAULT NULL,
|
||||
`VNCEncoding` varchar(20) DEFAULT NULL,
|
||||
`VNCProxyIP` varchar(128) DEFAULT NULL,
|
||||
`VNCProxyPassword` varchar(1024) DEFAULT NULL,
|
||||
`VNCProxyPort` int(11) DEFAULT NULL,
|
||||
`VNCProxyType` varchar(20) DEFAULT NULL,
|
||||
`VNCProxyUsername` varchar(512) DEFAULT NULL,
|
||||
`VNCSmartSizeMode` varchar(20) DEFAULT NULL,
|
||||
`VNCViewOnly` tinyint(1) NOT NULL,
|
||||
`VmId` varchar(512) DEFAULT NULL,
|
||||
`ICAEncryptionStrength` varchar(32) NOT NULL,
|
||||
`Icon` varchar(128) NOT NULL,
|
||||
`InheritAutomaticResize` tinyint(1) NOT NULL DEFAULT 0,
|
||||
`InheritCacheBitmaps` tinyint(1) NOT NULL,
|
||||
`InheritColors` tinyint(1) NOT NULL,
|
||||
`InheritDescription` tinyint(1) NOT NULL,
|
||||
`InheritDisableCursorBlinking` tinyint(1) NOT NULL,
|
||||
`InheritDisableCursorShadow` tinyint(1) NOT NULL,
|
||||
`InheritDisableFullWindowDrag` tinyint(1) NOT NULL,
|
||||
`InheritDisableMenuAnimations` tinyint(1) NOT NULL,
|
||||
`InheritDisplayThemes` tinyint(1) NOT NULL,
|
||||
`InheritDisplayWallpaper` tinyint(1) NOT NULL,
|
||||
`InheritDomain` tinyint(1) NOT NULL,
|
||||
`InheritEnableDesktopComposition` tinyint(1) NOT NULL,
|
||||
`InheritEnableFontSmoothing` tinyint(1) NOT NULL,
|
||||
`InheritExtApp` tinyint(1) NOT NULL,
|
||||
`InheritFavorite` tinyint(1) NOT NULL,
|
||||
`InheritICAEncryptionStrength` tinyint(1) NOT NULL,
|
||||
`InheritIcon` tinyint(1) NOT NULL,
|
||||
`InheritLoadBalanceInfo` tinyint(1) NOT NULL DEFAULT 0,
|
||||
`InheritMacAddress` tinyint(1) NOT NULL,
|
||||
`InheritPanel` tinyint(1) NOT NULL,
|
||||
`InheritPassword` tinyint(1) NOT NULL,
|
||||
`InheritPort` tinyint(1) NOT NULL,
|
||||
`InheritPostExtApp` tinyint(1) NOT NULL,
|
||||
`InheritPreExtApp` tinyint(1) NOT NULL,
|
||||
`InheritProtocol` tinyint(1) NOT NULL,
|
||||
`InheritPuttySession` tinyint(1) NOT NULL,
|
||||
`InheritRDGatewayDomain` tinyint(1) NOT NULL,
|
||||
`InheritRDGatewayHostname` tinyint(1) NOT NULL,
|
||||
`InheritRDGatewayPassword` tinyint(1) NOT NULL,
|
||||
`InheritRDGatewayUsageMethod` tinyint(1) NOT NULL,
|
||||
`InheritRDGatewayUseConnectionCredentials` tinyint(1) NOT NULL,
|
||||
`InheritRDGatewayUsername` tinyint(1) NOT NULL,
|
||||
`InheritRDPAlertIdleTimeout` tinyint(1) NOT NULL,
|
||||
`InheritRDPAuthenticationLevel` tinyint(1) NOT NULL,
|
||||
`InheritRDPMinutesToIdleTimeout` tinyint(1) NOT NULL,
|
||||
`InheritRdpVersion` tinyint(1) NOT NULL DEFAULT 0,
|
||||
`InheritRedirectAudioCapture` tinyint(1) NOT NULL,
|
||||
`InheritRedirectClipboard` tinyint(1) NOT NULL DEFAULT 0,
|
||||
`InheritRedirectDiskDrives` tinyint(1) NOT NULL,
|
||||
`InheritRedirectKeys` tinyint(1) NOT NULL,
|
||||
`InheritRedirectPorts` tinyint(1) NOT NULL,
|
||||
`InheritRedirectPrinters` tinyint(1) NOT NULL,
|
||||
`InheritRedirectSmartCards` tinyint(1) NOT NULL,
|
||||
`InheritRedirectSound` tinyint(1) NOT NULL,
|
||||
`InheritRenderingEngine` tinyint(1) NOT NULL,
|
||||
`InheritResolution` tinyint(1) NOT NULL,
|
||||
`InheritSSHOptions` tinyint(1) NOT NULL,
|
||||
`InheritSSHTunnelConnectionName` tinyint(1) NOT NULL,
|
||||
`InheritSoundQuality` tinyint(1) NOT NULL,
|
||||
`InheritUseConsoleSession` tinyint(1) NOT NULL,
|
||||
`InheritUseCredSsp` tinyint(1) NOT NULL,
|
||||
`InheritUseEnhancedMode` tinyint(1) DEFAULT NULL,
|
||||
`InheritUseVmId` tinyint(1) DEFAULT NULL,
|
||||
`InheritUserField` tinyint(1) NOT NULL,
|
||||
`InheritUsername` tinyint(1) NOT NULL,
|
||||
`InheritVNCAuthMode` tinyint(1) NOT NULL,
|
||||
`InheritVNCColors` tinyint(1) NOT NULL,
|
||||
`InheritVNCCompression` tinyint(1) NOT NULL,
|
||||
`InheritVNCEncoding` tinyint(1) NOT NULL,
|
||||
`InheritVNCProxyIP` tinyint(1) NOT NULL,
|
||||
`InheritVNCProxyPassword` tinyint(1) NOT NULL,
|
||||
`InheritVNCProxyPort` tinyint(1) NOT NULL,
|
||||
`InheritVNCProxyType` tinyint(1) NOT NULL,
|
||||
`InheritVNCProxyUsername` tinyint(1) NOT NULL,
|
||||
`InheritVNCSmartSizeMode` tinyint(1) NOT NULL,
|
||||
`InheritVNCViewOnly` tinyint(1) NOT NULL,
|
||||
`InheritVmId` tinyint(1) DEFAULT NULL,
|
||||
PRIMARY KEY (`ConstantID`),
|
||||
UNIQUE (`ID`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3324 DEFAULT CHARSET=latin1;
|
||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||
|
||||
--
|
||||
-- Table structure for table `tblRoot`
|
||||
--
|
||||
|
||||
DROP TABLE IF EXISTS `tblRoot`;
|
||||
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||
/*!40101 SET character_set_client = utf8 */;
|
||||
CREATE TABLE `tblRoot` (
|
||||
`Name` varchar(2048) NOT NULL,
|
||||
`Export` tinyint(1) NOT NULL,
|
||||
`Protected` varchar(4048) NOT NULL,
|
||||
`ConfVersion` double NOT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||
|
||||
--
|
||||
-- Table structure for table `tblUpdate`
|
||||
--
|
||||
|
||||
DROP TABLE IF EXISTS `tblUpdate`;
|
||||
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||
/*!40101 SET character_set_client = utf8 */;
|
||||
CREATE TABLE `tblUpdate` (
|
||||
`LastUpdate` datetime(3) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||
|
||||
|
||||
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
|
||||
|
||||
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
|
||||
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
|
||||
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
|
||||
@@ -1,34 +0,0 @@
|
||||
*****************************
|
||||
Default Connection Properties
|
||||
*****************************
|
||||
|
||||
Default connection properties are a template that is applied when creating new connections. You can set both property values and inheritance settings that will be set in new connections.
|
||||
|
||||
.. note::
|
||||
Currently, default connection properties are saved within the user settings of mRemoteNG and not with the connection file. Sharing a connection file between multiple machines will not share default connection properties.
|
||||
|
||||
|
||||
How it is used
|
||||
==============
|
||||
|
||||
New Folders/Connections
|
||||
-----------------------
|
||||
When a new folder or connection is created, all default properties and default inheritance are applied to it.
|
||||
|
||||
.. note::
|
||||
Changing default properties does not affect existing connections. The default values are only applied when the connection is first created.
|
||||
|
||||
|
||||
Quick Connections
|
||||
-----------------
|
||||
Default connection properties are also used when establishing quick connections. See :doc:`quick_connect` for more details.
|
||||
|
||||
|
||||
How to set them
|
||||
===============
|
||||
You can set default properties and inheritance by going to the Connection Tree and clicking the appropriate button for the default settings you would like to change.
|
||||
|
||||
.. figure:: /images/default_properties.png
|
||||
|
||||
- **Red** - Default connection properties
|
||||
- **Green** - Default connection inheritance
|
||||
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB |