GPG with PHP problem
Chris Mason
masonc@masonc.com
Sun Aug 19 14:53:01 2001
This is a multi-part message in MIME format.
------=_NextPart_000_0000_01C1288E.4C0DBB80
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit
I have a GPG class for php which works fine, I'll send it to you directly.
-----Original Message-----
From: gnupg-users-admin@gnupg.org [mailto:gnupg-users-admin@gnupg.org]On
Behalf Of JohnHBeasley@aol.com
Sent: Sunday, August 19, 2001 8:03 AM
To: gnupg-users@gnupg.org
Subject: GPG with PHP problem
Hi,
I'm currently evaluating GPG as a product and I'm having some problems
invoking gpg commands from within a PHP script.
Currently I'm am able to encrypt files from the command line no problem
running under redhat linux (latest version) on an Apache web server but as
soon as I try the same command line via the system() command in PHP - the
file is no longer encrypted. A return code = 2 is returned by the system
command. However when I test the very same PHP script locally on my PC
which
is running under Windows 2000 - gpg is invoked and the file is encrypted
beautifully.
So I then tried creating a perl script which calls gpg to encrypt a file.
This works fine under linux on the Apache web server when you call the
perl
script from the command line. However when I then use a PHP script to call
the perl script to do the encryption - the perl script is invoked and runs
but once again the encryption does not take place !!! I know the perl
script
is run because there are print commands displayed as part of the output
!!!
I am at a loss as to what to try next. Is it a permissions thing between
PHP,
linux & GPG ?
Any help would be very much appreciated as I'm getting nowhere fast.
Thanks
Christine
------=_NextPart_000_0000_01C1288E.4C0DBB80
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dus-ascii">
<META content=3D"MSHTML 5.50.4807.2300" name=3DGENERATOR></HEAD>
<BODY>
<DIV><SPAN class=3D531210613-19082001><FONT face=3DArial color=3D#0000ff =
size=3D2>I have=20
a GPG class for php which works fine, I'll send it to you=20
directly.</FONT></SPAN></DIV>
<BLOCKQUOTE>
<DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DTahoma=20
size=3D2>-----Original Message-----<BR><B>From:</B> =
gnupg-users-admin@gnupg.org=20
[mailto:gnupg-users-admin@gnupg.org]<B>On Behalf Of=20
</B>JohnHBeasley@aol.com<BR><B>Sent:</B> Sunday, August 19, 2001 8:03=20
AM<BR><B>To:</B> gnupg-users@gnupg.org<BR><B>Subject:</B> GPG with PHP =
problem<BR><BR></FONT></DIV><FONT face=3Darial,helvetica><FONT =
size=3D2>Hi,=20
<BR><BR>I'm currently evaluating GPG as a product and I'm having some =
problems=20
<BR>invoking gpg commands from within a PHP script. <BR><BR>Currently =
I'm am=20
able to encrypt files from the command line no problem <BR>running =
under=20
redhat linux (latest version) on an Apache web server but as <BR>soon =
as I try=20
the same command line via the system() command in PHP - the <BR>file =
is no=20
longer encrypted. A return code =3D 2 is returned by the system =
<BR>command.=20
However when I test the very same PHP script locally on my PC which =
<BR>is=20
running under Windows 2000 - gpg is invoked and the file is encrypted=20
<BR>beautifully. <BR><BR>So I then tried creating a perl script which =
calls=20
gpg to encrypt a file. <BR>This works fine under linux on the Apache =
web=20
server when you call the perl <BR>script from the command line. =
However when I=20
then use a PHP script to call <BR>the perl script to do the encryption =
- the=20
perl script is invoked and runs <BR>but once again the encryption does =
not=20
take place !!! I know the perl script <BR>is run because there are =
print=20
commands displayed as part of the output !!! <BR><BR>I am at a loss as =
to what=20
to try next. Is it a permissions thing between PHP, <BR>linux & =
GPG ?=20
<BR><BR>Any help would be very much appreciated as I'm getting nowhere =
fast.=20
<BR><BR>Thanks <BR>Christine</FONT> </FONT></BLOCKQUOTE></BODY></HTML>
------=_NextPart_000_0000_01C1288E.4C0DBB80--