diff options
author | Arne Schwabe <arne@rfc2549.org> | 2022-02-19 16:08:55 +0100 |
---|---|---|
committer | Arne Schwabe <arne@rfc2549.org> | 2022-05-04 19:21:56 +0200 |
commit | fb7a727b9d40b8fcf213528d64e6761e9268b9e1 (patch) | |
tree | d3be85209223316dae54c73318b45f2416717dec /main/src/skeleton | |
parent | 6d364856a35661e7dad414d38dc34c8cbd8b5985 (diff) |
Implement profile encryption using KeyMaster library
Diffstat (limited to 'main/src/skeleton')
-rw-r--r-- | main/src/skeleton/java/de/blinkt/openvpn/core/ProfileEncryption.java | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/main/src/skeleton/java/de/blinkt/openvpn/core/ProfileEncryption.java b/main/src/skeleton/java/de/blinkt/openvpn/core/ProfileEncryption.java new file mode 100644 index 00000000..c526a69f --- /dev/null +++ b/main/src/skeleton/java/de/blinkt/openvpn/core/ProfileEncryption.java @@ -0,0 +1,37 @@ +/* + * Copyright (c) 2012-2022 Arne Schwabe + * Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt + */ + +package de.blinkt.openvpn.core; + +import android.content.Context; + +import java.io.File; +import java.io.FileInputStream; +import java.io.FileOutputStream; +import java.io.IOException; +import java.security.GeneralSecurityException; + +/* Dummy class that supports no encryption */ +class ProfileEncryption { + static void initMasterCryptAlias() + { + + } + + static boolean encryptionEnabled() + { + return false; + } + + static FileInputStream getEncryptedVpInput(Context context, File file) throws GeneralSecurityException, IOException { + throw new GeneralSecurityException("encryption of file not supported in this build"); + } + + static FileOutputStream getEncryptedVpOutput(Context context, File file) throws GeneralSecurityException, IOException { + throw new GeneralSecurityException("encryption of file not supported in this build"); + } + + +} |