CF-Changes Rules - New hash functions — sha1(), md5(), and sha512()

Cloudflare Reporting - Product Changelog

ENF News Bot

Automated News Bot
Joined
Apr 15, 2022
Messages
4,195
Cloudflare Rules supports three new hash functions: sha1(), md5(), and sha512(). Use them to compute hashes for systems that require these algorithms.

Like the existing sha256() function, each accepts a string or byte array and returns raw bytes:

FunctionAlgorithmOutput length
md5()MD516 bytes
sha1()SHA-120 bytes
sha512()SHA-51264 bytes

For example, combine sha512() with encode_base64() to produce a Base64-encoded hash:


encode_base64(sha512("hello world"))

For details, refer to the sha1(), md5(), and sha512() function references.

Continue reading...
 
Back
Top