On Mon, 2009-01-26 at 15:07 -0800, mark.ma...@gdit.com wrote:
> My question is this – how can my ServiceRoutine in ServiceScript.pl
> get its own path? I would like to record this to the database for
> auditing purposes as well, to make sure no one is using a substitute
> version of ServiceRoutine from another script.

my ( $whoami ) = grep { m{ \b ServiceScript \. pl \b }msx } values %INC;
print "$whoami\n";

If someone is using another sub, your audit would only contain a NULL
field since it would not record anything.  Or it would contain a copy of
the path to try to spoof you.  Only by moving ServiceScript.pl around
would you hope to catch illegitimate subs.


-- 
Just my 0.00000002 million dollars worth,
  Shawn

"It would appear that we have reached the limits of what it is
 possible to achieve with computer technology, although one should
 be careful with such statements, as they tend to sound pretty silly
 in 5 years."
   --John von Neumann, circa 1960


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to