How to Set Up and Use GPG for Ubuntu (with Pictures) - wikiHow (2024)

  • Categories
  • Computers and Electronics
  • Software

Download Article

Explore this Article

parts

1Setting up GPG

2Sending other individuals encrypted information with GPG

Other Sections

Related Articles

Author Info

Last Updated: October 25, 2022Tested

Download Article

These easy instructions will explain how to use GPG crypt via e-mail from Ubuntu. It includes setting up the software and sending encrypted information.

Things You Should Know

  • Install a GPG and GUI by typing sudo apt-get install gnupg and sudo apt-get install kgpg into Terminal. Follow any prompting.
  • Generate a set of keys. Choose the expiry time, key size, and an algorithm for your keys. Then, press OK > Generate.
  • Keep your private key private, but share your public key with others so that they can send encrypted information to you.
  • To send files to others, upload their public key to your key ring. Then, go to File > Open editor, type the message you want to send, and click "Encrypt".

Part 1

Part 1 of 2:

Setting up GPG

Download Article

  1. 1

    Install GPG. To do this, run terminal and type in “sudo apt-get install gnupg” and follow through with any prompting you may get.

  2. 2

    Install a GUI for GPG. To install a popular GUI, go to the terminal and type in “sudo apt-get install kgpg”. Follow through with any prompting you may get.

    Advertisem*nt

  3. 3

    An icon for KGPG will be present under Applications → Accessories, to launch KGPG you should click on this icon.

  4. 4

    Generate a set of keys. To do this, click on the keys tab on the drop down bar, and from the drop down menu select Generate Key Pair. A new interface will pop up. The new interface will ask you for details so that it can generate your key pair. It will ask you for your name and e-mail address, for example.

    • For name, put your screen name; you can either leave e-mail blank, put your real e-mail address, or use a fake e-mail address. It should be noted that the name and e-mail address you use will be visible to anyone you send your public key to.
    • It will also ask you for a comment, which you can leave blank if you wish, or you can put a comment in if you have a reason to do so.
  5. 5

    Decide if your key will expire, and if so, when. Usually a key does not need an expiration date, although if you feel the need to put one in, you can do so. After an expiration date passes, your key will no longer function, and you will be required to generate a new pair.

  6. 6

    Select a key size. As a rule of thumb, the larger the key size, the more secure messages encrypted with the key are going to be. Select 4096 as your key size.

  7. 7

    Select an algorithm. The default algorithm, DSA & ElGamal, should be selected.

  8. 8

    After filling out the appropriate fields, click the OK button. You will be taken to a new interface and asked to supply a passphrase. The passphrase should be very long and random, your best bet is to use KeePassX to generate a passphrase.

  9. 9

    After you enter your passphrase twice, click on the generate button. A window will pop up explaining that a new key pair is being generated. During the generation of the key pair, you should move your mouse about randomly in order to create a large amount of entropy, thus making your key pair more secure. Continue to move your mouse until the generating key pair window closes.

  10. 10

    After your key pair has generated, the window will close.

  11. 11

    Note that now your keyring has one set of keys in it (your private key and your public key). You need to send your public key to all those you wish to communicate with, so that they can encrypt information before sending it to you. To do this, right click on the key pair you just generated, and select export public keys. A new window will pop up asking you where you would like to export the public key to. Select clipboard. Your public key will now be stored on your clipboard (meaning it is what will paste when you go to paste something.)

  12. 12

    Send your public key to others via forums, key servers, e-mails, etc. simply by pasting the key where you would like it to appear. Now others can use your public key to send encrypted information to you.

  13. 13

    After someone sends you encrypted information, copy the information to your clipboard. Go to KGPG and select File → Open Editor. A new window will pop up that allows you to input text into it. Paste the encrypted information into this window and select decrypt. You will be prompted for your passphrase. After correctly entering your passphrase, the information will decrypt and you will be able to read it.

  14. Advertisem*nt

Part 2

Part 2 of 2:

Sending other individuals encrypted information with GPG

Download Article

  1. 1

    Upload their key to your keyring. To do this, copy their public key to your clipboard. Now, go to KGPG and go to Keys → Import Keys. A new window will pop up and ask from where you want to import the new key. Select clipboard and then click ok. The persons public key will be added to your keyring.

  2. 2

    Now that you have the public key of the individual you wish to send encrypted information to, go to File → Open editor. A new window will pop up that allows you to input text into it. Type the message you wish to send to the individual in this window, then click on the Encrypt button. A new window will pop up asking which key you want to use to encrypt the information.

  3. 3

    If you have not set the individual's public key to trusted, you will need to click on the options button and put a check mark next to “Allow encryption with untrusted keys”. Now simply click on the key of the person the message is intended for, and select ok. Your message is now encrypted.

    • To send the message to the individual, simply copy and paste the encrypted block of text to your clipboard, and e-mail it to them, or send it to them in a private message, or whatever.
  4. 4

    Sign your encrypted message, so that the individual knows that it is in fact coming from you (or someone who has access to your private key and passphrase...which should be only you). To sign your encrypted message, click the sign/verify button and select your private key. You will be prompted to enter your passphrase, and after correctly entering your passphrase a signature will be attached to your message.

  5. 5

    If you have someone public key, you can verify signed messages they send to you. To do this:

    • Simply paste their signed message into the editor, and click on the sign/verify button. A window will pop up telling you if the signature is valid or not.
    • After you verify the signature, remove the signature from the editor. You will also need to remove one extra “*” at the top and bottom of the message, so that “*****BEGIN PGP MESSAGE*****” is the first line and “*****END PGP MESSAGE*****” is the last line.
    • After doing this, simply click the decrypt key and enter your passphrase after you are prompted to do so.
  6. Advertisem*nt

Expert Q&A

Ask a Question

200 characters left

Include your email address to get a message when this question is answered.

Submit

      Advertisem*nt

      Tips

      Submit a Tip

      All tip submissions are carefully reviewed before being published

      Name

      Please provide your name and last initial

      Submit

      Thanks for submitting a tip for review!

      You Might Also Like

      How toPlay MinesweeperHow toOpen EPUB Files
      Using Rufus to Create Bootable USB Drives: A Step-By-Step GuideHow to Add the Google Play Store to an Amazon Fire TabletHow toMake an Exe FileA Step-by-Step Guide to Compare Two Excel FilesHow toAdd a Password to a RAR FileWhy Is Your Child's Screen Time Not Showing? Troubleshooting Apple Family SharingHow toSave an Animation in BlenderHow toCrack Software by Modifying DLL FilesHow toEdit DLL FilesHow to Change the Hostname on Linux Without RebootingHow toUse Notepad++2 Simple Ways to Create an RSS Feed

      Advertisem*nt

      About This Article

      Tested by:

      wikiHow Technology Team

      wikiHow is a “wiki,” similar to Wikipedia, which means that many of our articles are co-written by multiple authors. To create this article, volunteer authors worked to edit and improve it over time. This article has been viewed 130,698 times.

      How helpful is this?

      Co-authors: 7

      Updated: October 25, 2022

      Views:130,698

      Categories: Software

      • Print
      • Send fan mail to authors

      Thanks to all authors for creating a page that has been read 130,698 times.

      Is this article up to date?

      Advertisem*nt

      How to Set Up and Use GPG for Ubuntu (with Pictures) - wikiHow (2024)
      Top Articles
      Investing 101 for Canadian Beginners - NerdWallet
      Analyst Predicts Big Bitcoin Dip Post-$60K; Decentraland & Quant Alternative Eyes Staggering Gains
      Nullreferenceexception 7 Days To Die
      Faint Citrine Lost Ark
      Www.metaquest/Device Code
      Kentucky Downs Entries Today
      Rainfall Map Oklahoma
      PGA of America leaving Palm Beach Gardens for Frisco, Texas
      World of White Sturgeon Caviar: Origins, Taste & Culinary Uses
      W303 Tarkov
      FAQ: Pressure-Treated Wood
      Accuradio Unblocked
      No Hard Feelings Showtimes Near Cinemark At Harlingen
      Andhrajyothy Sunday Magazine
      Why Is 365 Market Troy Mi On My Bank Statement
      Rugged Gentleman Barber Shop Martinsburg Wv
      2024 INFINITI Q50 Specs, Trims, Dimensions & Prices
      Sulfur - Element information, properties and uses
      Vegas7Games.com
      Adt Residential Sales Representative Salary
      All Breed Database
      LCS Saturday: Both Phillies and Astros one game from World Series
      11 Ways to Sell a Car on Craigslist - wikiHow
      25 Best Things to Do in Palermo, Sicily (Italy)
      104 Presidential Ct Lafayette La 70503
      What we lost when Craigslist shut down its personals section
      2021 Tesla Model 3 Standard Range Pl electric for sale - Portland, OR - craigslist
      Gesichtspflege & Gesichtscreme
      Que Si Que Si Que No Que No Lyrics
      Bratislava | Location, Map, History, Culture, & Facts
      Tributes flow for Soundgarden singer Chris Cornell as cause of death revealed
      Justin Mckenzie Phillip Bryant
      Appraisalport Com Dashboard /# Orders
      Unlock The Secrets Of "Skip The Game" Greensboro North Carolina
      How Much Is Mink V3
      Banana Republic Rewards Login
      Second Chance Apartments, 2nd Chance Apartments Locators for Bad Credit
      Invalleerkracht [Gratis] voorbeelden van sollicitatiebrieven & expert tips
      2023 Nickstory
      Walmart Pharmacy Hours: What Time Does The Pharmacy Open and Close?
      Kutty Movie Net
      Ladyva Is She Married
      Todd Gutner Salary
      Greg Steube Height
      Ts In Baton Rouge
      5103 Liberty Ave, North Bergen, NJ 07047 - MLS 240018284 - Coldwell Banker
      Kushfly Promo Code
      Morbid Ash And Annie Drew
      Ret Paladin Phase 2 Bis Wotlk
      Jovan Pulitzer Telegram
      All Obituaries | Roberts Funeral Home | Logan OH funeral home and cremation
      Latest Posts
      Article information

      Author: Wyatt Volkman LLD

      Last Updated:

      Views: 6117

      Rating: 4.6 / 5 (46 voted)

      Reviews: 85% of readers found this page helpful

      Author information

      Name: Wyatt Volkman LLD

      Birthday: 1992-02-16

      Address: Suite 851 78549 Lubowitz Well, Wardside, TX 98080-8615

      Phone: +67618977178100

      Job: Manufacturing Director

      Hobby: Running, Mountaineering, Inline skating, Writing, Baton twirling, Computer programming, Stone skipping

      Introduction: My name is Wyatt Volkman LLD, I am a handsome, rich, comfortable, lively, zealous, graceful, gifted person who loves writing and wants to share my knowledge and understanding with you.