Mailinglisten-Archive |
Hi, > IMHO reicht definitiv der Public-Key des Empfaengers - sonst Nein. Zum Verschlüsseln mußt du stets dein Mantra mit angeben. Ich hab aber gerade in der PGP FAQ einen interessanten Abschnitt gefunden, wie das Problem dennoch gelöst werden kann: --------------- The best, but also the most complicated way is using the PGPPASSFD environment variable. This variable should contain a "file descriptor number" pointing to a file which contains the passphrase. This will protect the passphrase from anyone but the superuser, if you properly set the file's permissions. Thanks to Jack Gostl <gostl_(at)_argos.argoscomp.com> for the following. You can find something on this in the appnotes file in the pgp262 distribution. If you set PGPPASSFD to 0, pgp will read the passphrase from stdin as soon it starts. PGPPASSFD=0; export PGPPASSFD echo "PassPhraseHere" | pgp -east file recipient1 recipient2.. Patrick J. LoPresti <patl_(at)_lcs.mit.edu> added: You could also use funky shell redirection to make PGP get the passphrase from an arbitrary file. The exact command to define a variable depends on the shell; ksh and the likes use export PGPPASSFD=3, and csh and derivates use setenv PGPPASSFD 3. setenv PGPPASSFD 3; pgp -eat file recipient 3 < /my/passphrase/file This last example has the added advantage that standard input is still available to the user, for example to answer Yes or No to certain questions. ---------------- -- Björn Schotte 09364/810492 PHP-Center -> <http://www.php-center.de/> Virtuelle Postkartengrüsse -> <http://www.web-cards.de/>
php::bar PHP Wiki - Listenarchive