diff --git a/Crypto/Data/AFIS.hs b/Crypto/Data/AFIS.hs
--- a/Crypto/Data/AFIS.hs
+++ b/Crypto/Data/AFIS.hs
@@ -79,7 +79,7 @@
             xorMem blockPtr lastBlock blockSize
             diffuse hashF lastBlock blockSize
         fillRandomBlock g blockPtr = do
-            let (rand, g') = genRandomBytes blockSize g
+            let (rand, g') = cprgGenerate blockSize g
             withBytePtr rand $ \randPtr -> B.memcpy blockPtr randPtr blockSize
             return g'
 
@@ -132,10 +132,10 @@
                                  return ()
                  | otherwise = return ()
 
-        digestSize = B.length $ digestToByteString $ hashF B.empty
+        digestSize = byteableLength $ hashF B.empty
 
         byteStringOfPtr :: Ptr Word8 -> Int -> IO ByteString
         byteStringOfPtr ptr sz = newForeignPtr_ ptr >>= \fptr -> return $ B.fromForeignPtr fptr 0 sz
 
         hashBlock n src =
-            digestToByteString $ hashF $ runPacking (B.length src+4) (putWord32BE (fromIntegral n) >> putBytes src)
+            toBytes $ hashF $ runPacking (B.length src+4) (putWord32BE (fromIntegral n) >> putBytes src)
diff --git a/afis.cabal b/afis.cabal
--- a/afis.cabal
+++ b/afis.cabal
@@ -1,5 +1,5 @@
 Name:                afis
-Version:             0.1.1
+Version:             0.1.2
 Synopsis:            Anti-forensic Information Splitter
 Description:         Anti-forensic Information Splitter as defined for LUKS
 License:             BSD3
@@ -17,8 +17,8 @@
 Library
   Build-Depends:     base >= 3 && < 5
                    , bytestring
-                   , cryptohash
-                   , crypto-random-api
+                   , cryptohash >= 0.9.1
+                   , crypto-random
                    , packer
                    , byteable
   Exposed-modules:   Crypto.Data.AFIS
@@ -35,9 +35,10 @@
                    , test-framework-quickcheck2
                    , test-framework-hunit
                    , afis
-                   , crypto-random-api
+                   , crypto-random
                    , cryptohash
                    , bytestring
+                   , byteable
   ghc-options:       -Wall -fno-warn-orphans -fno-warn-missing-signatures
 
 source-repository head
diff --git a/tests/Tests.hs b/tests/Tests.hs
--- a/tests/Tests.hs
+++ b/tests/Tests.hs
@@ -14,8 +14,9 @@
 
 import qualified Crypto.Data.AFIS as AFIS
 import Crypto.Hash
-import Crypto.Random.API
+import Crypto.Random
 import qualified Data.ByteString as B
+import Data.Byteable
 
 mergeVec =
     [ (3
@@ -42,11 +43,13 @@
 data FakeRNG = FakeRNG Int B.ByteString
 
 instance CPRG FakeRNG where
-    cprgNeedReseed _ = NeverReseed
-    cprgSupplyEntropy b2 (FakeRNG o b) = FakeRNG o (B.append b b2)
-    cprgGenBytes n (FakeRNG o b)
+    cprgCreate pool = FakeRNG 0 (toBytes $ grabEntropy 1024 pool)
+    cprgSetReseedThreshold _ g = g
+    cprgGenerate n (FakeRNG o b)
         | n > B.length b - o = (B.take n $ B.drop o (B.concat $ replicate 10 b), FakeRNG 0 b)
         | otherwise          = (B.take n $ B.drop o b, FakeRNG (o+n) b)
+    cprgGenerateWithEntropy = cprgGenerate
+    cprgFork g = (g,g)
 
 instance Arbitrary AFISParams where
     arbitrary = AFISParams <$> arbitraryBS <*> choose (2,2) <*> elements [hash :: HashFunctionBS SHA1] <*> arbitraryRandom
