Skip to content

feat: add proton drive upload support#11

Open
blefnk wants to merge 1 commit intomajor0:mainfrom
reliverse:main
Open

feat: add proton drive upload support#11
blefnk wants to merge 1 commit intomajor0:mainfrom
reliverse:main

Conversation

@blefnk
Copy link
Copy Markdown

@blefnk blefnk commented Mar 30, 2026

Hi, Mark! Thanks for building and maintaining this CLI!

And on a personal note, thank you for the work you do outside of tech as well! 🙏


I put this together because I needed a working way to upload a file to Proton Drive from this CLI, and the current codebase was already very close.

This PR adds a basic drive upload command and fixes a few things that were getting in the way of real uploads with Proton's current API behavior.

What's included

  • adds protondrive drive upload
  • fixes address/keyring lookup during upload setup
  • updates the app version string so upload requests are accepted
  • vendors a patched go-proton-api under third_party/go-proton-api
  • adds compatibility fixes for the current Proton Drive upload flow:
    • revision verification endpoint
    • block verifier token support
    • more reliable block upload request body handling
    • retry compatibility for transient upload failures

Notes

A couple of the dependency changes are bigger than I'd normally like, but I went with the most practical route to get a working upload path first.

I tested this against a real Proton account and was able to:

  • log in
  • list account / volume / share info
  • upload a .gpg file to Proton Drive
  • verify that the file appeared in the web UI

Known rough edges

  • session storage is still file-backed and still has the existing security warning
  • this only adds a basic upload flow (root of the selected share / primary share), not a full folder management workflow
  • there may still be room to clean up how the vendored API patch is organized

If you'd prefer, I can split this into smaller PRs afterward (for example: CLI command vs API compatibility patch).

@major0
Copy link
Copy Markdown
Owner

major0 commented Mar 30, 2026

I got a little side-tracked implementing a true POSIX/GNU option/flag parser (https://github.com/major0/optargs.git) so that I could have a real proton drive ls <options> interface. Once I was done there I was going to fully pivot back over to the proton-cli as my primary project and continue getting this fully on-online, along side a ProtonFS that can be mounted; I am nervous about some of the security implications of integrating w/ rclone. I am hoping to implement something closer to kbfs in functionality/performance.

Just a heads up, I wont have time to review this until this evening.

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.

2 participants