The user/group running the Apache, in your case as httpd.conf configured, daemon, must have a read access to the Pork.pm. It means that not only Pork.pm must have permission of 'r' for daemon, but also all parts in the path hieararchy enable daemon to "walktrough" to eventually read Pork.pm. This means at least the 'x' bit must be turned on for daemon.

Out of all.... You don't really need all that noise lines you now comment on. If you use PERL5LIB, perl automatically includes that in @INC. There's no point to untaint PERL5LIB either, because it will be ignored by perl in -T (taint mode), anyway. If you don't trust yourself, why didn't you put -T explicitly and see how's it going? And "use strict;", and "use warnings;".

However, if you insist to parse a lib path, assumming you really trust the source, this simple snip will do:

BEGIN { # $custom_path: you may obtain this global somewhere # outside of your code. You really need to reverse? unshift @INC, reverse split /:/, $custom_path; }
eval "use something;" just never works.

In reply to Re: Accessing Perl Modules Through .htaccess by naikonta
in thread Accessing Perl Modules Through .htaccess by monkfan

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.