Update: While I can open and write to a file in the current (cgi) directory from within the program when running as a CGI, gpg as called from the CGI doesn't seem to write anything. I tried:
`gpg --export -a --batch -o /home/...../cgi-bin/NEW`;
but it only works on command line fwiw.
I think I got it to do something a little while ago but it would only create a zero byte file.
I wonder how I'd go about trying to do this without using GnuPG or any other module, just the cgi talking to the binary..
Ah yes, I tried $gpg->export_keys( armor => 1, output => "keyring.pub" );
which creates a file in the appropriate place but one of zero bytes only. Permissions were cool.
Update: By cool I mean that it could write something. I could write successfully to files from the CGI. But it is not cool that only a zero byte file came out.. I tried it in different directories, and made a file chmod 777 in a 777 directory and gpg still wouldn't write to it from CGI. I have a whole application working on this system already so I don't think it is permissions.. I'm wondering if Io::Pipe will work.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.