S Scantech Well-Known Member Licensed User Longtime User May 3, 2019 #1 I can't figure this out. found example and not working. Code: Copy Sub DecryptText(EncryptedData() As Byte, password As String) As String Dim c As B4XCipher Dim b() As Byte = c.Decrypt(EncryptedData, password) Return BytesToString(b, 0, b.Length, "utf8") End Sub B4J Version: 7.31 Java Version: 8 Parsing code. (0.00s) Building folders structure. (0.01s) Compiling code. (0.01s) Compiling layouts code. (0.00s) Organizing libraries. (0.00s) Compiling generated Java code. Error B4J line: 74 Dim b() As Byte = c.Decrypt(EncryptedData, passwo javac 1.8.0_101 src\b4j\example\main.java:156: error: cannot access DataLengthException _b = _c.Decrypt(_encrypteddata,_password); ^ class file for org.bouncycastle.crypto.DataLengthException not found 1 error Click to expand...
I can't figure this out. found example and not working. Code: Copy Sub DecryptText(EncryptedData() As Byte, password As String) As String Dim c As B4XCipher Dim b() As Byte = c.Decrypt(EncryptedData, password) Return BytesToString(b, 0, b.Length, "utf8") End Sub B4J Version: 7.31 Java Version: 8 Parsing code. (0.00s) Building folders structure. (0.01s) Compiling code. (0.01s) Compiling layouts code. (0.00s) Organizing libraries. (0.00s) Compiling generated Java code. Error B4J line: 74 Dim b() As Byte = c.Decrypt(EncryptedData, passwo javac 1.8.0_101 src\b4j\example\main.java:156: error: cannot access DataLengthException _b = _c.Decrypt(_encrypteddata,_password); ^ class file for org.bouncycastle.crypto.DataLengthException not found 1 error Click to expand...
OliverA Expert Licensed User Longtime User May 3, 2019 #2 You need an additional library. See first post: https://www.b4x.com/android/forum/threads/jb4xencryption.48178/#content Upvote 0
You need an additional library. See first post: https://www.b4x.com/android/forum/threads/jb4xencryption.48178/#content