basm101 has asked for the wisdom of the Perl Monks concerning the following question:

Dear monks,

I have dowloaded PerlPlusPlugin, which allows tk programs to be viewed
in netscape browsers. I was able to run the makefile fine, and configured
the server and browser as in the readme docs. Checking the help menu
in netscape I saw the plugin was installed and enabled :)

There is a security CGI script with the plugin that does a lookup
on URLs pointing to perl programs and returns a security code to the plugin.
My problem is I have the plugin installed, have the cgi in my cgi-bin directory
but when I go to the test script (in my cgi-bin) I get the error: Error Security level =60!
Error: Attempt to execute unauthorised application failed.

As the security levels (or opcodes) appear to range from 0-5 Im confused.

Has anyone here been able to install and use the PerlPlusPlugin okay ?

If so any idea what I might be doing wrong?

Thanks a lot,

basm101

Replies are listed 'Best First'.
Re: PerlPlusPlugin: Security CGI problems
by tall_man (Parson) on Feb 21, 2003 at 16:32 UTC
    I have used it and it works. Did you modify the perlplus-secure.cgi to have an entry for your ppl script? You need to set the security level for each script explicitly there.
    $URL_ROOT="http://xxx.yyy.com/perl"; %url = ("$URL_ROOT/timesheet.ppl" => 4); $sec_level= $url{$url};
      Yes I have it set like this: basically exactly as the example
      provided when I downloaded it except I changed URL root to be my CGI directory
      and I moved the test script ptk_test.ppl into my cgi-bin directory too.
      $URL_ROOT="path to my cgi directory/cgi-bin"; %url = ("$URL_ROOT/neko.ppl" => 4, "$URL_ROOT/plop.ppl" => 2, "$URL_ROOT/y2k.ppl" => 2, "$URL_ROOT/thunder.ppl" => 2, "$URL_ROOT/ptk_test.ppl" => 2, "$URL_ROOT/quest.ppl" => 2, "$URL_ROOT/tktetris.ppl" => 2, ); $sec_level= $url{$url} || 1; print LOG " security level=$sec_level\n"; close LOG; print "Content-type: application/x-perlplus:.ppl:Perl\n\n"; print "$sec_level";
      basm101
        I'm not sure it will work that way, with the ppl files in the CGI directory. Apache will try to run it as a CGI script and PerlPlusPlugin will never get a chance at it.

        I configured a separate perl directory with Apache. You could also use a home directory for the scripts.

        Alias /perl/ /var/www/perl/