Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: open SUSE 11.0, Fedora 7 and Mandriva 2007
Posts: 1,662
Rep:
Copying the gpg folder on to a floppy drive
When you install the GnuPG software, it will create the following folder on the system. [ /.gnupg ].
I must copy it on to a USB or a floppy disk to preserve the data.
All the details like my public key, private key will be on that folder.
I found the following from a website.
It teaches me how to copy everything on that '' /.gnupg '' folder to a floppy disk. However, I can't fathom out the description.
This '--homdir ' is on any Linux system is 'gnupg'. So I will write the word 'gnupg' instead of 'homdir'.
How do I use this '' --homedir /my/path/ '' this option?
Do I have to write something to the path?
Are you able to tell me how to do this?
I don't need any help on key making. The following teaches me how to copy on to a floppy. I can't fathom out their description.
Please read the following description carefully.
------------------------------------------------------------------------------------------------------------------------------------------
4.18) How do I put my keyring in a different directory?
GnuPG keeps several files in a special homedir directory.
These include the options file, pubring.gpg, secring.gpg, trustdb.gpg, and others.
GnuPG will always create and use these files. On unices, the homedir is usually ~/.gnupg; on Windows "C:\gnupg\".
If you want to put your keyrings somewhere else, use the option:
--homedir /my/path/
to make GnuPG create all its files in that directory. Your keyring will be "/my/path/pubring.gpg".
This way you can store your secrets on a floppy disk.
Don't use "--keyring" as its purpose is to specify additional keyring files.
When I've needed to move my gnupg keys to a new location, I've always just exported the public and private keys to a USB drive. Then I import them at the new location. (Oh, and then I have to mess with the trust level.)
So it seems likely that the documented method you're describing is better.
I would read that documentation to mean that you need to do something like
Code:
gpg --homedir /mnt/some-dir
where 'some-dir' is the location you've mounted your floppy or usb drive to.
Distribution: open SUSE 11.0, Fedora 7 and Mandriva 2007
Posts: 1,662
Original Poster
Rep:
Thanks anomie
So it is nice to know that you too use the gpg.
I can test several times to see how it works.
As you know the system will create the folder ( /.gnupg )
Is it possible to erase it? As a root user, you could erase your folders and files. I suspect this folder is not erasable.
When you want to make some trials to see how it works, you should be able to install and erase.
Is this folder possible to erase?
--------------------------------------------------------------------------------------------------------------------------------
gpg --homedir /mnt/some-dir
The above command you suggested won't copy the files to your USB memory. Let us say I decided to reinstall the FC5 again. I must be able to install my 'gpg' without any hassle.
You can use the command 'gpg --gen-key ' and creates so many keys.
How do I insert the keys, ring, IDs, etc if I reinstall FC5?
It is not a question of making a pair of keys.
You should be able to use the keys for many years.
It is common for us to install new version of Linux from time to time.
Distribution: open SUSE 11.0, Fedora 7 and Mandriva 2007
Posts: 1,662
Original Poster
Rep:
Thanks anomie
Have you ever changed computers and transferred the gpg keys?
I mean you may have erased the existing Linux version and installed a new version.
Then it should work smoothly to transfer the keys.
As you mentioned exporting, importing keys and transferring to a USB memory works fine.
When you install again gpg on your computer, it should be possible to use the same old keys.
You can make keys using the same old passphrase. But the keys will not be the same.
You might tell me that it is possible to revoke the old keys and publish new keys on public key servers.
It is not a neat solution, as far as I am concerned.
1. You can have your old keys on a USB.
2. You can have your old ID on a USB.
3. You can have same old passphrase on a USB.
[root@c83-250-99-43 gnupg]# find / -name gnupg
find: WARNING: Hard link count is wrong for /selinux: this may be a bug in your filesystem driver. Automatically turning on find's -noleaf option. Earlier results may have failed to include directories that should have been searched.
/usr/lib64/gnupg
/usr/share/gnupg
[root@c83-250-99-43 gnupg]#
-----------------------------------------------------------------------------------------------------------------------
[root@c83-250-99-43 gnupg]# cd /usr/lib64/gnupg
[root@c83-250-99-43 gnupg]# ls
gpgkeys_finger
gpgkeys_hkp
gpgkeys_http
gpgkeys_ldap
[root@c83-250-99-43 gnupg]#
Distribution: open SUSE 11.0, Fedora 7 and Mandriva 2007
Posts: 1,662
Original Poster
Rep:
anomie
I made a mistake.
I am talking about 'gpg'.
When you write, you easily mixed up those words.
I have PGP on the windows side of this computer.
I never use windows. I like open source.
When the computer starts, I could go to the windows side if I want to work with windows XP.
PGP for windows is an expensive product. It will cost about 1500.00 US dollars. I have the latest version of PGP. It is a cracked program.
I would like to get your public key. Would you like to give it to me?
I want to know your name or email address which you have given to the 'gpg' program.
Very soon I will create keys. Your comments gave me some impetus to make a new pair of keys.
I have an old public key. You could download it. I didn't make any revocation certificate. I didn't make any backup of or copied the keys to a USB memory. I made a big blunder this was a couple of months ago. I was forced to reinstall the FC5 and lost everything. So it is a dead key. I can't remove it from the public key servers. This time I will do a neat job.
Are you in the following list?
-----------------------------------------------------------------------------------------------------------------------------------
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.