How do I import custom gpg.conf entries into ~/.gnupg/gpg.conf?

Asked by Harvey Muller

This question is relative to a Hardy Alpha 6 amd64 installation.

I use a GemPC Twin usb smartcard reader and an Openpgp smartcard. It has worked without a hitch in Gutsy, but seahorse is not enabled by default in Gutsy.

I would prefer to link ~/.gnupg to /media/<usbflashdrive>/.gnupg. But I am unable to do this, because when this operation is performed, seahorse-agent seems to break pcscd. After performing aforementioned operation, the smartcard reader becomes inaccessible, and the only way I can regain normal operation of the smartcard reader is to perform a reinstall of Hardy. Therefore I am forced to use the import function to bring the keys into seahorse regardless.

So this leaves my custom hidden-encrypt-to and default-recipient entries. I have two of each, per the openpgp subkey howto. The seahorse preferences only allow you to check a box to include yourself as a default recipient.

So the question is, how do I bring in those entries, since I cannot simply just copy my previous gpg.conf into ~/.gnupg without breaking seahorse / smartcard reader?

Thanks in advance. Any requests for clarification or additional information will be fulfilled in a timely fashion.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu seahorse Edit question
Assignee:
No assignee Edit question
Solved by:
Harvey Muller
Solved:
Last query:
Last reply:
Revision history for this message
subliminalfix (na1tr2lp-deactivatedaccount) said :
#1

noob was answered in this fashion sorry no other input

Get:1 http://security.ubuntu.com gutsy-security Release.gpg [191B]
Ign http://security.ubuntu.com gutsy-security/main Translation-en_US
Ign http://security.ubuntu.com gutsy-security/restricted Translation-en_US
Ign http://security.ubuntu.com gutsy-security/universe Translation-en_US
Ign http://security.ubuntu.com gutsy-security/multiverse Translation-en_US
Get:2 http://us.archive.ubuntu.com gutsy Release.gpg [191B]
Ign http://us.archive.ubuntu.com gutsy/main Translation-en_US
Get:3 http://security.ubuntu.com gutsy-security Release [51.2kB]
Ign http://us.archive.ubuntu.com gutsy/restricted Translation-en_US
Ign http://us.archive.ubuntu.com gutsy/universe Translation-en_US
Ign http://us.archive.ubuntu.com gutsy/multiverse Translation-en_US
Get:4 http://us.archive.ubuntu.com gutsy-updates Release.gpg [191B]
Ign http://us.archive.ubuntu.com gutsy-updates/main Translation-en_US
Ign http://us.archive.ubuntu.com gutsy-updates/restricted Translation-en_US
Ign http://us.archive.ubuntu.com gutsy-updates/universe Translation-en_US
Ign http://us.archive.ubuntu.com gutsy-updates/multiverse Translation-en_US
Get:5 http://us.archive.ubuntu.com gutsy-backports Release.gpg [191B]
Ign http://us.archive.ubuntu.com gutsy-backports/main Translation-en_US
Ign http://us.archive.ubuntu.com gutsy-backports/restricted Translation-en_US
Ign http://us.archive.ubuntu.com gutsy-backports/universe Translation-en_US
Ign http://us.archive.ubuntu.com gutsy-backports/multiverse Translation-en_US
Hit http://us.archive.ubuntu.com gutsy Release
Get:6 http://us.archive.ubuntu.com gutsy-updates Release [58.5kB]
Get:7 http://security.ubuntu.com gutsy-security/main Packages [76.0kB]
Hit http://us.archive.ubuntu.com gutsy-backports Release
Hit http://us.archive.ubuntu.com gutsy/main Packages
Hit http://us.archive.ubuntu.com gutsy/restricted Packages
Hit http://us.archive.ubuntu.com gutsy/main Sources
Hit http://us.archive.ubuntu.com gutsy/restricted Sources
Hit http://us.archive.ubuntu.com gutsy/universe Packages
Hit http://us.archive.ubuntu.com gutsy/universe Sources
Hit http://us.archive.ubuntu.com gutsy/multiverse Packages
Hit http://us.archive.ubuntu.com gutsy/multiverse Sources
Get:8 http://security.ubuntu.com gutsy-security/restricted Packages [14B]
Get:9 http://security.ubuntu.com gutsy-security/main Sources [13.9kB]
Get:10 http://security.ubuntu.com gutsy-security/restricted Sources [14B]
Get:11 http://security.ubuntu.com gutsy-security/universe Packages [49.3kB]
Get:12 http://us.archive.ubuntu.com gutsy-updates/main Packages [246kB]
Get:13 http://security.ubuntu.com gutsy-security/universe Sources [6839B]
Get:14 http://security.ubuntu.com gutsy-security/multiverse Packages [2903B]
Get:15 http://security.ubuntu.com gutsy-security/multiverse Sources [833B]
Get:16 http://us.archive.ubuntu.com gutsy-updates/restricted Packages [4263B]
Get:17 http://us.archive.ubuntu.com gutsy-updates/main Sources [68.8kB]
Get:18 http://us.archive.ubuntu.com gutsy-updates/restricted Sources [937B]
Get:19 http://us.archive.ubuntu.com gutsy-updates/universe Packages [72.4kB]
Get:20 http://us.archive.ubuntu.com gutsy-updates/universe Sources [11.5kB]
Get:21 http://us.archive.ubuntu.com gutsy-updates/multiverse Packages [9942B]
Get:22 http://us.archive.ubuntu.com gutsy-updates/multiverse Sources [1883B]
Hit http://us.archive.ubuntu.com gutsy-backports/main Packages
Hit http://us.archive.ubuntu.com gutsy-backports/restricted Packages
Hit http://us.archive.ubuntu.com gutsy-backports/universe Packages
Hit http://us.archive.ubuntu.com gutsy-backports/multiverse Packages
Fetched 676kB in 4s (147kB/s)
Reading package lists... Done
moth@pearl-desktop:~$ apt-get install kernel-package libncurses5-dev fakeroot wget bzip2
E: Could not open lock file /var/lib/dpkg/lock - open (13 Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
moth@pearl-desktop:~$ sudo apt-get install git-core
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libdigest-sha1-perl liberror-perl
Suggested packages:
  git-arch git-cvs git-svn git-email git-daemon-run git-gui gitk gitweb cogito
Recommended packages:
  git-doc patch curl
The following NEW packages will be installed:
  git-core libdigest-sha1-perl liberror-perl
0 upgraded, 3 newly installed, 0 to remove and 2 not upgraded.
Need to get 3671kB of archives.
After unpacking 7827kB of additional disk space will be used.
Do you want to continue [Y/n]? Y
Get:1 http://us.archive.ubuntu.com gutsy/main liberror-perl 0.15-8 [15.5kB]
Get:2 http://us.archive.ubuntu.com gutsy/main libdigest-sha1-perl 2.11-2 [24.7kB]
Get:3 http://us.archive.ubuntu.com gutsy/main git-core 1:1.5.2.5-2build1 [3631kB]
Fetched 3671kB in 9s (375kB/s)
Selecting previously deselected package liberror-perl.
(Reading database ... 131138 files and directories currently installed.)
Unpacking liberror-perl (from .../liberror-perl_0.15-8_all.deb) ...
Selecting previously deselected package libdigest-sha1-perl.
Unpacking libdigest-sha1-perl (from .../libdigest-sha1-perl_2.11-2_i386.deb) ...
Selecting previously deselected package git-core.
Unpacking git-core (from .../git-core_1%3a1.5.2.5-2build1_i386.deb) ...
Setting up liberror-perl (0.15-8) ...
Setting up libdigest-sha1-perl (2.11-2) ...
Setting up git-core (1:1.5.2.5-2build1) ...
moth@pearl-desktop:~$ git clone git://kernel.ubuntu.com/ubuntu/ubuntu-hardy.git ubuntu-hardy
Initialized empty Git repository in /home/moth/ubuntu-hardy/.git/
remote: Counting objects: 651230, done.
remote: Compressing objects: 100% (123715/123715), done.
Indexing 651230 objects...
remote: Total 651230 (delta 530045), reused 646898 (delta 526429)
 100% (651230/651230) done
Resolving 530045 deltas...
 100% (530045/530045) done
Checking 23734 files out...
 100% (23734/23734) done
moth@pearl-desktop:~$
moth@pearl-desktop:~$ git pull
fatal: Not a git repository
moth@pearl-desktop:~$ git fetch -f origin
fatal: Not a git repository
moth@pearl-desktop:~$ git checkout origin
fatal: Not a git repository
moth@pearl-desktop:~$ git branch -f master origin
fatal: Not a git repository
moth@pearl-desktop:~$ git checkout master git fetch -f origin
fatal: Not a git repository
moth@pearl-desktop:~$ git checkout origin
fatal: Not a git repository
moth@pearl-desktop:~$ git branch -f master origin
fatal: Not a git repository
moth@pearl-desktop:~$ git checkout master
fatal: Not a git repository
moth@pearl-desktop:~$ sudo apt-get git fetch -f origin
[sudo] password for moth:
E: Invalid operation git
moth@pearl-desktop:~$ git pull
fatal: Not a git repository
moth@pearl-desktop:~$ git-arch git-cvs git-svn git-email git-daemon-run git-gui gitk gitweb cogito
bash: git-arch: command not found
moth@pearl-desktop:~$ git-doc patch curl
bash: git-doc: command not found
moth@pearl-desktop:~$ git-doc patch curl
bash: git-doc: command not found
moth@pearl-desktop:~$ sudo apt-git-doc patch curl
sudo: apt-git-doc: command not found
moth@pearl-desktop:~$ sudo apt-get git-doc patch curl
E: Invalid operation git-doc
moth@pearl-desktop:~$ git log origin..HEAD | awk '/^commit/{print $2}' | tac > local-commits
fatal: Not a git repository
moth@pearl-desktop:~$ git branch new-head origin
fatal: Not a git repository
moth@pearl-desktop:~$ git checkout new-head
 Olivier said on 2008-03-14:

I don't know what you're trying exactly to do, but if you want to upgrade to hardy, you're simply doing some weird things...

git is used by developers to get the sources of programs developed using that revision control system. See http://en.wikipedia.org/wiki/Git_(software) for details.

To update to hardy, open your sources.list :

sudo gedit /etc/apt/sources.list

and replace every "gutsy" with a "hardy"

save and close. Then run in a terminal,

sudo apt-get update

sudo apt-get dist-upgrade

But being new to ubuntu, I am not sure you really want to do that. Hardy may be instable for you, and once installed, you are stuck with it. 2 days ago, an upgrade was pushed to the repos, and made the pc unbootable of those who installed the package (nothing irreversible). Just to tell you that it might not be painless.

Revision history for this message
Harvey Muller (hlmuller) said :
#2

Joel,

Thanks for trying, but you did not either understand the question, nor answer it. Please do not take offense, I should have been more clear in asking it.

Background for the question:
Hardy uses seahorse(-agent) by default, where in Gutsy it was optional. Seahorse-agent appears to "hijack" all of the files in ~/.gnupg. In other words, it wants to control all of them. The problem is I have custom entries in my ~/.gnupg/gpg.conf that I wish to continue to use in Hardy, but there is no clearly documented or identifiable way of doing so.

Question:
How do you import a previously used gpg.conf into ~/.gnupg/gpg.conf which is now controlled by seahorse-agent?

Revision history for this message
subliminalfix (na1tr2lp-deactivatedaccount) said :
#3

sorry for the confusion harvey muller i was simply tring to let you

 know there doesnt appear to be support for

hardy at this time. i am a noob so im just a little confused as to the problem

i dont know why you cant select these setting or can you delete seahorse?

and use the terminal to manually

create your keys like before? i guess this doesnt solve your problem i

 just wanted to respond again beacuse id

like to try hardy and im glad for the heads up on that situation

happy easter

peace =]

perhaps this will give you an option

http://packages.ubuntu.com/hardy/libmail-gnupg-perl

Revision history for this message
subliminalfix (na1tr2lp-deactivatedaccount) said :
#4

debmirror --nosource -m --passive --host=archive.ubuntu.com --root=ubuntu/ --method=ftp --progress --dist=hardy,hardy-security,hardy-updates,hardy-backports, --section=main,restricted,universe,multiverse --arch=i386 ~/UbuntuRepos --ignore-release-gpg

THIS IS A COMMAND LINE FOR GETTING HARDY INSTALLED PLEASE NOTE THE LAST SETTING

im not sure about this but im going to try it now

peace =]

Revision history for this message
Harvey Muller (hlmuller) said :
#5

Joel,

The original question is only relative to hardy, in that seahorse is installed and enabled by default in hardy. I appreciate your attempts to answer, and have come to learn the answer through personal trial and error.

The original issue is that I did not know how to get my personal gpg.conf into use without breaking pcscd. What I learned through trial and error is that to do this, seahorse-agent must first be killed, and then the file can be either modified or replaced:

    $ sudo pkill seahorse
    $ cp <path to custom>/gpg.conf ~/.gnupg/

Then seahorse-agent can be restarted, or reboot.

This however does not solve the pcscd "breakage" as that is a separate issue to be discussed elsewhere.