On Sun, Nov 29, 2015 at 08:57:47AM +0100, Salvatore Bonaccorso wrote: > Hi Kurt, > > ----cut---------cut---------cut---------cut---------cut---------cut----- > #!/usr/bin/perl > > use strict; > use warnings; > use autodie; > > use GnuPG::Interface; > > my $gnupg = GnuPG::Interface->new(); > > # how we create some handles to interact with GnuPG > my $input = IO::Handle->new(); > my $output = IO::Handle->new(); > my $handles = GnuPG::Handles->new( > stdin => $input, > stdout => $output > ); > > my $pid = $gnupg->verify( > handles => $handles, > command_args => [ '/tmp/test.asc', ], > ); > ----cut---------cut---------cut---------cut---------cut---------cut----- > > which correctly results in > > execve("/usr/bin/gpg", ["gpg", "--verify", "--", "/tmp/test.asc"], [/* 37 > vars */]) = 0
I actually tried that before for 1 mail, and it works. But I was getting confused and it was getting too late. So it had --verify twice before, and gpg just accepted both of them ... But I'm confused what I should do with this: invoke_gpg( 'Configuration' => $dvt, 'PassPhrase' => "$Config{Pass_Word}", 'GnuPG Args' => \@gpg_args, 'GnuPG Cmd' => 'Decrypt', 'Command Args' => [ "--output", "$bodydir/$msg_base.${body_suffix}", "--decrypt", "$bodydir/$msg" ] ); I assume this will break, I didn't test that yet. I assume the proper way to fix that is to use handles? But I could just move it to @gpg_args and it should work too? Kurt