diff options
-rw-r--r-- | keysafe.hs | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -10,6 +10,7 @@ module Main where import Types import Tunables import Encryption +import Cost import Shard import Storage import Storage.LocalFiles @@ -22,12 +23,15 @@ main = do storedemo :: IO () storedemo = do kek <- genKeyEncryptionKey tunables name password + putStrLn "Very rough estimate of cost to brute-force the password:" + print $ estimateAttack spotAWS $ estimateBruteforceOf kek + (passwordEntropy password) let esk = encrypt kek secretkey let sis = shardIdents tunables name keyid shards <- genShards esk tunables print =<< mapM (uncurry (storeShard localFiles)) (zip (getIdents sis) shards) where - password = Password "foo" + password = Password "correct horse battery staple" name = Name "bar" tunables = testModeTunables -- defaultTunables keyid = KeyId gpgKey "foobar" |