1

For security reasons, I would like to make sure my script is called by a specific cgi program.

Is it possible to get the name of the program that called the script ?

TIA

Mitch Match
  • 339
  • 4
  • 14
  • http://php.net/manual/en/function.debug-backtrace.php – Álvaro Touzón Feb 23 '17 at 08:25
  • 1
    http://stackoverflow.com/questions/1967158/how-can-i-get-the-name-of-the-script-that-called-a-function – Álvaro Touzón Feb 23 '17 at 08:25
  • That was fast ! I am going to try right away. Gracias, Álvaro. – Mitch Match Feb 23 '17 at 08:28
  • Possible duplicate of [How can I get the name of the script that called a function?](http://stackoverflow.com/questions/1967158/how-can-i-get-the-name-of-the-script-that-called-a-function) – Christophvh Feb 23 '17 at 08:30
  • Possible duplicate of [Finding out the filename that called my function in PHP](http://stackoverflow.com/questions/1935867/finding-out-the-filename-that-called-my-function-in-php) – Mark Fitzgerald Feb 23 '17 at 08:34
  • Well, it is not that conclusive. Thank you all, but I cannot find the name of the program that called my script by the methods described at the links. – Mitch Match Feb 23 '17 at 10:38
  • I will probably do what is suggested in one of the posts, to pass the name of the program in parameters. Once encrypted, it should be alright. – Mitch Match Feb 23 '17 at 10:39

0 Answers0