2014-12-23T14:57:49 GwenDragonVerschlüsseln mit den Modulen GnuPG oder Crypt::GPG
$gpg->gpgopts("--cipher-algo AES256");
1 2 3
$gpg->encrypt( plaintext => $in_filename, output => $out_filename, sign => 0, passphrase => $passwort );
1
2
3
4
5
6
7
8
9
10
11
12
13
Verzeichnis von C:\Program Files (x86)\GNU\GnuPG\pub
26.12.2014 16:03 <DIR> .
26.12.2014 16:03 <DIR> ..
25.11.2014 21:03 13.312 gpg-connect-agent.exe
25.11.2014 21:03 13.312 gpg.exe
25.11.2014 21:03 13.312 gpg2.exe
25.11.2014 21:03 13.312 gpgconf.exe
25.11.2014 21:03 13.312 gpgsm.exe
25.11.2014 21:03 13.312 gpgv.exe
25.11.2014 19:56 968.704 iconv.dll
25.11.2014 19:51 484.395 libgcc_s_sjlj-1.dll
25.11.2014 19:51 5.810.442 libstdc++-6.dll
9 Datei(en), 7.343.413 Bytes
1 2 3
my ($path) = grep { -x "$_/gpg" } split /:/, $ENV{PATH}; croak ( "Couldn't find gpg in PATH ($ENV{PATH})\n" ) unless $path;
1 2 3 4 5 6 7 8
my $file_from = 'test.txt'; my $file_to = 'test.gpg'; my $password = ' Blaaah'; open (my $FH, qq(| gpg --batch --passphrase-fd 0 -o "$file_to" --symmetric --cipher-algo AES256 "$file_from") ); print $FH $password; close $FH or die $!;