Ok, if you can run an application after the zip has been created, there’s hope.
Here’s one simple way you can encrypted/decrypt a file:
Public Sub EncryptFile(FromFile As FolderItem, ToFile As FolderItem)
dim b1,b2 As BinaryStream
dim s As String
try
if FromFile<>nil and FromFile.Exists and ToFile<>nil then
b1=BinaryStream.Open(FromFile) 'Load the input file
b2=BinaryStream.Create(ToFile,True) 'Create the output file
s=b1.Read(b1.Length) 'Read the whole input file
s=EncodeBase64(s) 'Simple encoding
b2.Write s 'Write to the other file
end if
Catch e
MessageBox "An error occurred: "+str(e.ErrorNumber)
end try
End Sub
Just note: if your zip file is big (huge), the code may take some time, but probably not.
So, you’d make the zip file, use the function above with the zip file as input and your own file as output.
To decrypt the file on the other end, use the same method with just replacing “EncodeBase64” by “DecodeBase64”.
This is still an attempt: the code above was written from scratch just now and we have to validate it as a working solution (I expect it is).