diff --git a/System/EntropyNix.hs b/System/EntropyNix.hs
--- a/System/EntropyNix.hs
+++ b/System/EntropyNix.hs
@@ -77,12 +77,16 @@
 #endif
 
 fdReadBS :: Fd -> Int -> IO B.ByteString
-fdReadBS fd n = do
-    allocaBytes n $ \buf -> do
-        rc <- fdReadBuf fd buf (fromIntegral n)
+fdReadBS fd n =
+    allocaBytes n $ \buf -> go buf n
+ where
+ go buf 0   = B.packCStringLen (castPtr buf, fromIntegral n)
+ go buf cnt  | cnt <= n = do
+        rc <- fdReadBuf fd (plusPtr buf (n - cnt)) (fromIntegral cnt)
         case rc of
             0 -> ioError (ioeSetErrorString (mkIOError eofErrorType "fdRead" Nothing Nothing) "EOF")
-            n' -> B.packCStringLen (castPtr buf, fromIntegral n')
+            n' -> go buf (cnt - fromIntegral n')
+ go _ _     = error "Impossible!  The count of bytes left to read is greater than the request or less than zero!"
 
 #ifdef HAVE_RDRAND
 foreign import ccall unsafe "cpu_has_rdrand"
diff --git a/entropy.cabal b/entropy.cabal
--- a/entropy.cabal
+++ b/entropy.cabal
@@ -1,5 +1,5 @@
 name:           entropy
-version:        0.3.3
+version:        0.3.4
 description:    A platform independent method to obtain cryptographically strong entropy 
                 (RDRAND when available anywhere, urandom on nix, CryptAPI on Windows, patches welcome).
                 Users looking for cryptographically strong (number-theoretically
@@ -18,7 +18,7 @@
 -- ^^ Used for HaLVM
 build-type:        Custom
 -- ^^ Test for RDRAND support using 'ghc'
-cabal-version:  >=1.10
+cabal-version:  >=1.17
 tested-with:    GHC == 7.8.2
 -- data-files:
 extra-source-files:   ./cbits/rdrand.c, ./cbits/rdrand.h, README.md
