HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

Modulecrypton-1.0.4Haskell2010

Crypto.Data.AFIS

Haskell implementation of the Anti-forensic information splitter available in LUKS. http://clemens.endorphin.org/AFsplitter

The algorithm bloats an arbitrary secret with many bits that are necessary for the recovery of the key (merge), and allow greater way to permanently destroy a key stored on disk.

  • 2 values
  • Packagecrypton-1.0.4
  • Exports2
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceAFIS.hs
valuesplit
  1. :: (ByteArray ba, HashAlgorithm hash, DRG rng)
  2. => hash

    Hash algorithm to use as diffuser

  3. -> rng

    Random generator to use

  4. -> Int

    Number of times to diffuse the data.

  5. -> ba

    original data to diffuse.

  6. -> (ba, rng)

    The diffused data

#

Split data to diffused data, using a random generator and an hash algorithm.

the diffused data will consist of random data for (expandTimes-1) then the last block will be xor of the accumulated random data diffused by the hash algorithm.

  • ---------

  • orig -

  • ---------

  • --------- ---------- --------------

  • rand1 - - rand2 - - orig ^ acc -

  • --------- ---------- --------------

where acc is : acc(n+1) = hash (n ++ rand(n)) ^ acc(n)

valuemerge
  1. :: (ByteArray ba, HashAlgorithm hash)
  2. => hash

    Hash algorithm used as diffuser

  3. -> Int

    Number of times to un-diffuse the data

  4. -> ba

    Diffused data

  5. -> ba

    Original data

#

Merge previously diffused data back to the original data.