Re: Why executable?

2003-08-14 Thread fliptop
On Mon, 11 Aug 2003 at 22:36, Octavian Rasnita opined: [snip] OR:I've tried chmodding the perl script to 755, and I've tried running it OR:with: OR: OR:$ script.pl OR: OR:...but it didn't want to run, telling me that there is no command OR:script.pl, even though the script has a shebang line in

Re: Why executable?

2003-08-14 Thread zentara
On Mon, 11 Aug 2003 11:33:40 +0300, [EMAIL PROTECTED] (Octavian Rasnita) wrote: Hi all, Does anyone know why the perl scripts need to have the execute permission under Unix? I am asking this because I've seen that the PHP files don't need this permission. Couldn't perl just read a text file

Why executable?

2003-08-14 Thread Octavian Rasnita
Hi all, Does anyone know why the perl scripts need to have the execute permission under Unix? I am asking this because I've seen that the PHP files don't need this permission. Couldn't perl just read a text file (doesn't matter if it has an execute permission or not), interpret it and execute

Re: Why executable?

2003-08-14 Thread Ovid
And as a word of caution, some like to add '.' to their path in order to save typing an extra two letters ('./' in front of the file name). Don't do this, though, as this is a major security hole. Using google to search for 'current directory path linux security hole' for many examples of

Re: Why executable?

2003-08-14 Thread Octavian Rasnita
: http://teddy.fcc.ro/ Email: [EMAIL PROTECTED] - Original Message - From: Randal L. Schwartz [EMAIL PROTECTED] To: [EMAIL PROTECTED]; Kristofer Hoch [EMAIL PROTECTED] Sent: Monday, August 11, 2003 7:35 PM Subject: Re: Why executable? Kristofer == Kristofer Hoch [EMAIL PROTECTED] writes

Re: Why executable?

2003-08-14 Thread Octavian Rasnita
, Teddy's Center: http://teddy.fcc.ro/ Email: [EMAIL PROTECTED] - Original Message - From: Kristofer Hoch [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, August 11, 2003 5:04 PM Subject: Re: Why executable? This is what I do for security on my webserver. I don't have the shebang

Re: Why executable?

2003-08-14 Thread Kristofer Hoch
You should never be able to guess the implementation language by looking at a URL. Wrong. Wrong. I couldn't agree more. None of my scripts are executed directly...IE there is not script called 'index.pl'. Alternatly, I use HTML::Mason for dynamic web content. The Mason handler calls the

Re: Why executable?

2003-08-14 Thread Camilo Gonzalez
Okay then, how should scripts be called? Let's say I'm using a form. What would the action be? Kristofer Hoch wrote: You should never be able to guess the implementation language by looking at a URL. Wrong. Wrong. I couldn't agree more. None of my scripts are executed directly...IE

Re: Why executable?

2003-08-14 Thread Randal L. Schwartz
Octavian == Octavian Rasnita [EMAIL PROTECTED] writes: Octavian Hmm, are you telling that I can create a perl file and name Octavian it file.html, file.php, or even file.asp, and use a shebang Octavian line in it, then it will be parsed as a perl file? Octavian Or I need to use extensions that

Re: Why executable?

2003-08-11 Thread Kristofer Hoch
This is what I do for security on my webserver. I don't have the shebang line in my scripts. The webserver has a list of approved perl script extensions. When it runs across a file with this extension, the web server executes it with perl. Otherwise, it treats the file as if it is text/html.