Thank you - I did change the ownership and group to webserver owner
(apache)for both the key file and the directory it's in and the script
itself.  But unfortunately still the same error.  I moved the vertex
(key file) to key directory under my scripts directory and am pointing
to it from the script.  All 3 are apache apache.  :(

Do you know what status code 255 means when I run
$b = "ssh -i key/vertex [EMAIL PROTECTED] TX 77041 COD 10000.00";
system($b, $g);
echo $g;

Thank you for the invaluable usr/bin/id script.  I had seen that path
mentioned in posts...

On Wed, 2003-07-09 at 15:49, Jeff Harris wrote:
> On Jul 9, 2003, "Mignon Hunter" claimed that:
> 
> |Hello all,
> |
> |I am trying to execute a command on another server from my web
> |application.
> |
> |I need to execute the command via ssh for security reasons. I have a
> |private key/passphrase installed for ssh so that I can run ssh without a
> |password.
> |
> |The command:
> |
> |ssh -i vertex [EMAIL PROTECTED] TX 77041 COD 10000.00
> |
> |Works from my box's command line. The vertex 'key' for ssh is also in
> |the same directory.
> |
> |But when I run
> |system(ssh -i vertex [EMAIL PROTECTED] TX 77041 COD 10000.00)
> |from my script I get an error:
> |
> |Host key verification failed.
> |
> [snip]
> |Any help is as always greatly appreciated.
> |
> |Thx
> |Mignon
> 
> Do you have the private key/passphrase installed as a regular user or the
> httpd user of the local machine on the remote machine?
> 
> PHP will run the scripts as the httpd user, not as the user who owns the
> script.
> 
> <?php
> $line = exec("/usr/bin/id");
> print ("PHP runs as $line\n</pre>\n");
> ?>
> 
> Jeff
> 
> -- 
> Registered Linux user #304026.
> "lynx -source http://jharris.rallycentral.us/jharris.asc | gpg --import"
> Key fingerprint = 52FC 20BD 025A 8C13 5FC6  68C6 9CF9 46C2 B089 0FED
> Responses to this message should conform to RFC 1855.
> 
-- 
Mignon Hunter
Web Master and Developer
Toshiba International
713.466.0277 x 3461


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to