0

When Iam accessing my friends site with shell by using this link example.com/cmd.php?cmd=ls then i'm getting this error

warning the function system() diasbled in php in /opt/lampp/htdocs/files/cmd.php on line 1

So how can I enable that system function by using Phpmyadmin >>

I have the access to only phpmyadmin because i know that root password.I had tried for a solution in google but lot of sites saying that edit php.ini file but I can't access that php.ini file.

So please someone help me to enable that function through phpmyadmin

Thank You

3
  • The host has disabled the system() function, there's probably not much you can do to enable it again. Commented Apr 5, 2015 at 16:40
  • Contect your webhost, tell them to enable it for you. Commented Apr 5, 2015 at 16:41
  • "my friends site"... Commented Apr 5, 2015 at 17:04

3 Answers 3

1

As described on the PhpMyAdmin site itself

phpMyAdmin is a free software tool written in PHP, intended to handle the administration of MySQL over the Web.

PhpMyAdmin only allows you to manage your MySQL database and doesn't have anything to do with PHP itself nor can it change anything to the configuration of PHP.

Because system is a very powerful tool in PHP, most hosting providers will restrict or even disable this function in their configuration (the php.ini file) for safety measures. This means you won't be able to access this function without having the permission to change the configuration file itself.

Sign up to request clarification or add additional context in comments.

Comments

0

phpMyAdmin is a tool for database administration, not for php configurations. So short answer: you can't.

If you don't have access to php.ini, you cannot enable any disabled functions. That would be a security vulnerability.

If you don't need exactly system() but want to execute a given command, you can try one of the following commands that is possibly not disabled:

  • exec()
  • shell_exec()
  • passthru()
  • pcntl_exec()
  • proc_open()
  • popen()

And PLEASE keep in mind to check the given input and don't just execute the command given in the query string.

Comments

0

Nooooo You can't Do that using phpmyAdmin

First of all I would like to say If you try to gain access unauthorized content It is not a good thing :)

phpMyAdmin is a free and open source tool written in PHP intended to handle the administration of MySQL with the use of a web browser.

It can't do using phpmyadmin it also writen in php(same as your shell) if it can do that job... It is huge security hole

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.