{"id":21711331,"url":"https://github.com/rignaneseleo/easy-gpg4win","last_synced_at":"2026-01-04T05:44:08.861Z","repository":{"id":132272653,"uuid":"134437920","full_name":"rignaneseleo/Easy-gpg4win","owner":"rignaneseleo","description":"Easy explanation of basic use of gpg4win","archived":false,"fork":false,"pushed_at":"2018-05-27T15:23:39.000Z","size":35,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-25T16:42:34.302Z","etag":null,"topics":["decryption","encryption","gdpr","gnupg","gpg4win","security"],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rignaneseleo.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":"2018-05-22T15:43:28.000Z","updated_at":"2024-10-25T20:40:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"13331a68-e2a6-4ee1-9796-f52da6f99f09","html_url":"https://github.com/rignaneseleo/Easy-gpg4win","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rignaneseleo%2FEasy-gpg4win","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rignaneseleo%2FEasy-gpg4win/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rignaneseleo%2FEasy-gpg4win/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rignaneseleo%2FEasy-gpg4win/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rignaneseleo","download_url":"https://codeload.github.com/rignaneseleo/Easy-gpg4win/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244666585,"owners_count":20490288,"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":["decryption","encryption","gdpr","gnupg","gpg4win","security"],"created_at":"2024-11-25T23:21:33.948Z","updated_at":"2026-01-04T05:44:08.801Z","avatar_url":"https://github.com/rignaneseleo.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Easy-gpg4win\nEasy explanation of basic use of gpg4win and GNUpg: https://www.gpg4win.org/ and https://gnupg.org/\n\n### The dictionary\nPUBLIC KEY = Key that you have to share with everyone is going to send you data.\n\nPRIVATE KEY = Key that you MUST NOT share with anyone. It allows you to decrypt what is crypted with your public key.\n\n### The logic\nEverything crypted with the public key is decryptable ONLY with his corrisponded private key AND VICE VERSA.\n\nWhen you want to send crypted data you need to crypt your file with the recipient's public key.\nThe recipient can decrypt the data with his private key.\n\n### Create your own keys\nYou have first of all generate your public and private keys. \nUse the command:\n\n\tgpg --gen-key\n            \nYou have to insert (without spaces is better) the name of your key [key_name], your email and a passphrase (it's a sort of password that you need to insert everytime you use the private key).\n\n### Show your keys\n      \nIf you created correctly your keys before, they should be shown here.\nYou can see the public keys stored in your pc with:\n            \n\tgpg --list-keys\n                \nYou can see the private keys stored in your pc with:\n            \n\tgpg --list-secret-keys\n               \n### Show your keygrips\n\nYou can see the keygrips codes of all the public and private keys stored in your pc with:\n\n\tgpg --with-keygrip --list-secret-keys\n\t\nYou can see the keygrip and fingerprint code of a specific key stored in your pc with:\n\n\tgpg --fingerprint --fingerprint --with-keygrip [key_name]\n\nYou can check a keygrip with:\n\n\tgpg-connect-agent\n\t\u003e havekey [keygrip]\n\n### Import the recipient's public key\n                \nAs I said before, you need to have the public key of your recipient if you want to send him cryptated files.\nAsk him the file of the key (we'll see how to export the key later) and import it in your pc with:\n\n\tgpg --import [key_file_path]      \n            \n                \n### Export your public key as a file\n                                \nWith the following command, you can create a file contaning your public key to share with everyone is going to send you crypted data:\n\n\tgpg -o [file_output_path] --export [key_name]\n\nTo delete a public key in your pc, you can use:\n\n\tgpg --delete-key [key_name] \n                \n### Export your private and public keys as a file\n\nWith the following command, you can create a file contaning both your private and your public key to put somewhere safe.\nYour passphrase is needed. DO NOT SHARE THIS FILE WITH ANYONE!\n\n\tgpg -o [file_output_path] --export-secret-keys [key_name]\n          \nYou should use his file as backup of your private key. You can restore both private and public key with the same import command I wrote before (that command imports only public key if the file contains only a public key and a private and public keys if it has both of them)\n\nTo delete a public key in your pc, you can use:\n\n\tgpg --delete-secret-key [key_name] \n                               \n## Crypt\nYou will use here only the public key of recipient\n\n\tgpg -o [file_output_path] -r [recipient_key_name] -e [file_input_path]\n                \n## Decrypt\nYou will use this only to decrypt files crypted with your public key. Your secret key is automatically selected (you don't need to write it also if you have more than one of them). You have to manually write the secret key passphrase. \n\n\tgpg -o [file_output_path] -d [file_input_path]\n\t   \n## gpg-agent.conf\ngpg-agent.conf is the file where the settings of the cache are stored.\n\n### Path\nIt is created in your homedir. You can read your homedir with:\n\n\tgpgconf --list-dirs\t\n\nyou can edit it and write inside:\n\n\tverbose\n\tallow-preset-passphrase\n\t\nEverytime the gpg-agent.conf is modificated, you have to reload the agent.\n\n### Start the agent\nYou can use\n\n\tgpg-agent --daemon --verbose --allow-preset-passphrase\n\t\nor\n\n\tgpg-connect-agent /bye\n\t\nIn the first case it reports you all the activities it does.\n\n### Turn off the agent\nTo turn off any agent:\n\t\n\tgpgconf --kill gpg-agent\n\n## Save a passphrase in cache\nEverytime you decode qith your private key, the passphrase is required. If you don't want to type it manually everytime, you can store it in the agent's cache. You need to configure your gpg-agent.conf before (read above).\n\n\tKill other agents:\n\n\t\tgpgconf --kill gpg-agent\n\n\tStart the agent:\n\n\t\tgpg-connect-agent /bye\n\n\tSave the passphrase\n\n\t\tgpg-preset-passphrase --passphrase [passphrase] --preset [private_keygrip]\n\t\nOR\n\n\tKill other agents:\n\n\t\tgpgconf --kill gpg-agent\n\t\t\n\tStart the agent with a presetted passphrase:\n\t\t\n\t\tgpg-connect-agent \"preset_passphrase [private_keygrip] -1 [passphrase_in-HEX]\" /bye\n\n\t(you can use this tool to convert the passphrase in HEX: http://string-functions.com/string-hex.aspx)\n\t\nIMPORTANT: _the passphrase MUST be composed only by letters and numbers (without spaces), otherwise you'll have problems_\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frignaneseleo%2Feasy-gpg4win","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frignaneseleo%2Feasy-gpg4win","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frignaneseleo%2Feasy-gpg4win/lists"}