1 | // Type definitions for cookie-signature 1.0
|
2 | // Project: https://github.com/tj/node-cookie-signature, https://github.com/visionmedia/node-cookie-signature
|
3 | // Definitions by: François Nguyen <https://github.com/lith-light-g>
|
4 | // Junyoung Choi <https://github.com/Rokt33r>
|
5 | // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
6 |
|
7 | /** Sign the given `val` with `secret`. */
|
8 | export function sign(value: string, secret: string): string;
|
9 |
|
10 | /**
|
11 | * Unsign and decode the given `val` with `secret`,
|
12 | * returning `false` if the signature is invalid.
|
13 | */
|
14 | export function unsign(value: string, secret: string): string | false;
|