I'm confused about status of running setuid script with perl 5.16

I see in 5.12 delta
suidperl is no longer part of Perl. It used to provide a mechanism to emulate setuid permission bits on systems that don't support it properly.

I read this as systems that properly support setuid bits should not be affected, but my experience does not match.

Summary
-------
God awful old RedHat 8.0 perl 5.8.8 setting setuid on script works as expected. New Centos 7 perl 5.16 setting setuid on script does not work as expected.

example
-------
On Centos 7 Perl 5.16

sudo -i cat > /tmp/setuid.pl #!/usr/bin/perl use English; print "UID:$UID EUID:$EUID\n"; ctrl D chmod a+rx /tmp/setuid.pl chmod u+s /tmp/setuid.pl exit /tmp/setuid.pl UID:1334 EUID:1334

On RedHat 8.0 perl 5.8.8

sudo -s cat > /tmp/setuid.pl #!/usr/bin/perl use English; print "UID:$UID EUID:$EUID\n"; ctrl D chmod a+rx /tmp/setuid.pl chmod u+s /tmp/setuid.pl exit /tmp/setuid.pl UID:1334 EUID:0

Have I overlooked something on Centos 7 setup to allow setuid?
Or did all setuid functionality get killed in 5.12?


In reply to perl 5.16 setuid by jamesrleu

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.