Working on #17576, I wanted to understand when and where an #idfef FCRYPT block would be included. Having dug into it a little, FCRYPT seems redundant and we could remove the few instances of it appearing. (Perhaps in the next release cycle, having dropped some advanced notice in the v5.32 perldelta.)
Core contains only a few small instances of FCRYPT and nothing in Configure or the platform-specific folders mention it. This was discussed almost two decades ago and summarized as "The (f)crypt of mystery" in:
https://www.perl.com/pub/2000/11/p5pdigest/THISWEEK-20001107.html/
* The obsolete function fcrypt is no longer available to newly linked
binaries. It was just another name for the standard function crypt,
and it has not appeared in any header file in many years.
Suggested Actions
Add a mention in the perldelta for the upcoming stable release that support for FCRYPT will be removed in the v5.34 release.
Remove FCRYPT early in the v.5.33.x cycle
Potential Pitfalls
People compiling with FCRYPT manually defined on purpose. They should hopefully know who they are!
Description
Working on #17576, I wanted to understand when and where an
#idfef FCRYPT
block would be included. Having dug into it a little, FCRYPT seems redundant and we could remove the few instances of it appearing. (Perhaps in the next release cycle, having dropped some advanced notice in the v5.32 perldelta.)Core contains only a few small instances of FCRYPT and nothing in Configure or the platform-specific folders mention it. This was discussed almost two decades ago and summarized as "The (f)crypt of mystery" in: https://www.perl.com/pub/2000/11/p5pdigest/THISWEEK-20001107.html/
This identifier (and some use of fcrypt() that looks similar to that in core today) seem to have not been present in Perl 2.0 but were added in Perl 3.0: https://perl5.git.perl.org/perl5.git?a=search&h=a687059cbaf2c6fdccb5e0fae2aee80ec15625a8&st=grep&s=FCRYPT
At no time does there seem to have been a Configure probe or platform-specific requirement for it.
Q. Does this mean that if you wanted fcrypt() support in perl that you had to explicitly ask for it?
As to what it would get you, probably a faster version of crypt(3) that originated in Alec Muffet's 'Crack' password cracker and had been integrated into glibc by the end of the last millenium: https://sourceware.org/git/?p=glibc.git;a=blob_plain;f=crypt/README.ufc-crypt;hb=HEAD
However, it hasn't provided anything different for a while, and may not even be available for modern build environments, as the NEWS for glibc v2.28 points out in https://sourceware.org/git/?p=glibc.git;a=blob;f=NEWS;hb=7975f9a48a83b95174503bda6c48124f08cb4f62#l923:
Suggested Actions
Potential Pitfalls