summaryrefslogtreecommitdiff
path: root/dgit
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2016-10-23 21:11:37 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2016-10-30 19:50:47 +0000
commitc646a7f57da1b79467aab438ecf1d80d185a0456 (patch)
tree07d414bfaf7976d5d951ea8a5d180dbec40b8365 /dgit
parentf5b95599f4cafe664fd2f218d47ec9248605f698 (diff)
import-dsc: Check the signature
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
Diffstat (limited to 'dgit')
-rwxr-xr-xdgit13
1 files changed, 13 insertions, 0 deletions
diff --git a/dgit b/dgit
index ef81599..c6d1be7 100755
--- a/dgit
+++ b/dgit
@@ -5304,6 +5304,19 @@ sub cmd_import_dsc {
$dscdata = do { local $/ = undef; <D>; };
D->error and fail "read $dscfn: $!";
close C;
+
+ # we don't normally need this so import it here
+ use Dpkg::Source::Package;
+ my $dp = new Dpkg::Source::Package filename => $dscfn;
+ {
+ local $SIG{__WARN__} = undef;
+ if (!$dp->is_signed()) {
+ warn "$us: warning: importing unsigned .dsc\n";
+ } else {
+ my $r = $dp->check_signature();
+ }
+ }
+
parse_dscdata();
my $dgit_commit = $dsc->{$ourdscfield[0]};