diff --git a/wai-secure-cookies.cabal b/wai-secure-cookies.cabal
--- a/wai-secure-cookies.cabal
+++ b/wai-secure-cookies.cabal
@@ -1,7 +1,7 @@
 cabal-version:       3.0
 
 name:                wai-secure-cookies
-version:             0.1.0.7
+version:             0.1.0.8
 synopsis:            WAI middleware to automatically encrypt and sign cookies
 description:         wai-secure-cookies is a WAI middleware to automatically encrypt and sign cookies w/ specified keys, and a command line tool to generate those keys
 homepage:            https://github.com/habibalamin/wai-secure-cookies
@@ -14,6 +14,10 @@
 build-type:          Simple
 extra-source-files:  README.md
 
+flag cryptonite
+  description:       Enable use of cryptonite, instead of crypton fork
+  default:           False
+
 library
   hs-source-dirs:      src
   default-language:    Haskell2010
@@ -25,12 +29,16 @@
                      , Extension.ByteString
   build-depends:       base >= 4.7 && < 5
                      , wai >= 3.2 && < 4
-                     , cryptonite >= 0.24 && < 0.31
                      , bytestring >= 0.10 && < 0.12
                      , memory >= 0.14 && < 0.19
                      , random >= 1.1 && < 1.3
                      , split >= 0.2 && < 0.3
                      , http-types >= 0.12.1 && < 0.13
+  if flag(cryptonite)
+    -- all versions from 0.24
+    build-depends:     cryptonite >= 0.24 && <= 0.30
+  else
+    build-depends:     crypton >= 0.31 && < 1
 
 test-suite wai-secure-cookies-test
   hs-source-dirs:      spec
@@ -55,9 +63,12 @@
   default-language:    Haskell2010
   main-is:             Main.hs
   build-depends:       base
-                     , cryptonite
                      , bytestring
                      , memory
+  if flag(cryptonite)
+    build-depends:     cryptonite
+  else
+    build-depends:     crypton
 
 source-repository head
   type:              git
