module Digest::MD5

MD5 (RFC 1321). Broken as a cryptographic hash: here for protocols that still use it, such as PostgreSQL's md5 authentication.

<std:digest>:32

Class methods

def self.digest(data: Bytes | String) -> Bytes

The 16-byte MD5 digest of data.

Digest::MD5.digest("abc").size   # => 16

<std:digest>:38

def self.hexdigest(data: Bytes | String) -> String

The MD5 digest of data in lowercase hexadecimal (32 digits).

Digest::MD5.hexdigest("abc")   # => "900150983cd24fb0d6963f7d28e17f72"

<std:digest>:45