Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > How to set the message displayed when a Perl Script failscompilation?

Reply
Thread Tools

How to set the message displayed when a Perl Script failscompilation?

 
 
Nigel
Guest
Posts: n/a
 
      03-15-2009
Hi all,

I'm sure this is glaringly obvious to those in the know, but my
efforts to find the answer have failed.

My problem is with the message that is displayed in a web browser when
a script fails compilation. At the moment I'm getting this:

For help, please send mail to the webmaster ([no address given]),
giving this error message and the time and date of the error.

At least, I'd like to know how to set the email address for the
webmaster instead of no address given.

Ideally I'd like to handle the failed compilation in some way that
would allow me to display a friendly page to my visitor and send me an
email to alert me to the problem.

Has anyone got any ideas? Apart that is from not uploading scripts
that don't compile!

Thanks in advance,

Nigel
 
Reply With Quote
 
 
 
 
A. Sinan Unur
Guest
Posts: n/a
 
      03-15-2009
Nigel <(E-Mail Removed)> wrote in news:85b78e80-10b5-480f-a83f-
http://www.velocityreviews.com/forums/(E-Mail Removed):

> Ideally I'd like to handle the failed compilation in some way that
> would allow me to display a friendly page to my visitor and send me an
> email to alert me to the problem.
>
> Has anyone got any ideas?


Maybe you should read the documentation for the HTTP server you are using.

Sinan
--
A. Sinan Unur <(E-Mail Removed)>
(remove .invalid and reverse each component for email address)

comp.lang.perl.misc guidelines on the WWW:
http://www.rehabitation.com/clpmisc/
 
Reply With Quote
 
 
 
 
Gunnar Hjalmarsson
Guest
Posts: n/a
 
      03-15-2009
Nigel wrote:
> My problem is with the message that is displayed in a web browser when
> a script fails compilation. At the moment I'm getting this:
>
> For help, please send mail to the webmaster ([no address given]),
> giving this error message and the time and date of the error.
>
> At least, I'd like to know how to set the email address for the
> webmaster instead of no address given.
>
> Ideally I'd like to handle the failed compilation in some way that
> would allow me to display a friendly page to my visitor and send me an
> email to alert me to the problem.
>
> Has anyone got any ideas? Apart that is from not uploading scripts
> that don't compile!


Assuming Apache, this might be helpful:
http://httpd.apache.org/docs/2.0/mod...#errordocument

Redirect to another script (that compiles...) and have it both send an
email alert to you and print a friendly message.

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
 
Reply With Quote
 
Krishna Chaitanya
Guest
Posts: n/a
 
      03-15-2009
Hi, I don't know if this is going to help you....but read up on
fatalsToBrowser ...
 
Reply With Quote
 
Xho Jingleheimerschmidt
Guest
Posts: n/a
 
      03-17-2009
Gunnar Hjalmarsson wrote:
> Krishna Chaitanya wrote:
>> Hi, I don't know if this is going to help you....but read up on
>> fatalsToBrowser ...

>
> That feature
>
> 1) might reveal sensitive information,


What kind? The only sensitive information I've seen it reveal is "Hey,
this programmer is clueless." No one, other than a clueless
programmer, would think this info hard to obtain by means other than
fatalsToBrowser.


>
> 2) does typically not display "a friendly page" to a visitor, and


Right. And the user unfriendly message it typically displays might very
well be the very message the OP is currently seeing. So he might want
to read up on it.

>
> 3) does not alert the script author if the error happens when a visitor
> uses the script.


It can be made to.

Xho
 
Reply With Quote
 
Peter J. Holzer
Guest
Posts: n/a
 
      03-17-2009
On 2009-03-17 02:11, Xho Jingleheimerschmidt <(E-Mail Removed)> wrote:
> Gunnar Hjalmarsson wrote:
>> Krishna Chaitanya wrote:
>>> Hi, I don't know if this is going to help you....but read up on
>>> fatalsToBrowser ...

>>
>> That feature
>>
>> 1) might reveal sensitive information,

>
> What kind? The only sensitive information I've seen it reveal is "Hey,
> this programmer is clueless."


Authentication credentials.
Hash seeds (I think the recent typo3 exploit used this).
Non-public file names.
....

Often you want this kind of information in an error log so that you can
reproduce the error. So you might include them in a die(). But revealing
them to the user would be a bad idea.

hp
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
Japanese Text not displayed on Image Generated by Servlet on winXP, Linux but displayed on Win2000 boney Java 1 12-15-2006 02:24 PM
Any one know how to set an alias in the perl, and use it after the perl script end Lim kiang Leng Perl Misc 3 07-17-2004 11:11 PM
Perl and IIS - script runs but 'The page cannot be displayed' stew dean Perl Misc 58 10-30-2003 09:27 AM
Perl Help - Windows Perl script accessing a Unix perl Script dpackwood Perl 3 09-30-2003 02:56 AM



Advertisments