You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While ZipArchive allows decryption of AES passwords from bytes, ZipWriter with FileOptions only allows for &str password. This behavior is inconsistent, and incomplete. Zip files can be protected using bytes, not only readable (&str) password.
The current implementation already allows for encryption using bytes, we only need to change the interface for FileOptions.
The text was updated successfully, but these errors were encountered:
The current implementation also adds an unnecessary unsafe to the code through the use of unsafe std::str::from_utf8_unchecked to convert from arbitrary bytes to &str. Not sure if there's any other way around, but support for &[u8] or AsRef<[u8]> is highly recommended.
While ZipArchive allows decryption of AES passwords from bytes, ZipWriter with FileOptions only allows for
&str
password. This behavior is inconsistent, and incomplete. Zip files can be protected using bytes, not only readable (&str
) password.The current implementation already allows for encryption using bytes, we only need to change the interface for FileOptions.
The text was updated successfully, but these errors were encountered: