Following @etnt great httpd_router post (pure OTP gems are having a moment!), here’s one more: tls_bloom_filter.erl, tucked away in lib/ssl/src/.
It powers TLS 1.3 anti-replay protection, using a rotating pair of Bloom filters to detect already-seen 0-RTT binders. But look past the TLS context and you’ll find a clean, dependency free Bloom filter with configurable hash functions, bit-array sizes, and false positive rates.
Pure Erlang. Zero deps. Already on your machine.
Between this and @etnt httpd_router, I’m starting to think we need a “Hidden Treasures of OTP” series. Who knows what else is lurking in there?