31 Jan, 2012, JohnnyStarr wrote in the 1st comment:
Votes: 0
The other day, I realized that I have the ability to send commands to my webserver via PHP's system function.
Right now my hosting is at FatCow.com, and because they provide a barebones (cheap) hosting service, they do not
provide SSH.

After running:
echo system("ruby -v");


I see something like:
Ruby v. 1.91


This is an interesting prospect.

After reading up on the PHP manual, there are a few helper functions that allow you to see output from STDERR and STDOUT.

That being the case, I have been curious as to whether this is in breach of my contract. I have looked around on the
site and cant find any direct answer. I guess I don't see anything wrong with it, but I'm curious if anyone here has had
similar questions regarding webservers. I think it makes for interesting discussion.
31 Jan, 2012, Cratylus wrote in the 2nd comment:
Votes: 0
JohnnyStarr said:
That being the case, I have been curious as to whether this is in breach of my contract. I have looked around on the
site and cant find any direct answer. I guess I don't see anything wrong with it, but I'm curious if anyone here has had
similar questions regarding webservers. I think it makes for interesting discussion.


I anal, but I suggest that if they have competent lawyers you probably don't want to gain unauthorized use of their servers.

Just ask them in an email that you save somewhere safe (as well as their response) whether they mind if you use that functionality of the PHP they provide.

-Crat
http://lpmuds.net
01 Feb, 2012, Kline wrote in the 3rd comment:
Votes: 0
PHP has maximum execution time limits. You should make a page that calls phpinfo(), view it, then secure it. You can find your max execution time there as it is set in your php.ini. IIRC, system calls and other forking are subject to this limitation – so even if you fork a call to some type of sshd, it will probably close and timeout within a few minutes if your host doesn't have an automatic kill switch in place already (as DreamHost does).
0.0/3