                   :as options}]]
   {:pre [(map? claims)]}
   (exc/try-on
-   (let [cipher (get-cipher enc)
-         scek (generate-cek {:key key :alg alg})
+   (let [scek (generate-cek {:key key :alg alg})
          ecek (encrypt-cek {:cek scek :alg alg})
          iv (generate-iv {:enc enc})
          header (generate-header {:alg alg :enc enc :zip zip})

  (exc/try-on
   (let [[header ecek iv ciphertext authtag] (str/split input #"\." 5)
         {:keys [alg enc zip] :or {zip ::none}} (parse-header header)
         cipher (get-cipher enc)
         ecek (codecs/safebase64->bytes ecek)
         scek (generate-cek {:key key :alg alg})
         iv (codecs/safebase64->bytes iv)

    (-> (codecs/bytes->str data)
        (json/parse-string true))))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Public Api
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
