[Pkg-privacy-commits] [parcimonie] 08/25: Allow key updates to existing keys, but do not allow any new keys to be imported (Closes: Debian#819305).

Intrigeri intrigeri at moszumanska.debian.org
Sun May 29 11:33:08 UTC 2016


This is an automated email from the git hooks/post-receive script.

intrigeri pushed a commit to branch master
in repository parcimonie.

commit d5dc213fd6026b64dad4d0508799917e5d313afb
Author: intrigeri <intrigeri at boum.org>
Date:   Tue Mar 29 15:24:59 2016 +0000

    Allow key updates to existing keys, but do not allow any new keys to be imported (Closes: Debian#819305).
---
 lib/App/Parcimonie/Daemon.pm | 17 +++++++++++++++--
 1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/lib/App/Parcimonie/Daemon.pm b/lib/App/Parcimonie/Daemon.pm
index e3a4e45..9aaa338 100644
--- a/lib/App/Parcimonie/Daemon.pm
+++ b/lib/App/Parcimonie/Daemon.pm
@@ -67,6 +67,14 @@ option 'gnupg_extra_args' => (
     format        => 's@',
 );
 
+has 'gnupg_builtin_args' => (
+    isa           => 'ArrayRef[Str]',
+    is            => 'ro',
+    default       => sub { [
+        '--import-options' => 'merge-only',
+    ] },
+);
+
 has 'gnupg_options' => (
     isa           => 'HashRef',
     is            => 'ro',
@@ -257,9 +265,14 @@ sub fatal {
 
 sub _build_gnupg_options {
     my $self = shift;
-    my %opts;
+    my %opts = (
+        extra_args => [],
+    );
     $opts{homedir}    = $self->gnupg_homedir    if defined $self->gnupg_homedir;
-    $opts{extra_args} = $self->gnupg_extra_args if defined $self->gnupg_extra_args;
+    push @{$opts{extra_args}}, @{$self->gnupg_builtin_args}
+        if defined $self->gnupg_builtin_args;
+    push @{$opts{extra_args}}, @{$self->gnupg_extra_args}
+        if defined $self->gnupg_extra_args;
     return \%opts;
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/parcimonie.git



More information about the Pkg-privacy-commits mailing list