Hi
as subject i get two different result if i call form more time the some function for encrypt my string
Is this correct?
I expected to always have the same byte array
If this is the correct behavior, how can I always get the same byte array?
thank's
the example is following
as subject i get two different result if i call form more time the some function for encrypt my string
Is this correct?
I expected to always have the same byte array
If this is the correct behavior, how can I always get the same byte array?
thank's
the example is following
EXAMPLE:
Dim EncryptedData() As Byte
Dim c As B4XCipher
Dim myString, myPassword As String
Log("Start test ==============")
myString = "abc"
myPassword = "1234"
Log("1° test >>")
EncryptedData = c.Encrypt(myString.GetBytes("utf8"), myPassword)
Log("First Time byte Length: " & EncryptedData.Length)
For N = 0 To EncryptedData.Length-1
Log(EncryptedData(N))
Next
EncryptedData = c.Encrypt(myString.GetBytes("utf8"), myPassword) ' note the some string and password
Log("Second Time byte Length: " & EncryptedData.Length)
For N = 0 To EncryptedData.Length-1
Log(EncryptedData(N))
Next
EncryptedData = c.Encrypt(myString.GetBytes("utf8"), myPassword) ' note the some string and password
Log("third Time byte Length: " & EncryptedData.Length)
For N = 0 To EncryptedData.Length-1
Log(EncryptedData(N))
Next