commit 369b82e1624fef10f6146fed2c280eb12ae90339
parent 2f91036649975655ab35facddcc8fbd8db8a5d71
Author: Jared Tobin <jared@jtobin.io>
Date: Wed, 16 Aug 2023 17:22:10 -0230
Default pragmas.
Diffstat:
8 files changed, 5 insertions(+), 15 deletions(-)
diff --git a/cryptopals.cabal b/cryptopals.cabal
@@ -13,8 +13,10 @@ library
default-language: Haskell2010
default-extensions:
BangPatterns
+ DeriveGeneric
LambdaCase
OverloadedStrings
+ RankNTypes
RecordWildCards
ViewPatterns
hs-source-dirs:
diff --git a/docs/s5.md b/docs/s5.md
@@ -280,8 +280,8 @@ its public key, then the server will compute S = 0 as its shared secret.
Whoops! The client can then just pass along the appropriate MAC to
authenticate.
-Example, using the 'srpZero' protocol and 'authZero' initial client
-action:
+Example, with the client using the 'srpZero' protocol and 'authZero'
+initial action:
-- GHCi instance one
> server "3000" srp
diff --git a/lib/Cryptopals/DH.hs b/lib/Cryptopals/DH.hs
@@ -1,5 +1,3 @@
-{-# LANGUAGE RecordWildCards #-}
-
module Cryptopals.DH (
p
, g
diff --git a/lib/Cryptopals/DH/Core.hs b/lib/Cryptopals/DH/Core.hs
@@ -1,5 +1,3 @@
-{-# LANGUAGE DeriveGeneric #-}
-
module Cryptopals.DH.Core (
Group(..)
, p
diff --git a/lib/Cryptopals/DH/Session.hs b/lib/Cryptopals/DH/Session.hs
@@ -1,6 +1,3 @@
-{-# LANGUAGE DeriveGeneric #-}
-{-# LANGUAGE RankNTypes #-}
-
module Cryptopals.DH.Session (
Command(..)
, genGroup
diff --git a/lib/Cryptopals/Digest/Pure/SHA.hs b/lib/Cryptopals/Digest/Pure/SHA.hs
@@ -2,7 +2,7 @@
--
-- https://hackage.haskell.org/package/SHA-1.6.4.4/docs/src/Data.Digest.Pure.SHA.html
-{-# LANGUAGE BangPatterns, CPP, FlexibleInstances #-}
+{-# LANGUAGE CPP, FlexibleInstances #-}
-- |Pure implementations of the SHA suite of hash functions. The implementation
-- is basically an unoptimized translation of FIPS 180-2 into Haskell. If you're
-- looking for performance, you probably won't find it here.
diff --git a/lib/Cryptopals/SRP.hs b/lib/Cryptopals/SRP.hs
@@ -1,6 +1,3 @@
-{-# LANGUAGE DeriveGeneric #-}
-{-# LANGUAGE RecordWildCards #-}
-
module Cryptopals.SRP where
import Control.Concurrent (threadDelay)
diff --git a/lib/Pipes/Network.hs b/lib/Pipes/Network.hs
@@ -1,5 +1,3 @@
-{-# LANGUAGE RankNTypes #-}
-
module Pipes.Network (
N.Socket(..)
, N.SockAddr(..)