Liking cljdoc? Tell your friends :D

altcha-clj.verify


check-solutionclj/s

(check-solution payload hmac-key check-expiration?)

Verifies the solution received from the client, returning an explicit true or a falsy nil Params:

  • payload: the map of the following keys received from the client. Note that usually you'll get the solution encoded in base-64
    • algorithm
    • challenge - the solved challenge value
    • number - the random number generated previously
    • salt
    • signature
  • hmac-key - the HMAC key used for verification.
  • check-expiration? - whether to check if the challenge has not expired. Recommended to be kept as true
Verifies the solution received from the client, returning
an explicit `true` or a falsy `nil`
Params:
- `payload`: the map of the following keys received from the client.
Note that usually you'll get the solution encoded in base-64
  - `algorithm`
  - `challenge` - the solved challenge value
  - `number` - the random number generated previously
  - `salt`
  - `signature`
- `hmac-key` - the HMAC key used for verification.
- `check-expiration?` - whether to check if the challenge has not expired.
Recommended to be kept as true
sourceraw docstring

check-solution-base64clj/s

(check-solution-base64 b64-payload hmac-key check-expiration?)

Verifies a base64 encoded solution

Verifies a base64 encoded solution
sourceraw docstring

signature-not-expired?clj/s

(signature-not-expired? verification-data current)
source

verify-fields-hashclj/s

(verify-fields-hash form-data fields fields-hash algorithm)

Verify the hashes of field values in the input map. Useful for scraper protection

Verify the hashes of field values in the input map.
Useful for scraper protection
sourceraw docstring

verify-server-signatureclj/s

(verify-server-signature {:keys [algorithm verification-data signature verified]
                          :as payload}
                         hmac-key)
source

verify-server-signature-base64clj/s

(verify-server-signature-base64 base64-payload hmac-key)
source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close