bobn has asked for the wisdom of the Perl Monks concerning the following question:
This works, even though I didn't permit 'match'.#!/usr/bin/perl -w use Safe; $c = new Safe; $c->permit_only( qw( leaveeval const )); $result = $c->reval('"A" =~ m/a/i') ? 'YES' : 'NO'; die "$@\n" if $@; print "\$result = $result\n"; __END__
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Catching m// with Safe.pm
by broquaint (Abbot) on Jun 09, 2003 at 10:19 UTC | |
by bobn (Chaplain) on Jul 16, 2003 at 13:37 UTC | |
by bobn (Chaplain) on Aug 01, 2003 at 03:05 UTC |