Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encrypted files at rest #1697

Open
liquid-metal opened this issue Dec 7, 2023 · 2 comments
Open

Encrypted files at rest #1697

liquid-metal opened this issue Dec 7, 2023 · 2 comments

Comments

@liquid-metal
Copy link

馃殌 Feature Request

When a file is pushed, it should be possible to select (or force by configuration) that the file is stored encrypted in whatever storage is configured.

馃攬 Motivation

Users might expect files in password pusher to be shared securely (not only the access), so in my opinion it is logical to share files with sensitive content. Especially when using external storage, it might be desirable to have the files on the storage encrypted. This is an improvement to security from the moment where the storage is on another host than the application itself. This might further be improved by deriving the encryption key from a lockdown passphrase.

Incorrectly configured S3 leads to countless data leaks; this might even become worse when using some kind of self hosted storage which might not be as well-integrated into an IAM as a cloud-hosted offer.

馃洶 Alternatives

Require the user to encrypt files? Sounds not so viable to me.

馃搸 Additional context

I am aware of the optimization mentioned in the config document that the browser can send files to an external storage directly. I can imagine multiple ways to deal with that

  • remove it - but this will put an avoidable strain on the application server
  • conditionally uploading the file to storage or to the application itself, depending whether it needs to be encrypted or not
  • always encrypt in the browser. Although, this would have to be approached with extreme care, as this would either require sending secret key material from the server to the browser, and/or relying on good mechanisms and user passphrases for local encryption. Though not as big as a concern, this might impact lower-end clients, although I suggest that modern smartphones will be able to handle well-written JS encryption, and not many people are going to try sharing a file from an ancient computer or a washing machine.
@pglombardo
Copy link
Owner

Great feature request - I agree this would be ideal although not the easiest thing to implement so it will take some careful thought and planning. Having the encryption key potentially tied to the lockdown passphrase is a good idea too. I'll give it all some thought.

@pglombardo
Copy link
Owner

Password Pusher uses lockbox for data encryption and it supports ActiveStorage encryption (file uploads): https://github.com/ankane/lockbox?tab=readme-ov-file#active-storage

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

No branches or pull requests

2 participants