MCPcopy Index your code
hub / github.com/simstudioai/sim / hmacSha256Hex

Function hmacSha256Hex

packages/security/src/hmac.ts:11–13  ·  view source on GitHub ↗
(body: string, secret: string | Buffer)

Source from the content-addressed store, hash-verified

9 * {@link ../compare | safeCompare} for timing-safe comparison.
10 */
11export function hmacSha256Hex(body: string, secret: string | Buffer): string {
12 return createHmac('sha256', secret).update(body, 'utf8').digest('hex')
13}
14
15/**
16 * HMAC-SHA256 of a UTF-8 body using the given secret, base64-encoded. Use for

Callers 15

hmac.test.tsFile · 0.90
generateSignatureFunction · 0.90
signPayloadFunction · 0.90
validateNotionSignatureFunction · 0.90
validateSlackSignatureFunction · 0.90
validateCalcomSignatureFunction · 0.90
validateSentrySignatureFunction · 0.90
validateZoomSignatureFunction · 0.90
handleChallengeFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected