Name

Taint ( boolean, inherited)

Synopsis

If this attribute is set to a true value and Perl is running in taint mode (e.g., started with the -T option), then all data fetched from the database is tainted, and the arguments to most DBI method calls are checked for being tainted. This may change.

The attribute defaults to off, even if Perl is in taint mode. See the perlsec manpage for more about taint mode. If Perl is not running in taint mode, this attribute has no effect.

When fetching data that you can trust, you can turn off the taint attribute for that statement handle, for the duration of the fetch loop.

Currently only fetched data is tainted. It is possible that the results of other DBI method calls, and the value of fetched attributes, may also be tainted in future versions. That change may well break your applications unless you take great care now. If you use DBI taint mode, please report your experience and any suggestions for changes.

Get Programming the Perl DBI now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.