packages feed

ssh 0.2.11 → 0.2.12

raw patch · 2 files changed

+9/−7 lines, 2 filesdep ~asn1-datadep ~crypto-pubkey-types

Dependency ranges changed: asn1-data, crypto-pubkey-types

Files

src/SSH/Crypto.hs view
@@ -2,7 +2,8 @@  import Control.Monad (replicateM) import Control.Monad.Trans.State-import Data.ASN1.BER (decodeASN1Stream)+import Data.ASN1.BinaryEncoding (BER(..))+import Data.ASN1.Encoding (decodeASN1) import Data.ASN1.Stream import Data.Digest.Pure.SHA (bytestringDigest, sha1) import Data.List (isPrefixOf)@@ -69,7 +70,7 @@             . lines             $ x -    case decodeASN1Stream (toLBS asn1) of+    case decodeASN1 BER (toLBS asn1) of         Right (Start Sequence:ss)             | all isIntVal (fst $ getConstructedEnd 0 ss) ->             let (is, _) = getConstructedEnd 0 ss@@ -142,9 +143,9 @@         u -> error $ "unknown public key format: " ++ u  sign :: KeyPair -> LBS.ByteString -> IO LBS.ByteString-sign (RSAKeyPair (RSAPublicKey _ n) d) m = return $ LBS.concat+sign (RSAKeyPair (RSAPublicKey e n) d) m = return $ LBS.concat     [ netString "ssh-rsa"-    , netLBS (RSA.rsassa_pkcs1_v1_5_sign RSA.ha_SHA1 (RSAKey.PrivateKey 256 n d 0 0 0 0 0) m)+    , netLBS (RSA.rsassa_pkcs1_v1_5_sign RSA.ha_SHA1 (RSAKey.PrivateKey (RSAKey.PublicKey 256 n e) d 0 0 0 0 0) m)     ] sign (DSAKeyPair (DSAPublicKey p q g y) x) m = do     (r, s) <- DSA.signDigestedDataWithDSA (DSA.tupleToDSAKeyPair (p, q, g, y, x)) digest
ssh.cabal view
@@ -1,5 +1,5 @@ name:                ssh-version:             0.2.11+version:             0.2.12 synopsis:            A pure-Haskell SSH server library. description:     This package was split from darcsden into its own project; documentation@@ -19,6 +19,7 @@ build-type:          Simple cabal-version:       >= 1.6 stability:           Unstable+tested-with:         GHC==7.6.3  source-repository   head     type:           darcs@@ -43,7 +44,7 @@   other-modules:    SSH.Debug,                     SSH.Util -  build-depends:    asn1-data >= 0.6.1.2 && < 0.7,+  build-depends:    asn1-data >= 0.7.1,                     base >= 4 && < 5,                     base64-string,                     binary,@@ -51,7 +52,7 @@                     cereal,                     containers,                     crypto-api,-                    crypto-pubkey-types >= 0.1 && < 0.2,+                    crypto-pubkey-types >= 0.2,                     cryptohash,                     HsOpenSSL >= 0.8,                     network,