Smart.Framework Logo

static class smartJ$CryptoHash
{ } .

CLASS :: Smart CryptoHash (ES6, Strict Mode)
Crypto Hash for JavaScript: CRC32B :: (Hex / B36) ; MD5 / SHA1 / SHA224 / SHA256 / SHA384 / SHA512 / SHA3-224 / SHA3-256 / SHA3-384 / SHA3-512 / HMAC :: (Hex / B64) ; PBKDF2 :: (Hex / B92)


class Methods

public static function crc32b ( {String} s, {Boolean} b36 ) {} . {String}
@throws: console.error
@return: {String} The CRC32B hash of the string (Hex or B36)
@param: {String} s The string
@param: {Boolean} b36 If set to TRUE will use Base36 Encoding instead of Hex Encoding
Returns the CRC32B hash of a string
public static function sh3a512 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA3-512 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA3-512 hash of a string
public static function sh3a384 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA3-384 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA3-384 hash of a string
public static function sh3a256 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA3-256 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA3-256 hash of a string
public static function sh3a224 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA3-224 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA3-224 hash of a string
public static function sha512 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA512 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA512 hash of a string
public static function sha384 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA384 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA384 hash of a string
public static function sha256 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA256 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA256 hash of a string
public static function sha224 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA224 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA224 hash of a string
public static function sha1 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The SHA1 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the SHA1 hash of a string
public static function md5 ( {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The MD5 hash of the string (Hex or B64)
@param: {String} str The string
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the MD5 hash of a string
public static function hmac ( {Enum} algo, {String} key, {String} str, {Boolean} b64 ) {} . {String}
@throws: console.error
@return: {String} The Hmac Hash of the string, salted by key (Hex or B64)
@param: {Enum} algo The hashing algo: md5, sha1, sha224, sha256, sha384, sha512, sha3-224, sha3-256, sha3-384, sha3-512
@param: {String} key The secret key
@param: {String} str The string to be hashed
@param: {Boolean} b64 If set to TRUE will use Base64 Encoding instead of Hex Encoding
Returns the HMAC hash of a string with support for various algorithms

class Properties


class Constants



documentation generated on: 2024-12-16 17:13:26 +0000


Smart.Framework © 2009-2024 unix-world.org