luben / zstd-jni

JNI binding for Zstd
Other
809 stars 165 forks source link

How to make an encrypted compression #236

Closed Cyberavater closed 1 year ago

Cyberavater commented 1 year ago

Can I make a password-protected compression of a folder using this library?

Please provide an example if possible.

luben commented 1 year ago

No, this library provides just compression/decompression. If you want to have encryption, you may add additional layer on top of it. I recommend first compress, then encrypt. If you pick hardware accelerated crypto, e.g. AES GCM, you can get quite close to native performance.