safe_level#

Report the current safety level used by File::Temp checks.

Synopsis#

my $level = File::Temp::safe_level();
File::Temp->safe_level(File::Temp::STANDARD);

What you get back#

The integer 0, which corresponds to STANDARD. The setter form is accepted but has no effect.

Differences from upstream#

  • Upstream supports STANDARD, MEDIUM, and HIGH; the latter two add sticky-bit and ancestor-ownership checks that are not implemented here. Requests to raise the level are silently clamped to STANDARD. Covered by t/81-xs-native/File-Temp/*.t.

See also#

  • top_system_uid — related stub used by the HIGH-level checks.

  • cmpstat — stat comparison performed independently of safe_level.