From 6965f6fdde9c834b0dff32f406a5eaeba4acb722 Mon Sep 17 00:00:00 2001 From: Daniel Kahn Gillmor Date: Tue, 3 Feb 2009 21:42:06 -0500 Subject: use the environment to determine usage flags (default to certify) --- src/keytrans/pem2openpgp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/keytrans/pem2openpgp b/src/keytrans/pem2openpgp index 1aae4fe..315a2b5 100755 --- a/src/keytrans/pem2openpgp +++ b/src/keytrans/pem2openpgp @@ -361,7 +361,7 @@ if (defined $ENV{PEM2OPENPGP_TIMESTAMP}) { my $flags = 0; if (! defined $ENV{PEM2OPENPGP_USAGE_FLAGS}) { - $flags = $usage_flags->{authenticate}; + $flags = $usage_flags->{certify}; } else { my @ff = split(",", $ENV{PEM2OPENPGP_USAGE_FLAGS}); foreach my $f (@ff) { @@ -378,7 +378,7 @@ my $creation_time_packet = pack('CCN', 5, $subpacket_types->{sig_creation_time}, # FIXME: HARDCODED: what if someone wants to select a different set of # usage flags? For now, we do only authentication because that's what # monkeysphere needs. -my $usage_packet = pack('CCC', 2, $subpacket_types->{usage_flags}, $usage_flags->{authenticate}); +my $usage_packet = pack('CCC', 2, $subpacket_types->{usage_flags}, $flags); # FIXME: HARDCODED: how should we determine how far off to set the -- cgit v1.2.3