Appearance
Interface: HttpHawkAuth
Hawk: the authorization: Hawk … header, a MAC over the timestamp, a nonce, the method, the path and query, the host, the port and, with includePayloadHash, the body. When the vendor answers with server-authorization, the host verifies it (and the payload hash it carries); one that does not verify fails the request with an HttpNetworkError whose network is unknown, the request having reached the vendor. An answer without one is accepted.
Properties
algorithm?
ts
optional algorithm?: "sha1" | "sha256";sha256 (the default) or sha1.
app?
ts
optional app?: string;authId
ts
authId: string;authKey
ts
authKey: string;ctx.secret(name).
authType
ts
authType: "hawk";dlg?
ts
optional dlg?: string;ext?
ts
optional ext?: string;includePayloadHash?
ts
optional includePayloadHash?: boolean;nonce?
ts
optional nonce?: string;A fixed nonce, for tests; the host makes a fresh one otherwise.
timestamp?
ts
optional timestamp?: string;Fixed seconds since the epoch, for tests; the host reads its clock otherwise.