Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/T3los/mRemoteNGOpenVPN
https://github.com/T3los/mRemoteNGOpenVPN
Last synced: 8 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/T3los/mRemoteNGOpenVPN
- Owner: T3los
- Created: 2021-07-02T16:01:50.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2022-08-01T10:53:02.000Z (over 2 years ago)
- Last Synced: 2024-08-01T12:23:40.576Z (3 months ago)
- Language: PowerShell
- Size: 22.5 KB
- Stars: 12
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# mRemoteNG OpenVPN External tool
## Synopsis
Connect to OpenVPN via mRemoteNG external tool.
## Description
- Automatically connect to the right OpenVPN configuration before attempting to connect to the RDP.
- Can detect if OpenVPN is already running with the right configuration.
- When connecting, the script will try to read the logfile and close when connected. **// TODO : Stop if error**
- If not able to access the logfile, then wait 15 sec.
- Automaticlly disconnect the VPN when the RDP connection is closed.
- Before disconnecting the VPN, the script can check if there are others connected session in mRemoteNG still needing the VPN.## Configuration
### External Tool
The Userfield is used to pass parameters.\
Two external tools are needed, one to connect and another to disconnect. \
They must have the option 'Wait for exit' enabled :#### Connection :
```Bash
"path\to\file\RDPOpenVPN.ps1" -u %USERNAME% -p %PASSWORD% -config %USERFIELD%
```#### Disconnection :
```Bash
"path\to\file\RDPOpenVPN.ps1" -deco -config %USERFIELD%
```
![](img/extTool.png)### Session Configuration
Userfield should contain the OpenVPN configuration name and `-askdeco` if needed.Before external tool = Connection\
After external tool = Disconnection![](img/config.png)
\
PS: OpenVPN folder should be added in `PATH` or the folder location must be added in the script.
PPS: Enable silent connection in OpenVPN-gui.___
|
PARAMETER|INFO|
|----------------------------------------|----|
|-deco |Used for disconnection.|
|-askdeco |Will prevent the disconnection if there are other connected session in mRemoteNG with the same onfig.|
|-vpn \ |For future improvement, if more vpn can be added.|
|-config \ |The name of the OpenVPN config.|
|-u \ |Used to retrieve the username from mRemoteNG.|
|-p \ |Used to retrieve the password from mRemoteNG. **/!\ Special Character Escaping /!\\**. Check [doc](https://mremoteng.readthedocs.io/en/latest/user_interface/external_tools.html#special-character-escaping) for more info.|
|-w \ |Set a wait time in sec if the script was not able to find the VPN log. Default is 15 sec.|
I lost the game.