{"id":50342978,"url":"https://github.com/131/ssh-agent-crypt","last_synced_at":"2026-05-29T18:01:37.823Z","repository":{"id":348451503,"uuid":"1197681586","full_name":"131/ssh-agent-crypt","owner":"131","description":"Encrypt/decrypt data using your ssh-agent","archived":false,"fork":false,"pushed_at":"2026-04-01T09:07:12.000Z","size":8,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-05-04T19:07:33.241Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/131.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-31T19:39:27.000Z","updated_at":"2026-04-01T09:07:15.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/131/ssh-agent-crypt","commit_stats":null,"previous_names":["131/ssh-agent-crypt"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/131/ssh-agent-crypt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/131%2Fssh-agent-crypt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/131%2Fssh-agent-crypt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/131%2Fssh-agent-crypt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/131%2Fssh-agent-crypt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/131","download_url":"https://codeload.github.com/131/ssh-agent-crypt/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/131%2Fssh-agent-crypt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33664259,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-29T02:00:06.066Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-05-29T18:01:37.661Z","updated_at":"2026-05-29T18:01:37.815Z","avatar_url":"https://github.com/131.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ssh-agent-crypt\n\n## ssh-agent is enough\n\nEncrypt and decrypt with the SSH key you already have loaded.\nNo private key export. No extra key file. No sidecar secret store.\n`ssh-agent` is already part of your daily flow. That is enough.\n\n## Install / Quick Round-Trip\n\n```bash\nnpm install -g ssh-agent-crypt\n\necho \"ok\" | ssh-agent-crypt | ssh-agent-crypt -decrypt\nok\n```\n\n## Usage\n\nEncrypt with the first key loaded in your agent:\n\n```bash\ncat secret.txt | ssh-agent-crypt \u003e secret.enc\n```\n\nDecrypt with the same key:\n\n```bash\ncat secret.enc | ssh-agent-crypt -decrypt \u003e secret.txt\n```\n\nPick a specific key from your agent by public key path, comment, SHA256 fingerprint, or MD5 fingerprint:\n\n```bash\nssh-agent-crypt id_ed25519.pub \u003c secret.txt \u003e secret.enc\nssh-agent-crypt user@host \u003c secret.txt \u003e secret.enc\nssh-agent-crypt SHA256:abc123... \u003c secret.txt \u003e secret.enc\nssh-agent-crypt MD5:aa:bb:cc:dd:... \u003c secret.txt \u003e secret.enc\n```\n\nYou can also use a direct private key file, with no need for an agent running.\nSupported key algorithms still apply.\n\n```bash\nssh-agent-crypt ~/.ssh/id_ed25519 \u003c secret.txt \u003e secret.enc\n```\n\n## What It Does\n\n`ssh-agent-crypt` asks `ssh-agent` to sign a random salt through `ssh-keygen -Y sign`, derives two subkeys from that signature material, then uses:\n\n- `AES-256-CBC` for encryption\n- `HMAC-SHA256` for authentication\n\nThe output is one line:\n\n```text\nssh-agent-crypt:v1:\u003csalt_b64\u003e.\u003civ_hex\u003e.\u003cciphertext_b64\u003e.\u003cmac_hex\u003e\n```\n\n## Supported Key Algorithms\n\n- EdDSA (`ssh-ed25519`)\n- RSA (`ssh-rsa`, `rsa-sha2-256`, `rsa-sha2-512`)\n\nECDSA is not supported.\n\n## Requirements\n\n- `bash`\n- `openssl`\n- `ssh-agent`, `ssh-add`, `ssh-keygen`\n\n## Tests\n\nThe shipped tool is pure bash. The test harness uses the local `ssh-agent-js` dev dependency.\n\n```bash\nnpm test\n```\n\n## Credits\n\n- [Francois Leurent/131](https://github.com/131)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F131%2Fssh-agent-crypt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F131%2Fssh-agent-crypt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F131%2Fssh-agent-crypt/lists"}