#format creole = Get public keys **work in progress** //This tutorial is for Gpg4win 4.0.3. For new versions this process may differ.// === Contents * [[Gpg4win/Tutorials/RetrievePublicKeys#Introduction|Introduction]] * [[Gpg4win/Tutorials/RetrievePublicKeys#keyserver|Download a public key from an external source (WKD server/ keyserver)]] * [[Gpg4win/Tutorials/RetrievePublicKeys#file_import|Import a public key as a file]] <> ===Introduction You created your own keys and are able to sign files and messages and now you want to encrypt to another person. But wait. Isn't something missing? Yes, to encrypt a file to someone you need their public key. The next question is: How can you get that key? And how do you know that the pubkey you've gotten belong to the person that you want to communicat with. \\ There are several ways and here we explain two of them: * Download the public key from an external source (WKD server/ keyserver) * Import a public key as a file <> === Download a public key from an external source (WKD server/ keyserver) **todo: link to article about which keyserver to use and limitation of the new keyserver network** * Click on **Lookup on Server...** \\\\ {{lookup_on_server.png}} \\\\\\ * Enter the email address of the person you want to encrypt something to \\\\ {{enter_email_address.png}} \\\\\\ * Click on **Search** \\\\ {{search_key.png}} \\\\\\ * After some time a public key appears if the search was successful. Select the key you want to import. \\\\ {{select_email_address.png}} \\\\\\ * Click on **Import** to import the new public key \\\\ {{import_key.png}} \\\\\\ * A message appears where you can decide if you want to check the fingerprint of the public key. This means you check if the key really belongs to the person you want to encrypt something to. \\ You have two options: # Don't certify the new public key. Then click on **No** # Start the certifying process. Then follow the next section of this tutorial (//Certifying process//) \\\\ {{dont_certify.png}} \\\\\\ ==== Certifying process As written above when you certify a public key you claim that that key really belongs to the person you think this key belongs. This is important if you take encryption serious and want to be sure that you don't use any faked keys. * To start the process click on **Yes** \\\\ {{certify.png}} \\\\\\ * If you have more than one key pair select the private key you want to use to certify the new public key. \\\\ {{key_for_certification.png}} \\\\\\ * If you set a password for your key you have to enter your password/passphrase \\\\ {{enter_password.png}} \\\\\\ * Confirm the password with a click on **OK** \\\\ {{confirm_password.png}} \\\\\\ * Confirm with a click on **OK** \\\\ {{certification_complete.png}} \\\\\\ **Now the certifying process is complete and you can use the new public key.** <> === Import a public key as a file To import a public key which you got as a file (e.g. via email) there are two ways which are explained in the following sections. ==== Double-click on the file * This is the easiest way. If you have a file whose icon looks like the one on the next screenshot you can just **double-click** on that file. \\\\ {{asc_file.png}} \\\\\\ * Kleopatra opens the file and imports the public key right away. Then it shows a small window where you have to click on **OK**. \\\\ {{confirm_import.png}} \\\\\\ ==== Import the file from Kleopatra Another way to import a key starts in Kleopatra. * Click on **Import...** \\\\ {{import.png}} \\\\\\ * The file explorer will be opened. Here you have to navigate to the file with the public key and click on it. \\\\ {{select_key.png}} \\\\\\ * Click on **Open** \\\\ {{open_key.png}} \\\\\\ * Click on **OK** to close the confirmation window. \\\\ {{confirm_import.png}} \\\\\\ **Now you have imported the new public key and can use it.**