Skip to content

Commit 1a71917

Browse files
committed
Minor fixes
1 parent 789effd commit 1a71917

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

main/src/main/java/de/blinkt/openvpn/VpnProfile.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,8 +329,8 @@ public void upgradeProfile() {
329329
if (mAllowAppVpnBypass)
330330
mBlockUnusedAddressFamilies = false;
331331
case 8:
332-
if (!TextUtils.isEmpty(mCipher) && !mCipher.equals("AES-256-GCM") && !mCipher.equals("AES-128-GCM")) {
333-
mDataCiphers = "AES-256-GCM:AES-128-GCM:" + mCipher;
332+
if (!TextUtils.isEmpty(mCipher) && !mCipher.equals("AES-256-GCM") && !mCipher.equals("AES-128-GCM") && !mCipher.equals("CHACHA20-POLY1305")) {
333+
mDataCiphers = "AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305:" + mCipher;
334334
}
335335
case 9:
336336
if (!TextUtils.isEmpty(mDataCiphers) &&

main/src/main/java/de/blinkt/openvpn/core/OpenVPNService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -717,7 +717,7 @@ public void onDestroy() {
717717
}
718718

719719
if (mDeviceStateReceiver != null) {
720-
this.unregisterReceiver(mDeviceStateReceiver);
720+
unregisterDeviceStateReceiver();
721721
}
722722
// Just in case unregister for state
723723
VpnStatus.removeStateListener(this);

main/src/main/java/de/blinkt/openvpn/core/VpnStatus.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ public static void flushLog() {
134134
mLogFileHandler.sendEmptyMessage(LogFileHandler.FLUSH_TO_DISK);
135135
}
136136

137-
public static void setConnectedVPNProfile(String uuid) {
137+
public synchronized static void setConnectedVPNProfile(String uuid) {
138138
mLastConnectedVPNUUID = uuid;
139139
for (StateListener sl: stateListener)
140140
sl.setConnectedVPN(uuid);

main/src/main/res/values/strings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@
126126
<string name="no_vpn_support_image">Your image does not support the VPNService API, sorry :(</string>
127127
<string name="encryption">Encryption</string>
128128
<string name="cipher_dialog_title">Enter data encryption methods</string>
129-
<string name="chipher_dialog_message">Enter the data encryption cipher algorithms used by OpenVPN separated by : (--data-ciphers). Leave empty to use the default of AES-256-GCM:AES-128-GCM.</string>
129+
<string name="chipher_dialog_message">Enter the data encryption cipher algorithms used by OpenVPN separated by : (--data-ciphers). Leave empty to use the default of AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305.</string>
130130
<string name="auth_dialog_message">Enter the authentication digest used for OpenVPN. Leave empty to use default digest.</string>
131131
<string name="settings_auth">Authentication/Encryption</string>
132132
<string name="file_explorer_tab">File Explorer</string>

0 commit comments

Comments
 (0)