Skip to content
class method

OpenSSL::Digest.digest

(::String name, ::String data) -> ::String
digest(name, data)

Return the hash value computed with name Digest. name is either the long name or short name of a supported digest algorithm.

Example

Example
OpenSSL::Digest.digest("SHA256", "abc")
See also .digests .new also in 4.1 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0