bunway
    Preparing search index...

    Function unsignCookie

    • Verify and extract value from a signed string. Uses timing-safe comparison to prevent timing attacks.

      Parameters

      • signedValue: string

        The signed value in format "value.signature"

      • secrets: string[]

        Array of secrets to try (for key rotation)

      Returns string | false

      The original value if signature is valid, false otherwise