 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 (defn hmac
-  [data ^String key ^String algorithm]
+  [data key ^String algorithm]
   (make-hmac data key algorithm))
 
 (defn hmac-verify
-  [data ^bytes signature ^String key ^String algorithm]
+  [data ^bytes signature key ^String algorithm]
   (verify-hmac data signature key algorithm))
 
 (defn shmac

  "Generic function that implement salted variant
of keyed-hash message authentication code (hmac).
This is a low level function and always return bytes."
  [data ^String key salt ^String algorithm]
  (let [key (concat-byte-arrays (->byte-array key)
                                (->byte-array salt))]
    (make-hmac data (sha512 key) algorithm)))

(defn- verify-salted-hmac
  [data ^bytes signature ^String key salt ^String algorithm]
  (let [key (concat-byte-arrays (->byte-array key)
                                (->byte-array salt))]
    (verify-hmac data signature (sha512 key) algorithm)))

  "Generic function that exposes a high level
interface for salted variant of keyed-hash message
authentication code verification algorithm."
  [data ^bytes signature key ^String salt ^String algorithm]
  (verify-salted-hmac data signature key salt algorithm))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
