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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve trust when installing agent #953

Open
dustinblackman opened this issue Mar 9, 2024 · 1 comment
Open

Improve trust when installing agent #953

dustinblackman opened this issue Mar 9, 2024 · 1 comment
Assignees

Comments

@dustinblackman
Copy link

dustinblackman commented Mar 9, 2024

Is your feature request related to a problem?

Nothing is broken, but it's a problem nonetheless.

Which solution do you suggest?

DevPod is fantastic where it's able to bring up an any environment I define in the place I need it to, I love it! The only addition to my devcontainer is the DevPod agent. At the moment DevPod expects a developer to put trust that the binary from GitHub releases that's downloaded in each new environment is the same as it was a month ago. This is a trust many are happy to provide, but in circles where security is more strict, having DevPod download an executable on each new run is a hard sell.

HackerNews has articles on supply chain attacks almost weekly now, it can happen to any of us where our creds get leaked, someone sees a popular repo like this one, and swaps out a binary in releases with something malicious.

Which alternative solutions exist?

It's great that the AGENT_URL parameter is available, this makes it easier to be sure the agent remains the same on each run if I self host. Getting friends and colleagues of all levels to remember setting it is difficult though.

What would be a great middle ground is if the DevPod client that's spinning up an environment validates a checksum of the agent on each download. Looking at how DevPod is compiled I can imagine this may be a tad difficult. The agent and the CLI are bundled in a single binary, so computing and embedding a checksum isn't possible (to my knowledge, at least). However if you guys were open to providing a stripped down additional binary of just the agent, you could compute checksum and bundle it in the CLI and Desktop app. With this if the unfortunate scenario happens where a binary is swapped out post release, red flags start going off within the app before executing.

A secondary option; as SSH access is available it's could be an option to upload the binary from the users machine to the remote environment, and that saves the effort of having to do checksums. The binary size would be greater, but it may be a worthwhile trade off.

Happy to discuss further if you find either of these interesting. Thanks!

@dustinblackman dustinblackman changed the title Add checksum validation when downloading agent, or upload agent from local Improve trust when installing agent Mar 9, 2024
@pascalbreuninger
Copy link
Member

Hey @dustinblackman, thanks for raising the concern and the detailed elaboration. We agree that we should validate the checksum against the latest release before we download the agent on any machine - we'll introduce a new pipeline to do this soon-ish (not exactly sure when but in the next couple of weeks).

Why we download from the releases page sometimes is because of potentially different architectures of DevPod on your host machine and your target machine

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

No branches or pull requests

3 participants