MCPcopy
hub / github.com/freeCodeCamp/freeCodeCamp / sign

Function sign

api/src/plugins/cookies.ts:26–27  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

24 * @returns The signed cookie value.
25 */
26export const sign = (value: string) =>
27 's:' + fastifyCookie.sign(value, COOKIE_SECRET);
28
29/**
30 * Unsigns a cookie value by removing the "s:" prefix and using the COOKIE_SECRET.

Callers 2

auth0.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected