Commit Graph

184 Commits (f42b91dc2fa75b81badb093b062a5691ce07b75c)

Author SHA1 Message Date
Selva Nair 14615356e5 Do not clear saved passwords on verification failure
After a failure the auth-pass dialog is shown with the password
field prefilled but highlighted. This allows the user to easily
overwrite the password or resubmit the old password if the
failure was temporary.

After a private key passphrase failure, the dialog is not
prefilled with saved password as this failure happens locally
and in such cases the password is very likely wrong.

If the user aborts the dialog by pressing cancel, the saved
password will get used during the next connection attempt.

Wrong username or password warning text is changed to: "Wrong
credentials".

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-04-23 15:41:03 +03:00
Ilya Shipitsin 4a4a6ab52f remove unused resource
after https://github.com/OpenVPN/openvpn-gui/pull/188 that string
is not used anymore
2018-04-23 15:39:47 +03:00
Selva Nair b23c4c2736 Update year in the "About" tab
Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-04-02 20:59:25 -04:00
Ilya Shipitsin 1c020eee60 add EXSTYLE WS_EX_TOPMOST to login/auth window
(same way it is already done for key password dialog)
2018-03-10 11:00:02 -05:00
Ilya Shipitsin e7fd11812f simplify caption on user/password auth window
also add openvpn ico to auth window
2018-01-30 10:29:00 +02:00
Selva Nair ecb8e50c0f Display assigned IPs and connection stats on status window
- Show the assigned IP numbers, traffic stats (bytes in/out), and
  the GUI and OpenVPN core versions on the status window.

Note: IDS_TXT_BYTECOUNT = "Bytes in: %s out %s" needs translation.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-01-30 10:20:58 +02:00
Selva Nair c87c7387b3
Merge pull request #188 from selvanair/already-running-v2
Support sending commands to a running instance of the GUI
2018-01-24 07:38:07 -05:00
MaxXor eabd26fc18 Update german translation 2018-01-23 19:08:37 +01:00
Samuli Seppänen 64b0ae83c8
Merge pull request #192 from MaxXor/res-de
Update german translation
2018-01-23 14:04:16 +02:00
Selva Nair 874d0890dd Document sending commands to a running instance
Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-01-22 00:31:11 -05:00
Selva Nair 688f41878f More helpful message if already running
Why: The current message assumes the balloon to appear attached
to the icon which is not the case in Windows 10.

Based on feedback from larson0815 and Deantwo here:
https://github.com/selvanair/openvpn-gui/issues/5

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-01-20 11:43:02 -05:00
Selva Nair 0f21030774 Support sending commands to running instance
- New option --command <action> <params> to send commands to
  a running instance of openvpn-gui.exe
  Supported actions are
      connect, disconnect, reconnect
  each of which takes the name of the config (with or without the
  extension .ovpn) as a parameter;
      disconnect_all, exit
  which take no parameter and
      silent_connection
  which takes an optional parameter = 0 or 1 (1 is the default)

  Examples: with the gui running, start a new instance as

  openvpn-gui.exe --command disconnect myvpn : ask running instance
                        to disconnect myvpn if connected
  openvpn-gui.exe --command status myvpn     : ask running instance
                        to show the status window for myvpn if available
  openvpn-gui.exe --command disconnect_all   : ask running instance
                        to disconnect all active connections

- The second instance exits after issuing a SendMessage to the
  already running instance. If no action is specified, the running
  instance is notified to show a balloon to alert the user

- These messages may also be sent from scripts as COPYDATA messages
  with the wData element specifying the action to execute and lpData
  a pointer to the parameter. The dwData param must be one of
  WM_OVPN_xxx with xxx = START, STOP, RESTART, STOPALL, EXIT or
  SILENT. See main.h for their values.

v2: Bug fixes based on test reports from larson0815
here: https://github.com/selvanair/openvpn-gui/issues/5
and cron410 here: https://github.com/OpenVPN/openvpn-gui/issues/104

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-01-20 11:42:23 -05:00
Selva Nair 31896ce33b Add restart button to connection menus
- This works the same way as restart button in the status window
  but is more conveniently accessible from the tray menu.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2018-01-20 11:41:19 -05:00
Ilya Shipitsin 0642cb8fe5 better alignment of warning message 2018-01-06 21:14:11 +05:00
Ilya Shipitsin 52219fcebf russian localization for "no-auth-prompt" branch 2017-12-29 01:27:52 +05:00
Selva Nair 5fb23f6ad9 Auto submit saved auth-user-pass credentials after a brief delay
- Effective only when username and password are saved.
- The user may interrupt auto submission and edit the username/password.
- If silent_connection is on the dialog is bypassed without any delay.

v2 changes:
- Display message in normal text color and show remaining time

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-12-26 13:41:55 -05:00
Selva Nair d98ad55467 Change OK button style to BS_DEFPUSHBUTTON in auth-user-pass dialog
- Make the OK button appear highlighted as the default action so that
  the user can press enter and submit the form. This also gives a clearer
  indication of the default action when automatic submission of saved
  username/password activates.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-12-26 13:41:55 -05:00
Selva Nair 301a5e5644 Check for invalid characters in user inputs
- Flag password and username input if these contain an invalid character
  (currently only embedded '\n' is disallowed). Shows a popup when OK
  is pressed so that the user can correct the input and resubmit.

- Add an error message to the log when the management i/f returns
  ERROR for incorrectly parsed commands. Otherwise such errors go
  unnoticed.

Note: IDS_ERR_INVALID_USERNAME/PASSWORD need translations.

Reported and tested by: Florian Beier (H4ndl3 on github)
Fixes Trac: #958

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-11-20 09:53:31 -05:00
MaxXor 6fa818dcb0 Update german translation 2017-10-11 15:05:34 +02:00
Samuli Seppänen de777b8fb1 Merge pull request #184 from bubuleur/patch-1
Update of the French version of Open Vpn GUI
2017-10-07 13:53:31 +03:00
bubuleur 7c5ce7bcba Update openvpn-gui-res-fr.rc 2017-10-05 13:30:36 +02:00
bubuleur c8e825ca28 Update openvpn-gui-res-fr.rc 2017-08-29 11:30:12 +02:00
bubuleur bf826353d1 Update openvpn-gui-res-fr.rc 2017-08-29 09:53:09 +02:00
bubuleur c1237891ae Update of the French version of Open Vpn GUI
Hello,
I just put my contribution for the French translation of OpenVpn Gui
Can you put it in the next update
In thanking you
(The next update is for when?)
2017-08-27 14:59:55 +02:00
Frank Fesevur 735f4761b5 Give text the space it needs 2017-08-14 22:57:51 +02:00
Frank Fesevur cfdfb2d096 Translate title of tab 2017-08-14 22:57:15 +02:00
Pavel Zhovner 9c7a8af3d3 Ukranian translation for auth failure warnings
- Text width increased to avoid clipped text during commit
  by Selva Nair
2017-06-27 16:05:07 -04:00
Selva Nair d127bab27f Fix buttons overlapping with text in auth dialog for Korean
Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-06-27 16:05:07 -04:00
Selva Nair 29a8bba38c Resize private key password dialog to avoid clipped text
Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-06-27 16:05:07 -04:00
Ilya Shipitsin dd65e5372a russian localization for "warn-auth-failure" branch" 2017-06-27 16:01:18 -04:00
Selva Nair 1bd5a6faa9 Add a warning message when authentication is retried due to wrong credentials
- "Wrong username or password" message shown in the auth userpass dialog after
  an auth failure
- "Wrong password" message shown in the private key password dialog after a
  password failure.

These message texts are colored red by default (TODO: make the color customizable)

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-06-27 16:01:18 -04:00
nilswende c1ce443d57 use en dashes where they should be used 2017-06-18 15:56:40 +02:00
nilswende d95ee78fea translated lots, fixed typos where needed 2017-06-18 15:55:56 +02:00
Stevie Howard 4ead3222cf Fix typo "diffrent" 2017-06-15 14:41:23 -07:00
Samuli Seppänen fa5e306b4e Fixed clipping errors in the Finnish translation
Signed-off-by: Samuli Seppänen <samuli@openvpn.net>
2017-05-16 15:51:06 +03:00
Samuli Seppänen 9a4ad06b65 Add missing strings to Finnish translation
Signed-off-by: Samuli Seppänen <samuli@openvpn.net>
2017-05-12 10:10:20 +03:00
JoungKyun Kim f1599fa3e4 fixed typo 2017-05-10 14:15:01 +09:00
JoungKyun Kim 79add8b8ba fixed font size(increse to 9), font name(changed Malgun Gothic) and text position 2017-05-10 14:15:00 +09:00
JoungKyun Kim ea0e8b6bb4 add Korean localization by JoungKyun Kim 2017-05-10 14:14:06 +09:00
Samuli Seppänen fa2fd383ec Merge pull request #136 from Hexabitt/patch-1
Completed all missing translations to french
2017-03-22 10:55:07 +02:00
Hexabitt 68d80cc80d Update openvpn-gui-res-fr.rc 2017-03-19 01:13:09 +01:00
Samuli Seppänen 86a57aee0b Merge pull request #146 from Chocobo1/pr_109
Update and fix localization for zh-hant
2017-03-13 19:31:16 +02:00
Chocobo1 20dd73dec7 Address review comments 2017-03-12 22:30:55 +08:00
Selva Nair ad6f03f50f Merge pull request #118 from selvanair/validate-user
Check group membership without needing connection to DC

Acked-by: Gert Doering <gert@greenie.muc.de>
2017-03-07 08:28:55 -05:00
Hexabitt 5ce1ec592a Completed all the missing translations 2017-02-24 15:14:07 +01:00
Selva Nair da6d0c63b1 Merge pull request #110 from EagleErwin/patch-1
Translate missing Dutch strings and minor changes
2017-02-01 20:57:25 -05:00
Selva Nair be3d367abc Merge pull request #126 from Ashus/master
Czech translation added
2017-01-31 10:37:56 -05:00
Ashus a157944ccf Translation corrected by another developer, Elieux.
Signed-off-by: Ashus <github.com@ashus.net>
2017-01-27 20:57:22 +01:00
Ashus 2c6f1fa905 Czech translation added
Signed-off-by: Ashus <github.com@ashus.net>
2017-01-26 23:56:39 +01:00
Selva Nair d662991d13 Close service pipe in case of startup error
Without this the service will continue to wait for input from GUI
and log pipe read errors to the event log.
Also fix a typo in the error messgae shown.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-01-14 22:27:05 -05:00
Ilya Shipitsin dd33b9068d added Windows Vista/Win7/Win8/Win8.1/Win10 to compatibility manifest 2017-01-08 03:57:35 +05:00
Peter Chen 21d022a1b4
UI clipping fix, and misc wording fix/redundant punc removed 2017-01-05 01:12:28 +08:00
Selva Nair 9cea37ad80 Suppress warning popups if silent_connection is set
Warnings dsabled if silent_connection is true
- interactive service is not installed or not running
- duplicate configs found and ignored

v2: Update description of --silent_connection in README
and English resource file (translations not updated).

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2017-01-03 11:28:45 -05:00
Erwin Bronkhorst 3abcdef46c Translate missing Dutch strings and minor changes 2016-12-29 14:48:32 +01:00
Peter Chen 1b424a6f51
Update and fix localization in openvpn-gui-res-zh-hant.rc 2016-12-29 11:27:26 +08:00
aixxe 270ea5f160 Add 24x24 and 20x20 versions of each icon.
Signed-off-by: aixxe <me@aixxe.net>
2016-12-06 10:12:40 +00:00
Samuli Seppänen 8020ee1071 Merge pull request #91 from selvanair/pkcs11-pin-v3
pkcs11 pin prompt
2016-11-30 22:18:34 +02:00
Samuli Seppänen 8f57172c2d Merge pull request #99 from selvanair/dpi-aware
Make the program DPI aware
2016-11-30 08:34:01 +02:00
Selva Nair 6ce96ee3ae Rendering/Positioning fix
- Adjust widget positioning for text to render without
  clipping. Several language resource files affected.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-11-27 21:40:20 -05:00
Selva Nair 7033d5c1aa Copy updated copyright to language files
- Copy updates to copyright by commit 32c31ab942 in
  Englishc to all other language files.
- Change version displayed in About page to the form
  "a.b.c.d"
- General settings dialog is incomplete in chinese:
  copy from English version.

- Add the word "OpenVPN" in the About page of Norwegian
  mistakenly removed by commit d81b93d487..

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-11-27 20:41:08 -05:00
Stig Otnes Kolstad d81b93d487 Update Norwegian translations 2016-11-27 23:33:16 +01:00
Samuli Seppänen 10951c6160 Merge pull request #94 from zhovner/master
Fix Ukrainian localization
2016-11-25 20:11:01 +02:00
Samuli Seppänen e7ff5a4c13 Merge pull request #93 from ValdikSS/russian-fixes
Russian translation updates
2016-11-21 17:39:39 +02:00
Selva Nair 5fe0d5225e Make the program DPI aware
- Set dpi-awareness to true in the manifest (i.e., "system-dpi aware")
- Check system dpi and scale and/or position widgets and windows
  that depend on the system dpi (only components within the status
  window are affected).

Note: Declaring dpi awareness eliminates automatic rescaling of
windows that causes blurred text on high dpi monitors.
Windows 8.1 and later allow per monitor dpi setting which is
not handled here.
2016-11-19 21:57:39 -05:00
Selva Nair dca8160a37 Update version-info resource
- Add PRODUCTVERSION to the VERSIONINFO resource.
  Without this some versions of Windows (e.g., Server 2008 32bit)
  displays Product version = 0.0.0.0, File version = 11.1.0.0

- Also define the file and product versions in the stringinfo block
  as a stringified form of PACKAGE_VERSION_RESOURCE (e.g., "11.1.0.0").
  Windows versions that take the Product version from this block
  will now get the same value as older versions that use PRODUCTVERSION.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-11-18 17:54:00 -05:00
Selva Nair be417bb38f Support pkcs11 token insertion request and pin input
Note: IDS_NFO_TOKEN_PASSWORD_CAPTION and IDS_NFO_TOKEN_PASSWORD_REQUEST
strings need translation.

TODO: support for selecting pkcs11-id from the GUI

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-11-15 19:29:23 -05:00
Selva Nair 1a5ce44a99 Handle dynamic challenge/response
- Add a base64 decode function using Windows CyptoAPI
- Move multibyte to widechar conversions to a function
- Add config name to caption of password dialogs to help user
  identify the request
- Add new dialog template for generic password/PIN requests
  and use it to handle dynamic challenge

Note 1: if dynamic challenge response verification fails, an auth-failed
message is returned by the server causing the GUI to clear any saved
password even if the user-auth dialog itself succeeeded.

Note 2: Dialog template ID_DLG_CHALLENGE_RESPONSE added to language
files may require translation.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-11-15 19:14:32 -05:00
Pavel Zhovner 3aafabf8f5 fix Ukrainian localization 2016-11-13 15:47:28 +03:00
ValdikSS 3648896b33 More Russian fixes 2016-11-13 13:32:20 +03:00
ValdikSS 10c2a74312 Russian translation updates 2016-11-13 13:10:00 +03:00
Samuli Seppänen 32c31ab942 Update About page
Signed-off-by: Samuli Seppänen <samuli@openvpn.net>
2016-10-21 11:15:33 +03:00
Samuli Seppänen d3581746cb Merge pull request #80 from chipitsine/master
cleaned up unused resource
2016-10-11 15:12:20 +03:00
Ilya Shipitsin 0f531dc3ee cleaned up unused resource 2016-09-24 17:17:23 +05:00
Selva Nair 395caf88db Improve the message shown when no config files are found
Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-09-19 21:46:06 -04:00
Samuli Seppänen dbe459f418 Merge pull request #71 from ValdikSS/master
Update Russian translation
2016-09-17 12:22:56 +03:00
Samuli Seppänen 8226f17eff Merge pull request #72 from ValdikSS/nonewline
No new line for "Starting this connection requires membership in"
2016-08-29 11:57:03 +03:00
ValdikSS 7ab7f47fda Fix Italian typo 2016-08-28 22:26:42 +03:00
ValdikSS 06218b4f69 Update Russian translation v3 2016-08-28 22:24:13 +03:00
ValdikSS f2439c7970 Update Russian translation v2 2016-08-24 23:01:33 +03:00
ValdikSS e55de21e37 No new line for "Starting this connection requires membership in" 2016-08-24 19:51:47 +03:00
ValdikSS 187f646fa8 Update Russian translation 2016-08-24 13:07:35 +03:00
Ilya Shipitsin 3e57007f2b more russian translation 2016-08-24 00:05:33 +05:00
Selva Nair 5a47986ccb Make options saved in registry editable by user
Option ediitng dialogs are in two tabs: General and Advanced.
Proxy related options are left in the proxy tab. Options
config_dir, config_ext, log_dir, script timeouts and
service-only flag are in the Advanced tab. All other more commonly
used flags and options are in the General tab.

- As options are editable, save values in registry only when they differ
  from the default values. This leaves the registry clean and makes changing
  options and their defaults during updates easier.

- Entries for config_dir and log_dir must be absolute paths.
  Environemental variables such as %PROFILEDIR% may be used
  to construct these.

- Empty config_dir, config_ext and log_dir entries are silently
  ignored (i.e., the current values are left unchanged).

- Store all numeric and boolean parameters in registry as DWORD instead of
  strings.

- On startup, the default parameters are loaded, then the registry is read
  and finally command-line parameters parsedi.

- Out of range script timeout values in registry truncated with a
  warning instead of fatal error. This allows the user to access the
  settings dialog and make corrections.

- Save proxy and language settings under the same
  HKCU\Software\OpenVPN-GUI key as other options instead of under Nilings.

- Save the current version of the GUI in regsitry so that updates
  can be detected and any needed registry cleanup done.

- If no version info is present in the registry any values in OpenVPN-GUI
  key in HKCU are deleted for a clean start as this is the first version
  to save registry values in HKCU. Language and proxy data if present
  under Nilings is migrated.

Note: new controls in the General tab and newly added Advanced tab dialog
are copied to all language files from the English version. These need to
be translated.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-08-06 11:46:15 -04:00
Selva Nair 1c748e382d Simplify some parameters and registry keys
- Replace allow_password by a runtime check that enables password
  change menu only when the user has write-access to the key file.
- Read exe_path and priority from HKLM and do not duplicate in HKCU.
- Always allow the user to view the config: edit will succeed if user
  has write access.
- Always include the proxy settings tab which is the default.
- Remove the unused power event handling and disconnect_on_suspend key.
- Remove password_attempts -- user can stop the password dilaog
  by clicking cancel.
- Remove allow_service: implicitly enabled if service_only is used.
- Deprecate removed options in cmd-line parser
- Update README.rst
- Close config file before exit in GetKeyFileName
- Close thread and dialog handles in passphrase.c

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-08-06 11:46:15 -04:00
Ilya Shipitsin 1f60125439 save pass: russian translation 2016-07-22 16:34:43 +05:00
Frank Fesevur 6a0e681b67 Update Dutch translation 2016-07-15 19:56:42 +02:00
Selva Nair 5880fdcd02 Save username and optionally passwords
- Username and, optionally, password as well as the private
  key passphrase are saved in config-specific registry keys
- All saved data are kept encrypted using DPAPI
- The passphrase dialog is skipped if a valid saved private
  key password is available. However, the user-auth dialog
  is always presented, prefilled with the saved username
  and password.

Note: A text string "Save password" is added to three dialogs
in all language resource files. Additional text with ids
IDS_MENU_CLEARPASS and IDS_NFO_DELETE_PASS are added to the
STRINGTABLE only in the English language resource file.
All these need translations.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-05-29 19:35:30 -04:00
Leonardo Basilio ece6aef6a6 Launch on startup setting 2016-05-22 22:05:42 -03:00
Ilya Shipitsin 727eaee0c5 fix the following "warning"
x86_64-w64-mingw32-windres: warning: 5: 230: 1033: duplicate value
2016-05-12 14:34:09 +06:00
Frank Fesevur aba703fa8e Fix typos and reword on some texts 2016-04-09 22:45:13 +02:00
Frank Fesevur 749c9a5293 Add all missing texts and translate them.
As mentioned in #30 some text where still missing. This adds
all those texts and adds the texts that were added by #26 as well.
2016-04-07 21:43:05 +02:00
Samuli Seppänen cc1b676524 Merge pull request #26 from selvanair/iservice-restrictions
handle iservice policy restrictions
2016-04-04 10:42:57 +03:00
Selva Nair 1df1b62f4b Merge pull request #30 from ffes/nl-2016-03
Improve many Dutch translations
2016-03-22 23:25:12 -04:00
aixxe 2f1892fb8e Added 32x32 versions of each icon. 2016-03-22 16:30:33 +00:00
aixxe 177b5fc5dd Add Windows 8 styled system tray icons. 2016-03-22 12:08:35 +00:00
Leonardo Basilio bdb0350398 Improving PT translation 2016-03-17 13:14:55 -03:00
Frank Fesevur e4126de781 Improve many Dutch translations 2016-03-16 14:56:30 +01:00
Selva Nair 43d0ef3a5a Handle interactive service policy restrictions
When a connection is attempted using a config in a location
that would fail, offer an option to add the user to the "OpenVPN
Administrators" group. This is done using shell-execute which will
show a UAC prompt for elevation. If it fails (due to user chooses
NO or the UAC dialog fails) the connection is not started.

v2 Changes
 - Rebase to master
 - Automaticlaly add the admin group if it doesn't exist
 - Allow unicode strings in debug output
 - Use domain\username to identify user
 - Fix the PrintDebug macro

Minor changes based on user feedback
 - Bring the window back to foreground after UAC prompt completion
 - Show a message if another connection is tried during authorization
 - Do not add user to ovpn_admin_group if it is same as the built-in admin group

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-03-13 20:23:20 -04:00
Samuli Seppänen f1ce93e5d5 Merge pull request #18 from selvanair/user-config-dir
Support user and global config directories
2016-03-08 11:22:29 +02:00
Selva Nair 77538dd0d0 Support user and global config directories
- Set default config directory (config_dir) to %UserProfile%\OpenVPN\config
  (saved and read back from HKCU\Software\OpenVPN-GUI\config_dir)

- Add a global_config_dir variable read from HKLM\Software\OpenVPN\config_dir
  or set to OpenVPN-install-path\config

- Scan both directories and their sub directories for connection profiles.
  In case of name conflicts config_dir gets priority over global_config_dir

- Eliminate multiple warnings of duplicate configs

Fixed on review (Thanks to leobasilio@gmail.com)

- Fix wrongly used o.config_dir in 2 locations
- Unrelated: Added missing  CheckIServiceStatus to service.h

Signed-off-by: Selva Nair <selva.nair@gmail.com>
2016-03-01 15:50:02 -05:00