{"id":13722288,"url":"https://github.com/Foxboron/age-plugin-tpm","last_synced_at":"2025-05-07T14:31:25.499Z","repository":{"id":156787422,"uuid":"629188876","full_name":"Foxboron/age-plugin-tpm","owner":"Foxboron","description":":key: TPM 2.0 plugin for age","archived":false,"fork":false,"pushed_at":"2025-02-16T15:09:48.000Z","size":183,"stargazers_count":92,"open_issues_count":5,"forks_count":9,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-17T18:17:05.675Z","etag":null,"topics":["age","go-tpm","golang","security","tpm","tpm2"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Foxboron.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2023-04-17T20:09:04.000Z","updated_at":"2025-04-17T16:01:29.000Z","dependencies_parsed_at":"2024-01-15T20:47:17.293Z","dependency_job_id":"bdf73249-01b3-4603-ba69-3da23b7630b4","html_url":"https://github.com/Foxboron/age-plugin-tpm","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foxboron%2Fage-plugin-tpm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foxboron%2Fage-plugin-tpm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foxboron%2Fage-plugin-tpm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foxboron%2Fage-plugin-tpm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Foxboron","download_url":"https://codeload.github.com/Foxboron/age-plugin-tpm/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252895646,"owners_count":21821198,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["age","go-tpm","golang","security","tpm","tpm2"],"created_at":"2024-08-03T01:01:26.897Z","updated_at":"2025-05-07T14:31:25.491Z","avatar_url":"https://github.com/Foxboron.png","language":"Go","funding_links":[],"categories":["Go","Plugins"],"sub_categories":[],"readme":"TPM plugin for age clients\n==========================\n\n`age-plugin-tpm` is a plugin for [age](https://age-encryption.org/v1) clients\nlike [`age`](https://age-encryption.org) and [`rage`](https://str4d.xyz/rage),\nwhich enables files to be encrypted to age identities sealed by the TPM.\n\n# Features\n\n* Keys created on the TPM, sealed outside of it\n* PIN support\n* TPM session encryption\n\n# Experimental\n\nThe identity format and technical details might change between iterations.\nConsider this plugin experimental.\n\nInstead of utilizing the TPM directly, you can use `--swtpm` or `export\nAGE_TPM_SWTPM=1` to create a identity backed by\n[swtpm](https://github.com/stefanberger/swtpm) which will be stored under\n`/var/tmp/age-plugin-tpm`.\n\nNote that `swtpm` provides no security properties and should only be used for\ntesting.\n\n## Installation\n\nThe simplest way of installing this plugin is by running the follow go command.\n\n`go install github.com/foxboron/age-plugin-tpm/cmd/age-plugin-tpm@latest`\n\nAlternatively download the [pre-built binaries](https://github.com/foxboron/age-plugin-tpm/releases).\n\n# Usage\n\n```bash\n# Create identity\n$ age-plugin-tpm --generate -o age-identity.txt\n$ age-plugin-tpm -y age-identity.txt \u003e age-recipient.txt\n\n# Encrypt / Decrypt something\n$ echo 'Hack The Planet!' | age -R age-recipient.txt -o test-decrypt.txt\n$ age --decrypt -i age-identity.txt -o - test-decrypt.txt\nHack The Planet!\n```\n\nYou can add `--pin` when calling `--generate` to require a PIN when encrypting or decrypting.\n\n### When used non-interactively\n\nIf you want to use a `--pin` non-interactively, you can use the `AGE_TPM_PIN` environment variable.\nPlease be aware that environment variables are not secure, and can be read from `/proc/$PID/environ`.\n\n```bash\n# Create identity\n$ AGE_TPM_PIN=1234 age-plugin-tpm --generate --pin -o age-identity.txt\n$ age-plugin-tpm -y age-identity.txt \u003e age-recipient.txt\n\n# Encrypt / Decrypt something\n$ echo 'Hack The Planet!' | age -R age-recipient.txt -o test-decrypt.txt\n$ AGE_TPM_PIN=1234 age --decrypt -i age-identity.txt -o - test-decrypt.txt\nHack The Planet!\n```\n\n## Commands\n\nAn age identity can be created with:\n\n```\n$ age-plugin-tpm --generate -o age-identity.txt\n# Created: 2023-07-05 22:38:36.362043774 +0200 CEST m=+0.110154231\n# Recipient: age1tpm1qg86fn5esp30u9h6jy6zvu9gcsvnac09vn8jzjxt8s3qtlcv5h2x287wm36\n\nAGE-PLUGIN-TPM-1QYQSQLSQYZJN56KJ4WHGP676AW248W7Z3KE7JRP8HWGGTW98CX955U9NCV4G2QQS828ZMZNQLLC57QU037ELMLA0RR56SM35HLJAFHKY0EH7J62SYJLX3YFULEE7AQJR0DJX7D33HRKWRYHNXFN0TRS45MKUHZGRU3K3EPRUSGSWWV07K2PKTFF79YVACDZSVEKAYY4GEAM6DRNQQPTQQGCQPVQQYQRJQQQQQYQQZQQQXQQSQQSQLFXWNXQX9LSKL2GNGFNS4RZPJ0HPU4JV7G2GEV7ZYP0LPJJAGEGQYQE8GSEC0GWWDVKAFT04QTJWCU3T2KYVXGER35FVMHEY0ZDGEHC4C0EXJ8Y\n```\n\nTo display the recipient of a given identity:\n\n```\n$ age-plugin-tpm -y age-identity.txt\nage1tpm1qg86fn5esp30u9h6jy6zvu9gcsvnac09vn8jzjxt8s3qtlcv5h2x287wm36\n```\n\n## License\n\nLicensed under the MIT license. See [LICENSE](LICENSE) or http://opensource.org/licenses/MIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FFoxboron%2Fage-plugin-tpm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FFoxboron%2Fage-plugin-tpm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FFoxboron%2Fage-plugin-tpm/lists"}