Skip to content

Conversation

@marcin-cebo
Copy link
Contributor

@marcin-cebo marcin-cebo commented Nov 17, 2025

fix: Fixed upload/download encrypted file API.

Fixed upload/download encrypted file API. When file is encrypted application/octet-stream data format is enforced regardless of original file type (image/jpeg, video/mp4, text/plain) or server's suggested Content-Type from generateUploadUrl.

fix: Removed redundant buffering when parsing encrypted data.

When file is encrypted "application/octet-stream" data format is enforced regardless of original file type (image/jpeg, video/mp4, text/plain) or server's suggested Content-Type from generateUploadUrl

@Test
fun uploadListDownloadDeleteWithCipherUseFileWithLegacyCryptoModule(){
fun uploadListDownloadDeleteWithCipherUseFileWithLegacyCryptoModule() {
Copy link
Contributor

@jguz-pubnub jguz-pubnub Nov 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this test case cover? Have you considered other names for it?

uploadListDownloadDeleteWithCipherUseFileWithLegacyCryptoModule is quite long, and the same applies to uploadListDownloadDeleteWithCipherUseFileWithAesCbcCryptoModule below

EDIT: I see it uploads an encrypted File, then downloads a File from the remote server and compares their contents. If so, what do you think of the following, or something similar?

aesCbcEncryptedFileTransfer
legacyEncryptedFileTransfer

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These tests: upload, then list, then delete file using aesCbc/legacy cryptoModule.
I like proposed names. I will use them.

@marcin-cebo
Copy link
Contributor Author

@pubnub-release-bot release kotlin as v12.0.1

@marcin-cebo marcin-cebo merged commit 415c246 into master Nov 19, 2025
9 of 13 checks passed
@marcin-cebo marcin-cebo deleted the mc/downloadEncryptedFile_fix branch November 19, 2025 12:03
@pubnub-release-bot
Copy link
Contributor

🚀 Release successfully completed 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants