Enable Exec() in PHP

saqibskvip PHP exec() Enable

(PHP exec() Enable)

Error Message

Please Enable Exec() In PHP

Other Information

(other information and details relevant to your question)

Short & Strong Answer: No.

It is a shared hosting and your site is being hosted on small piece of our server, but exec() will execute commands in ALL the server. And for security issues we didn’t, don’t and won’t enable it anytime.

1 Like

I have to say, Wow, Why, As BayoDino says, you could literaly run

rm -rf /

With php exec(), anything could happen, you could take someone’s files, or even read /etc/shadow!

1 Like

The above is partially true. It’s disabled for security reasons, yes. But even if you did get access to the exec() function, you would be able to run commands as your own user, not the root user, so you don’t get unrestricted access to the whole server.

Still, there are a lot of nasty things you can do with exec(), even with a non-administrator user. Our abuse scanners are designed to recognize PHP code. If you can run arbitrary commands, you can execute a wide range of system commands which makes things much harder to secure for us.

So any kind of command line access from PHP will not be added to free hosting.


This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.