HASH.SHA1

HASH.SHA1 calculates a SHA1 message digest based on a provided string. It throws an error if this function is passed an argument that is not a string.

Function category: HASH

Syntax

HASH.SHA1(arg)

Arguments

Definition

arg

A string to be transformed.

Examples

Example 1: Encrypt a phrase or key

Let's say we have the following HASH.SHA1 with a string as argument.

HASH.SHA1('secret-phrase')

This returns the following SHA1 digest:

b9e2f93ae5bfd09cd1bd52b14f94bf45affac0f8

Note: The HASH.MD5, HASH.SHA256, HASH.SHA384, and HASH.SHA512 are supported.