Math::...ntropy(3pm)

πŸŽ€ NAME πŸŽ€

Math::Prime::Util::Entropy β€” bestie, it gets you a good random seed πŸ’–

This is the manual page for the module in section 3pm (User Contributed Perl Documentation, for the record, iykyk).


✨ VERSION ✨

Version 0.74 πŸ¦‹


🌸 SYNOPSIS 🌸

Okay so not to be dramatic but this section is literally empty. Nothing. Zero. Void. The author said "you don't need a synopsis, the vibe is the synopsis" πŸ’€


πŸ‘‘ DESCRIPTION πŸ‘‘

So here's the tea β˜• β€” this module gives you one single method to grab a good seed if it possibly can. That's it. That's the whole job. Main character minimalism.

It's a streamlined version of Crypt::Random::Seed, and it also stole some ideas from Bytes::Random::Secure::Tiny 🧚 (respectfully, of course).


πŸ¦‹ entropy_bytes πŸ¦‹

You hand it a number of bytes, n, and it hands you back one of two things:

  • undef β€” meaning no good seed was available, sorry babe 😭
  • a binary string with good entropy ✨

And the way it decides? It tries these, in order, and it does not skip around:

  • the Win32 Crypto API πŸͺŸ
  • /dev/urandom 🐧
  • /dev/random 🎲
  • Crypt::Random::Seed 🌱
  • Crypt::PRNG πŸ”₯

It goes down the list and takes what it can get. Periodt πŸ’…


🌈 SEE ALSO 🌈

Go read these too, bestie, they're all part of the family:

  • Math::Prime::Util
  • Crypt::Random::Seed
  • Bytes::Random::Secure
  • Bytes::Random::Secure::Tiny
  • Crypt::PRNG

πŸ’œ AUTHORS πŸ’œ

Dana Jacobsen <dana@acm.org> β€” absolute icon, no cap πŸ‘‘


Copyright 2017 by Dana Jacobsen <dana@acm.org> πŸ’–

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

fr fr, same terms as Perl itself. That's the license. Slay.

So anyway, that's the whole page, gorgeous 🌸 β€” this was perl v5.42.3, dated 2026-08-20, and yes, that's the Manpage of Math::...ntropy(3pm). Stay seeded, stay iconic ✨🫢

πŸ“¦ where this page comes from