NYCPHP Meetup

NYPHP.org

[nycphp-talk] SSH Login via PHP

Ben Sgro bens at oddcast.com
Fri Aug 11 10:02:59 EDT 2006


Hello Nick, 

http://us3.php.net/manual/en/ref.ssh2.php (you may need to tweak by hand for
SSH options).

It appears PHP.net has a lot of info for ssh:
http://us3.php.net/manual/en/function.ssh2-shell.php may work for a CLI php
app.

How about letting a user upload a new .* file that is created on their
locatal machine. Then they can login (w/ssh credentials) through the web
based GUI, select the file from an input type=file box and use
http://us3.php.net/manual/en/function.ssh2-scp-send.php
to send it.

There are probably a few solutions, good luck!

- Ben

-----Original Message-----
From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On
Behalf Of Nick
Sent: Friday, August 11, 2006 10:04 AM
To: talk at lists.nyphp.org
Subject: [nycphp-talk] SSH Login via PHP

I am looking to permit users to change their own .vacation and .forward 
files on our email server so that they can autoreply to email while they 
are away on holiday.  Since ssh is already set on our email server, I 
thought it might be possible to use php to permit the user to login and 
then easily change his/her .vacation message and switch on autoreply via 
a web page - from a different server:  I don't want our email server 
doing double duty as a webserver.

Please let me know if this is possible and if so what options are 
available to achieve this goal.  My web server is running on i5/OS which 
supports php5 but may be lacking certain options/libraries.

Thanks.

-- 
Regards,
Nicholas Hart
MPF


_______________________________________________
New York PHP Community Talk Mailing List
http://lists.nyphp.org/mailman/listinfo/talk

NYPHPCon 2006 Presentations Online
http://www.nyphpcon.com

Show Your Participation in New York PHP
http://www.nyphp.org/show_participation.php





More information about the talk mailing list