This is for end-to-end app, where the server is just 'dumb' temporary storage. I'm considering using plain HTTP (no TLS) to transmit ciphertexts due to the following reasons:
- Security of a single encryption algorithm is well studied,
while stacking multiple ones is unknown (e.g.
NaCl()
vs.AES(NaCl()
) - Simplicity (at rest == in transit)
- Increased server load (zero-copy
sendfile(2)
vs. copying to RAM for TLS encrypt).
What risks do I have using a setup like this:
- Two channels:
- HTTPS for authentication/metadata/receive one-time token,
- HTTP to transmit ciphertexts.
- Client uses GET/POST http://example.com/?token=one-time.
Body: ciphertext (chunked in AEAD mode), flexible size (can be large) - Server validates token (to prevent reuse) then streams ciphertext to/from disk.
- Client receives and decrypts ciphertext (to detect modification, truncation, etc.)