Jump to content

rodbm

Members
  • Posts

    3
  • Joined

  • Last visited

rodbm's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Edit: I fogot I had the directory privacy up for that url. It works perfectly now, thanks!
  2. Thank you wolstech. I tried that before and I still can't get this function to work. The py file I'm using is as follows: #!/usr/bin/python print("Content-Type: text/html\n\n") print("Heliohost rules!") And the php I'm trying to make it to work is as follows: <?php $grab = file_get_contents("http://mydomain.heliohost.org/cgi-bin/test.py"); echo $grab; ?> I get the message: Warning: file_get_contents(http://mydomain.heliohost.org/cgi-bin/test.py): failed to open stream: HTTP request failed! HTTP/1.1 401 Unauthorized in ../test.php on line 3 I with the dir path instead of the url but it just returns the full code in plain text. Am I doing something wrong?
  3. Hey there everyone, I have good knowledge of python but I'm still learning Php (well to be honest I started learning it for this purpose). I have a Python script in /cgi-bin and it works fine when I go to mydomain.heliohost.org/cgi-bin/script.py. What I want to do is make it so that it starts from a Php file outside of /cgi-bin. I tried shell_exec() but I'm getting the "Warning: shell_exec() has been disabled for security reasons..." message. I know this function can be used for malicious purposes and that's why it's blocked. I tried some other functions but nothing seems to work or I'm doing it wrong. Question: Can this be done without the use of shell_exec() by any chance? I know there are some duplicate topics of this subject, but as I said I tried a few solutions posted on them and these didn't work. Thanks for your attention!
×
×
  • Create New...