cat file |gpg --option newfile oldfile #### open (PASS, "+<$pass") or warn "was unable to open FH $!"; for (;;) { $gpgpass = $_; }