    -- CryptonNewtypes.hs: OpenPGP (RFC4880) newtype wrappers for some crypton types
    -- Copyright © 2012-2024  Clint Adams
    -- This software is released under the terms of the Expat license.
    -- (See the LICENSE file).
    {-# LANGUAGE DeriveDataTypeable #-}
    {-# LANGUAGE DeriveGeneric #-}

    module Codec.Encryption.OpenPGP.Types.Internal.CryptonNewtypes where

    import GHC.Generics (Generic)

    import Control.Monad (mzero)
    import qualified Crypto.PubKey.DSA as DSA
    import qualified Crypto.PubKey.ECC.ECDSA as ECDSA
    import qualified Crypto.PubKey.ECC.Types as ECCT
    import qualified Crypto.PubKey.RSA as RSA
    import qualified Data.Aeson as A
    import Data.Data (Data)
    import Data.Hashable (Hashable(..))
    import Data.Typeable (Typeable)
    import Prettyprinter (Pretty(..), (<+>), tupled)

    newtype DSA_PublicKey =
      DSA_PublicKey
        { DSA_PublicKey -> PublicKey
    unDSA_PublicKey :: DSA.PublicKey
        }
      deriving (Typeable DSA_PublicKey
    Typeable DSA_PublicKey =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> DSA_PublicKey -> c DSA_PublicKey)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c DSA_PublicKey)
    -> (DSA_PublicKey -> Constr)
    -> (DSA_PublicKey -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c DSA_PublicKey))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c DSA_PublicKey))
    -> ((forall b. Data b => b -> b) -> DSA_PublicKey -> DSA_PublicKey)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r)
    -> (forall u. (forall d. Data d => d -> u) -> DSA_PublicKey -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> DSA_PublicKey -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey)
    -> Data DSA_PublicKey
    DSA_PublicKey -> Constr
    DSA_PublicKey -> DataType
    (forall b. Data b => b -> b) -> DSA_PublicKey -> DSA_PublicKey
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u. Int -> (forall d. Data d => d -> u) -> DSA_PublicKey -> u
    forall u. (forall d. Data d => d -> u) -> DSA_PublicKey -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_PublicKey
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_PublicKey -> c DSA_PublicKey
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_PublicKey)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c DSA_PublicKey)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_PublicKey -> c DSA_PublicKey
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_PublicKey -> c DSA_PublicKey
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_PublicKey
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_PublicKey
    $ctoConstr :: DSA_PublicKey -> Constr
    toConstr :: DSA_PublicKey -> Constr
    $cdataTypeOf :: DSA_PublicKey -> DataType
    dataTypeOf :: DSA_PublicKey -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_PublicKey)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_PublicKey)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c DSA_PublicKey)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c DSA_PublicKey)
    $cgmapT :: (forall b. Data b => b -> b) -> DSA_PublicKey -> DSA_PublicKey
    gmapT :: (forall b. Data b => b -> b) -> DSA_PublicKey -> DSA_PublicKey
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PublicKey -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> DSA_PublicKey -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> DSA_PublicKey -> [u]
    $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> DSA_PublicKey -> u
    gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> DSA_PublicKey -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_PublicKey -> m DSA_PublicKey
    Data, DSA_PublicKey -> DSA_PublicKey -> Bool
    (DSA_PublicKey -> DSA_PublicKey -> Bool)
    -> (DSA_PublicKey -> DSA_PublicKey -> Bool) -> Eq DSA_PublicKey
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: DSA_PublicKey -> DSA_PublicKey -> Bool
    == :: DSA_PublicKey -> DSA_PublicKey -> Bool
    $c/= :: DSA_PublicKey -> DSA_PublicKey -> Bool
    /= :: DSA_PublicKey -> DSA_PublicKey -> Bool
    Eq, (forall x. DSA_PublicKey -> Rep DSA_PublicKey x)
    -> (forall x. Rep DSA_PublicKey x -> DSA_PublicKey)
    -> Generic DSA_PublicKey
    forall x. Rep DSA_PublicKey x -> DSA_PublicKey
    forall x. DSA_PublicKey -> Rep DSA_PublicKey x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. DSA_PublicKey -> Rep DSA_PublicKey x
    from :: forall x. DSA_PublicKey -> Rep DSA_PublicKey x
    $cto :: forall x. Rep DSA_PublicKey x -> DSA_PublicKey
    to :: forall x. Rep DSA_PublicKey x -> DSA_PublicKey
    Generic, Int -> DSA_PublicKey -> ShowS
    [DSA_PublicKey] -> ShowS
    DSA_PublicKey -> String
    (Int -> DSA_PublicKey -> ShowS)
    -> (DSA_PublicKey -> String)
    -> ([DSA_PublicKey] -> ShowS)
    -> Show DSA_PublicKey
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> DSA_PublicKey -> ShowS
    showsPrec :: Int -> DSA_PublicKey -> ShowS
    $cshow :: DSA_PublicKey -> String
    show :: DSA_PublicKey -> String
    $cshowList :: [DSA_PublicKey] -> ShowS
    showList :: [DSA_PublicKey] -> ShowS
    Show, Typeable)

    instance Ord DSA_PublicKey

    instance A.ToJSON DSA_PublicKey where
      toJSON :: DSA_PublicKey -> Value
    toJSON (DSA_PublicKey (DSA.PublicKey Params
    p PublicNumber
    y)) = (DSA_Params, PublicNumber) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (Params -> DSA_Params
    DSA_Params Params
    p, PublicNumber
    y)

    instance Pretty DSA_PublicKey where
      pretty :: forall ann. DSA_PublicKey -> Doc ann
    pretty (DSA_PublicKey (DSA.PublicKey Params
    p PublicNumber
    y)) =
        DSA_Params -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    forall ann. DSA_Params -> Doc ann
    pretty (Params -> DSA_Params
    DSA_Params Params
    p) Doc ann -> Doc ann -> Doc ann
    forall ann. Doc ann -> Doc ann -> Doc ann
    <+> PublicNumber -> Doc ann
    forall ann. PublicNumber -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty PublicNumber
    y

    newtype RSA_PublicKey =
      RSA_PublicKey
        { RSA_PublicKey -> PublicKey
    unRSA_PublicKey :: RSA.PublicKey
        }
      deriving (Typeable RSA_PublicKey
    Typeable RSA_PublicKey =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> RSA_PublicKey -> c RSA_PublicKey)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c RSA_PublicKey)
    -> (RSA_PublicKey -> Constr)
    -> (RSA_PublicKey -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c RSA_PublicKey))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c RSA_PublicKey))
    -> ((forall b. Data b => b -> b) -> RSA_PublicKey -> RSA_PublicKey)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r)
    -> (forall u. (forall d. Data d => d -> u) -> RSA_PublicKey -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> RSA_PublicKey -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey)
    -> Data RSA_PublicKey
    RSA_PublicKey -> Constr
    RSA_PublicKey -> DataType
    (forall b. Data b => b -> b) -> RSA_PublicKey -> RSA_PublicKey
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u. Int -> (forall d. Data d => d -> u) -> RSA_PublicKey -> u
    forall u. (forall d. Data d => d -> u) -> RSA_PublicKey -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c RSA_PublicKey
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> RSA_PublicKey -> c RSA_PublicKey
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c RSA_PublicKey)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c RSA_PublicKey)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> RSA_PublicKey -> c RSA_PublicKey
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> RSA_PublicKey -> c RSA_PublicKey
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c RSA_PublicKey
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c RSA_PublicKey
    $ctoConstr :: RSA_PublicKey -> Constr
    toConstr :: RSA_PublicKey -> Constr
    $cdataTypeOf :: RSA_PublicKey -> DataType
    dataTypeOf :: RSA_PublicKey -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c RSA_PublicKey)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c RSA_PublicKey)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c RSA_PublicKey)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c RSA_PublicKey)
    $cgmapT :: (forall b. Data b => b -> b) -> RSA_PublicKey -> RSA_PublicKey
    gmapT :: (forall b. Data b => b -> b) -> RSA_PublicKey -> RSA_PublicKey
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PublicKey -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> RSA_PublicKey -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> RSA_PublicKey -> [u]
    $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> RSA_PublicKey -> u
    gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> RSA_PublicKey -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> RSA_PublicKey -> m RSA_PublicKey
    Data, RSA_PublicKey -> RSA_PublicKey -> Bool
    (RSA_PublicKey -> RSA_PublicKey -> Bool)
    -> (RSA_PublicKey -> RSA_PublicKey -> Bool) -> Eq RSA_PublicKey
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: RSA_PublicKey -> RSA_PublicKey -> Bool
    == :: RSA_PublicKey -> RSA_PublicKey -> Bool
    $c/= :: RSA_PublicKey -> RSA_PublicKey -> Bool
    /= :: RSA_PublicKey -> RSA_PublicKey -> Bool
    Eq, (forall x. RSA_PublicKey -> Rep RSA_PublicKey x)
    -> (forall x. Rep RSA_PublicKey x -> RSA_PublicKey)
    -> Generic RSA_PublicKey
    forall x. Rep RSA_PublicKey x -> RSA_PublicKey
    forall x. RSA_PublicKey -> Rep RSA_PublicKey x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. RSA_PublicKey -> Rep RSA_PublicKey x
    from :: forall x. RSA_PublicKey -> Rep RSA_PublicKey x
    $cto :: forall x. Rep RSA_PublicKey x -> RSA_PublicKey
    to :: forall x. Rep RSA_PublicKey x -> RSA_PublicKey
    Generic, Int -> RSA_PublicKey -> ShowS
    [RSA_PublicKey] -> ShowS
    RSA_PublicKey -> String
    (Int -> RSA_PublicKey -> ShowS)
    -> (RSA_PublicKey -> String)
    -> ([RSA_PublicKey] -> ShowS)
    -> Show RSA_PublicKey
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> RSA_PublicKey -> ShowS
    showsPrec :: Int -> RSA_PublicKey -> ShowS
    $cshow :: RSA_PublicKey -> String
    show :: RSA_PublicKey -> String
    $cshowList :: [RSA_PublicKey] -> ShowS
    showList :: [RSA_PublicKey] -> ShowS
    Show, Typeable)

    instance Ord RSA_PublicKey

    instance A.ToJSON RSA_PublicKey where
      toJSON :: RSA_PublicKey -> Value
    toJSON (RSA_PublicKey (RSA.PublicKey Int
    size PublicNumber
    n PublicNumber
    e)) = (Int, PublicNumber, PublicNumber) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (Int
    size, PublicNumber
    n, PublicNumber
    e)

    instance Pretty RSA_PublicKey where
      pretty :: forall ann. RSA_PublicKey -> Doc ann
    pretty (RSA_PublicKey (RSA.PublicKey Int
    size PublicNumber
    n PublicNumber
    e)) =
        Int -> Doc ann
    forall ann. Int -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty Int
    size Doc ann -> Doc ann -> Doc ann
    forall ann. Doc ann -> Doc ann -> Doc ann
    <+> PublicNumber -> Doc ann
    forall ann. PublicNumber -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty PublicNumber
    n Doc ann -> Doc ann -> Doc ann
    forall ann. Doc ann -> Doc ann -> Doc ann
    <+> PublicNumber -> Doc ann
    forall ann. PublicNumber -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty PublicNumber
    e

    newtype ECDSA_PublicKey =
      ECDSA_PublicKey
        { ECDSA_PublicKey -> PublicKey
    unECDSA_PublicKey :: ECDSA.PublicKey
        }
      deriving (Typeable ECDSA_PublicKey
    Typeable ECDSA_PublicKey =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> ECDSA_PublicKey -> c ECDSA_PublicKey)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c ECDSA_PublicKey)
    -> (ECDSA_PublicKey -> Constr)
    -> (ECDSA_PublicKey -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PublicKey))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c ECDSA_PublicKey))
    -> ((forall b. Data b => b -> b)
        -> ECDSA_PublicKey -> ECDSA_PublicKey)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r)
    -> (forall u.
        (forall d. Data d => d -> u) -> ECDSA_PublicKey -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> ECDSA_PublicKey -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d)
        -> ECDSA_PublicKey -> m ECDSA_PublicKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> ECDSA_PublicKey -> m ECDSA_PublicKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> ECDSA_PublicKey -> m ECDSA_PublicKey)
    -> Data ECDSA_PublicKey
    ECDSA_PublicKey -> Constr
    ECDSA_PublicKey -> DataType
    (forall b. Data b => b -> b) -> ECDSA_PublicKey -> ECDSA_PublicKey
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u.
    Int -> (forall d. Data d => d -> u) -> ECDSA_PublicKey -> u
    forall u. (forall d. Data d => d -> u) -> ECDSA_PublicKey -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECDSA_PublicKey
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECDSA_PublicKey -> c ECDSA_PublicKey
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PublicKey)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECDSA_PublicKey)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECDSA_PublicKey -> c ECDSA_PublicKey
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECDSA_PublicKey -> c ECDSA_PublicKey
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECDSA_PublicKey
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECDSA_PublicKey
    $ctoConstr :: ECDSA_PublicKey -> Constr
    toConstr :: ECDSA_PublicKey -> Constr
    $cdataTypeOf :: ECDSA_PublicKey -> DataType
    dataTypeOf :: ECDSA_PublicKey -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PublicKey)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PublicKey)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECDSA_PublicKey)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECDSA_PublicKey)
    $cgmapT :: (forall b. Data b => b -> b) -> ECDSA_PublicKey -> ECDSA_PublicKey
    gmapT :: (forall b. Data b => b -> b) -> ECDSA_PublicKey -> ECDSA_PublicKey
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PublicKey -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> ECDSA_PublicKey -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> ECDSA_PublicKey -> [u]
    $cgmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> ECDSA_PublicKey -> u
    gmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> ECDSA_PublicKey -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PublicKey -> m ECDSA_PublicKey
    Data, ECDSA_PublicKey -> ECDSA_PublicKey -> Bool
    (ECDSA_PublicKey -> ECDSA_PublicKey -> Bool)
    -> (ECDSA_PublicKey -> ECDSA_PublicKey -> Bool)
    -> Eq ECDSA_PublicKey
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: ECDSA_PublicKey -> ECDSA_PublicKey -> Bool
    == :: ECDSA_PublicKey -> ECDSA_PublicKey -> Bool
    $c/= :: ECDSA_PublicKey -> ECDSA_PublicKey -> Bool
    /= :: ECDSA_PublicKey -> ECDSA_PublicKey -> Bool
    Eq, (forall x. ECDSA_PublicKey -> Rep ECDSA_PublicKey x)
    -> (forall x. Rep ECDSA_PublicKey x -> ECDSA_PublicKey)
    -> Generic ECDSA_PublicKey
    forall x. Rep ECDSA_PublicKey x -> ECDSA_PublicKey
    forall x. ECDSA_PublicKey -> Rep ECDSA_PublicKey x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. ECDSA_PublicKey -> Rep ECDSA_PublicKey x
    from :: forall x. ECDSA_PublicKey -> Rep ECDSA_PublicKey x
    $cto :: forall x. Rep ECDSA_PublicKey x -> ECDSA_PublicKey
    to :: forall x. Rep ECDSA_PublicKey x -> ECDSA_PublicKey
    Generic, Int -> ECDSA_PublicKey -> ShowS
    [ECDSA_PublicKey] -> ShowS
    ECDSA_PublicKey -> String
    (Int -> ECDSA_PublicKey -> ShowS)
    -> (ECDSA_PublicKey -> String)
    -> ([ECDSA_PublicKey] -> ShowS)
    -> Show ECDSA_PublicKey
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> ECDSA_PublicKey -> ShowS
    showsPrec :: Int -> ECDSA_PublicKey -> ShowS
    $cshow :: ECDSA_PublicKey -> String
    show :: ECDSA_PublicKey -> String
    $cshowList :: [ECDSA_PublicKey] -> ShowS
    showList :: [ECDSA_PublicKey] -> ShowS
    Show, Typeable)

    instance Ord ECDSA_PublicKey

    instance A.ToJSON ECDSA_PublicKey where
      toJSON :: ECDSA_PublicKey -> Value
    toJSON (ECDSA_PublicKey (ECDSA.PublicKey Curve
    curve PublicPoint
    q)) =
        (String, String) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (Curve -> String
    forall a. Show a => a -> String
    show Curve
    curve, PublicPoint -> String
    forall a. Show a => a -> String
    show PublicPoint
    q)

    instance Pretty ECDSA_PublicKey where
      pretty :: forall ann. ECDSA_PublicKey -> Doc ann
    pretty (ECDSA_PublicKey (ECDSA.PublicKey Curve
    curve PublicPoint
    q)) =
        (String, String) -> Doc ann
    forall ann. (String, String) -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty (Curve -> String
    forall a. Show a => a -> String
    show Curve
    curve, PublicPoint -> String
    forall a. Show a => a -> String
    show PublicPoint
    q)

    newtype DSA_PrivateKey =
      DSA_PrivateKey
        { DSA_PrivateKey -> PrivateKey
    unDSA_PrivateKey :: DSA.PrivateKey
        }
      deriving (Typeable DSA_PrivateKey
    Typeable DSA_PrivateKey =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> DSA_PrivateKey -> c DSA_PrivateKey)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c DSA_PrivateKey)
    -> (DSA_PrivateKey -> Constr)
    -> (DSA_PrivateKey -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c DSA_PrivateKey))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c DSA_PrivateKey))
    -> ((forall b. Data b => b -> b)
        -> DSA_PrivateKey -> DSA_PrivateKey)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r)
    -> (forall u.
        (forall d. Data d => d -> u) -> DSA_PrivateKey -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> DSA_PrivateKey -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d)
        -> DSA_PrivateKey -> m DSA_PrivateKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> DSA_PrivateKey -> m DSA_PrivateKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> DSA_PrivateKey -> m DSA_PrivateKey)
    -> Data DSA_PrivateKey
    DSA_PrivateKey -> Constr
    DSA_PrivateKey -> DataType
    (forall b. Data b => b -> b) -> DSA_PrivateKey -> DSA_PrivateKey
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u.
    Int -> (forall d. Data d => d -> u) -> DSA_PrivateKey -> u
    forall u. (forall d. Data d => d -> u) -> DSA_PrivateKey -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_PrivateKey
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_PrivateKey -> c DSA_PrivateKey
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_PrivateKey)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c DSA_PrivateKey)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_PrivateKey -> c DSA_PrivateKey
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_PrivateKey -> c DSA_PrivateKey
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_PrivateKey
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_PrivateKey
    $ctoConstr :: DSA_PrivateKey -> Constr
    toConstr :: DSA_PrivateKey -> Constr
    $cdataTypeOf :: DSA_PrivateKey -> DataType
    dataTypeOf :: DSA_PrivateKey -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_PrivateKey)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_PrivateKey)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c DSA_PrivateKey)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c DSA_PrivateKey)
    $cgmapT :: (forall b. Data b => b -> b) -> DSA_PrivateKey -> DSA_PrivateKey
    gmapT :: (forall b. Data b => b -> b) -> DSA_PrivateKey -> DSA_PrivateKey
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_PrivateKey -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> DSA_PrivateKey -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> DSA_PrivateKey -> [u]
    $cgmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> DSA_PrivateKey -> u
    gmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> DSA_PrivateKey -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> DSA_PrivateKey -> m DSA_PrivateKey
    Data, DSA_PrivateKey -> DSA_PrivateKey -> Bool
    (DSA_PrivateKey -> DSA_PrivateKey -> Bool)
    -> (DSA_PrivateKey -> DSA_PrivateKey -> Bool) -> Eq DSA_PrivateKey
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: DSA_PrivateKey -> DSA_PrivateKey -> Bool
    == :: DSA_PrivateKey -> DSA_PrivateKey -> Bool
    $c/= :: DSA_PrivateKey -> DSA_PrivateKey -> Bool
    /= :: DSA_PrivateKey -> DSA_PrivateKey -> Bool
    Eq, (forall x. DSA_PrivateKey -> Rep DSA_PrivateKey x)
    -> (forall x. Rep DSA_PrivateKey x -> DSA_PrivateKey)
    -> Generic DSA_PrivateKey
    forall x. Rep DSA_PrivateKey x -> DSA_PrivateKey
    forall x. DSA_PrivateKey -> Rep DSA_PrivateKey x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. DSA_PrivateKey -> Rep DSA_PrivateKey x
    from :: forall x. DSA_PrivateKey -> Rep DSA_PrivateKey x
    $cto :: forall x. Rep DSA_PrivateKey x -> DSA_PrivateKey
    to :: forall x. Rep DSA_PrivateKey x -> DSA_PrivateKey
    Generic, Int -> DSA_PrivateKey -> ShowS
    [DSA_PrivateKey] -> ShowS
    DSA_PrivateKey -> String
    (Int -> DSA_PrivateKey -> ShowS)
    -> (DSA_PrivateKey -> String)
    -> ([DSA_PrivateKey] -> ShowS)
    -> Show DSA_PrivateKey
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> DSA_PrivateKey -> ShowS
    showsPrec :: Int -> DSA_PrivateKey -> ShowS
    $cshow :: DSA_PrivateKey -> String
    show :: DSA_PrivateKey -> String
    $cshowList :: [DSA_PrivateKey] -> ShowS
    showList :: [DSA_PrivateKey] -> ShowS
    Show, Typeable)

    instance Ord DSA_PrivateKey

    instance A.ToJSON DSA_PrivateKey where
      toJSON :: DSA_PrivateKey -> Value
    toJSON (DSA_PrivateKey (DSA.PrivateKey Params
    p PublicNumber
    x)) = (DSA_Params, PublicNumber) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (Params -> DSA_Params
    DSA_Params Params
    p, PublicNumber
    x)

    instance Pretty DSA_PrivateKey where
      pretty :: forall ann. DSA_PrivateKey -> Doc ann
    pretty (DSA_PrivateKey (DSA.PrivateKey Params
    p PublicNumber
    x)) = (DSA_Params, PublicNumber) -> Doc ann
    forall ann. (DSA_Params, PublicNumber) -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty (Params -> DSA_Params
    DSA_Params Params
    p, PublicNumber
    x)

    newtype RSA_PrivateKey =
      RSA_PrivateKey
        { RSA_PrivateKey -> PrivateKey
    unRSA_PrivateKey :: RSA.PrivateKey
        }
      deriving (Typeable RSA_PrivateKey
    Typeable RSA_PrivateKey =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> RSA_PrivateKey -> c RSA_PrivateKey)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c RSA_PrivateKey)
    -> (RSA_PrivateKey -> Constr)
    -> (RSA_PrivateKey -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c RSA_PrivateKey))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c RSA_PrivateKey))
    -> ((forall b. Data b => b -> b)
        -> RSA_PrivateKey -> RSA_PrivateKey)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r)
    -> (forall u.
        (forall d. Data d => d -> u) -> RSA_PrivateKey -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> RSA_PrivateKey -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d)
        -> RSA_PrivateKey -> m RSA_PrivateKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> RSA_PrivateKey -> m RSA_PrivateKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> RSA_PrivateKey -> m RSA_PrivateKey)
    -> Data RSA_PrivateKey
    RSA_PrivateKey -> Constr
    RSA_PrivateKey -> DataType
    (forall b. Data b => b -> b) -> RSA_PrivateKey -> RSA_PrivateKey
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u.
    Int -> (forall d. Data d => d -> u) -> RSA_PrivateKey -> u
    forall u. (forall d. Data d => d -> u) -> RSA_PrivateKey -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c RSA_PrivateKey
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> RSA_PrivateKey -> c RSA_PrivateKey
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c RSA_PrivateKey)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c RSA_PrivateKey)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> RSA_PrivateKey -> c RSA_PrivateKey
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> RSA_PrivateKey -> c RSA_PrivateKey
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c RSA_PrivateKey
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c RSA_PrivateKey
    $ctoConstr :: RSA_PrivateKey -> Constr
    toConstr :: RSA_PrivateKey -> Constr
    $cdataTypeOf :: RSA_PrivateKey -> DataType
    dataTypeOf :: RSA_PrivateKey -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c RSA_PrivateKey)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c RSA_PrivateKey)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c RSA_PrivateKey)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c RSA_PrivateKey)
    $cgmapT :: (forall b. Data b => b -> b) -> RSA_PrivateKey -> RSA_PrivateKey
    gmapT :: (forall b. Data b => b -> b) -> RSA_PrivateKey -> RSA_PrivateKey
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> RSA_PrivateKey -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> RSA_PrivateKey -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> RSA_PrivateKey -> [u]
    $cgmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> RSA_PrivateKey -> u
    gmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> RSA_PrivateKey -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> RSA_PrivateKey -> m RSA_PrivateKey
    Data, RSA_PrivateKey -> RSA_PrivateKey -> Bool
    (RSA_PrivateKey -> RSA_PrivateKey -> Bool)
    -> (RSA_PrivateKey -> RSA_PrivateKey -> Bool) -> Eq RSA_PrivateKey
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: RSA_PrivateKey -> RSA_PrivateKey -> Bool
    == :: RSA_PrivateKey -> RSA_PrivateKey -> Bool
    $c/= :: RSA_PrivateKey -> RSA_PrivateKey -> Bool
    /= :: RSA_PrivateKey -> RSA_PrivateKey -> Bool
    Eq, (forall x. RSA_PrivateKey -> Rep RSA_PrivateKey x)
    -> (forall x. Rep RSA_PrivateKey x -> RSA_PrivateKey)
    -> Generic RSA_PrivateKey
    forall x. Rep RSA_PrivateKey x -> RSA_PrivateKey
    forall x. RSA_PrivateKey -> Rep RSA_PrivateKey x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. RSA_PrivateKey -> Rep RSA_PrivateKey x
    from :: forall x. RSA_PrivateKey -> Rep RSA_PrivateKey x
    $cto :: forall x. Rep RSA_PrivateKey x -> RSA_PrivateKey
    to :: forall x. Rep RSA_PrivateKey x -> RSA_PrivateKey
    Generic, Int -> RSA_PrivateKey -> ShowS
    [RSA_PrivateKey] -> ShowS
    RSA_PrivateKey -> String
    (Int -> RSA_PrivateKey -> ShowS)
    -> (RSA_PrivateKey -> String)
    -> ([RSA_PrivateKey] -> ShowS)
    -> Show RSA_PrivateKey
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> RSA_PrivateKey -> ShowS
    showsPrec :: Int -> RSA_PrivateKey -> ShowS
    $cshow :: RSA_PrivateKey -> String
    show :: RSA_PrivateKey -> String
    $cshowList :: [RSA_PrivateKey] -> ShowS
    showList :: [RSA_PrivateKey] -> ShowS
    Show, Typeable)

    instance Ord RSA_PrivateKey

    instance A.ToJSON RSA_PrivateKey where
      toJSON :: RSA_PrivateKey -> Value
    toJSON (RSA_PrivateKey (RSA.PrivateKey PublicKey
    pub PublicNumber
    d PublicNumber
    p PublicNumber
    q PublicNumber
    dP PublicNumber
    dQ PublicNumber
    qinv)) =
        (RSA_PublicKey, PublicNumber, PublicNumber, PublicNumber,
     PublicNumber, PublicNumber, PublicNumber)
    -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (PublicKey -> RSA_PublicKey
    RSA_PublicKey PublicKey
    pub, PublicNumber
    d, PublicNumber
    p, PublicNumber
    q, PublicNumber
    dP, PublicNumber
    dQ, PublicNumber
    qinv)

    instance Pretty RSA_PrivateKey where
      pretty :: forall ann. RSA_PrivateKey -> Doc ann
    pretty (RSA_PrivateKey (RSA.PrivateKey PublicKey
    pub PublicNumber
    d PublicNumber
    p PublicNumber
    q PublicNumber
    dP PublicNumber
    dQ PublicNumber
    qinv)) =
        RSA_PublicKey -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    forall ann. RSA_PublicKey -> Doc ann
    pretty (PublicKey -> RSA_PublicKey
    RSA_PublicKey PublicKey
    pub) Doc ann -> Doc ann -> Doc ann
    forall ann. Doc ann -> Doc ann -> Doc ann
    <+> [Doc ann] -> Doc ann
    forall ann. [Doc ann] -> Doc ann
    tupled ((PublicNumber -> Doc ann) -> [PublicNumber] -> [Doc ann]
    forall a b. (a -> b) -> [a] -> [b]
    map PublicNumber -> Doc ann
    forall ann. PublicNumber -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty [PublicNumber
    d, PublicNumber
    p, PublicNumber
    q, PublicNumber
    dP, PublicNumber
    dQ, PublicNumber
    qinv])

    newtype ECDSA_PrivateKey =
      ECDSA_PrivateKey
        { ECDSA_PrivateKey -> PrivateKey
    unECDSA_PrivateKey :: ECDSA.PrivateKey
        }
      deriving (Typeable ECDSA_PrivateKey
    Typeable ECDSA_PrivateKey =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> ECDSA_PrivateKey -> c ECDSA_PrivateKey)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c ECDSA_PrivateKey)
    -> (ECDSA_PrivateKey -> Constr)
    -> (ECDSA_PrivateKey -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PrivateKey))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c ECDSA_PrivateKey))
    -> ((forall b. Data b => b -> b)
        -> ECDSA_PrivateKey -> ECDSA_PrivateKey)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r)
    -> (forall u.
        (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d)
        -> ECDSA_PrivateKey -> m ECDSA_PrivateKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> ECDSA_PrivateKey -> m ECDSA_PrivateKey)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d)
        -> ECDSA_PrivateKey -> m ECDSA_PrivateKey)
    -> Data ECDSA_PrivateKey
    ECDSA_PrivateKey -> Constr
    ECDSA_PrivateKey -> DataType
    (forall b. Data b => b -> b)
    -> ECDSA_PrivateKey -> ECDSA_PrivateKey
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u.
    Int -> (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> u
    forall u. (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECDSA_PrivateKey
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECDSA_PrivateKey -> c ECDSA_PrivateKey
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PrivateKey)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECDSA_PrivateKey)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECDSA_PrivateKey -> c ECDSA_PrivateKey
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECDSA_PrivateKey -> c ECDSA_PrivateKey
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECDSA_PrivateKey
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECDSA_PrivateKey
    $ctoConstr :: ECDSA_PrivateKey -> Constr
    toConstr :: ECDSA_PrivateKey -> Constr
    $cdataTypeOf :: ECDSA_PrivateKey -> DataType
    dataTypeOf :: ECDSA_PrivateKey -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PrivateKey)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECDSA_PrivateKey)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECDSA_PrivateKey)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECDSA_PrivateKey)
    $cgmapT :: (forall b. Data b => b -> b)
    -> ECDSA_PrivateKey -> ECDSA_PrivateKey
    gmapT :: (forall b. Data b => b -> b)
    -> ECDSA_PrivateKey -> ECDSA_PrivateKey
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECDSA_PrivateKey -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> [u]
    $cgmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> u
    gmapQi :: forall u.
    Int -> (forall d. Data d => d -> u) -> ECDSA_PrivateKey -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d)
    -> ECDSA_PrivateKey -> m ECDSA_PrivateKey
    Data, ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool
    (ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool)
    -> (ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool)
    -> Eq ECDSA_PrivateKey
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool
    == :: ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool
    $c/= :: ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool
    /= :: ECDSA_PrivateKey -> ECDSA_PrivateKey -> Bool
    Eq, (forall x. ECDSA_PrivateKey -> Rep ECDSA_PrivateKey x)
    -> (forall x. Rep ECDSA_PrivateKey x -> ECDSA_PrivateKey)
    -> Generic ECDSA_PrivateKey
    forall x. Rep ECDSA_PrivateKey x -> ECDSA_PrivateKey
    forall x. ECDSA_PrivateKey -> Rep ECDSA_PrivateKey x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. ECDSA_PrivateKey -> Rep ECDSA_PrivateKey x
    from :: forall x. ECDSA_PrivateKey -> Rep ECDSA_PrivateKey x
    $cto :: forall x. Rep ECDSA_PrivateKey x -> ECDSA_PrivateKey
    to :: forall x. Rep ECDSA_PrivateKey x -> ECDSA_PrivateKey
    Generic, Int -> ECDSA_PrivateKey -> ShowS
    [ECDSA_PrivateKey] -> ShowS
    ECDSA_PrivateKey -> String
    (Int -> ECDSA_PrivateKey -> ShowS)
    -> (ECDSA_PrivateKey -> String)
    -> ([ECDSA_PrivateKey] -> ShowS)
    -> Show ECDSA_PrivateKey
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> ECDSA_PrivateKey -> ShowS
    showsPrec :: Int -> ECDSA_PrivateKey -> ShowS
    $cshow :: ECDSA_PrivateKey -> String
    show :: ECDSA_PrivateKey -> String
    $cshowList :: [ECDSA_PrivateKey] -> ShowS
    showList :: [ECDSA_PrivateKey] -> ShowS
    Show, Typeable)

    instance Ord ECDSA_PrivateKey

    instance A.ToJSON ECDSA_PrivateKey where
      toJSON :: ECDSA_PrivateKey -> Value
    toJSON (ECDSA_PrivateKey (ECDSA.PrivateKey Curve
    curve PublicNumber
    d)) =
        (String, String) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (Curve -> String
    forall a. Show a => a -> String
    show Curve
    curve, PublicNumber -> String
    forall a. Show a => a -> String
    show PublicNumber
    d)

    instance Pretty ECDSA_PrivateKey where
      pretty :: forall ann. ECDSA_PrivateKey -> Doc ann
    pretty (ECDSA_PrivateKey (ECDSA.PrivateKey Curve
    curve PublicNumber
    d)) =
        (String, String) -> Doc ann
    forall ann. (String, String) -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty (Curve -> String
    forall a. Show a => a -> String
    show Curve
    curve, PublicNumber -> String
    forall a. Show a => a -> String
    show PublicNumber
    d)

    newtype DSA_Params =
      DSA_Params
        { DSA_Params -> Params
    unDSA_Params :: DSA.Params
        }
      deriving (Typeable DSA_Params
    Typeable DSA_Params =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> DSA_Params -> c DSA_Params)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c DSA_Params)
    -> (DSA_Params -> Constr)
    -> (DSA_Params -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c DSA_Params))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c DSA_Params))
    -> ((forall b. Data b => b -> b) -> DSA_Params -> DSA_Params)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r)
    -> (forall u. (forall d. Data d => d -> u) -> DSA_Params -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> DSA_Params -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params)
    -> Data DSA_Params
    DSA_Params -> Constr
    DSA_Params -> DataType
    (forall b. Data b => b -> b) -> DSA_Params -> DSA_Params
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u. Int -> (forall d. Data d => d -> u) -> DSA_Params -> u
    forall u. (forall d. Data d => d -> u) -> DSA_Params -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_Params
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_Params -> c DSA_Params
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_Params)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c DSA_Params)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_Params -> c DSA_Params
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> DSA_Params -> c DSA_Params
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_Params
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c DSA_Params
    $ctoConstr :: DSA_Params -> Constr
    toConstr :: DSA_Params -> Constr
    $cdataTypeOf :: DSA_Params -> DataType
    dataTypeOf :: DSA_Params -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_Params)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c DSA_Params)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c DSA_Params)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c DSA_Params)
    $cgmapT :: (forall b. Data b => b -> b) -> DSA_Params -> DSA_Params
    gmapT :: (forall b. Data b => b -> b) -> DSA_Params -> DSA_Params
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> DSA_Params -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> DSA_Params -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> DSA_Params -> [u]
    $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> DSA_Params -> u
    gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> DSA_Params -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> DSA_Params -> m DSA_Params
    Data, DSA_Params -> DSA_Params -> Bool
    (DSA_Params -> DSA_Params -> Bool)
    -> (DSA_Params -> DSA_Params -> Bool) -> Eq DSA_Params
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: DSA_Params -> DSA_Params -> Bool
    == :: DSA_Params -> DSA_Params -> Bool
    $c/= :: DSA_Params -> DSA_Params -> Bool
    /= :: DSA_Params -> DSA_Params -> Bool
    Eq, (forall x. DSA_Params -> Rep DSA_Params x)
    -> (forall x. Rep DSA_Params x -> DSA_Params) -> Generic DSA_Params
    forall x. Rep DSA_Params x -> DSA_Params
    forall x. DSA_Params -> Rep DSA_Params x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. DSA_Params -> Rep DSA_Params x
    from :: forall x. DSA_Params -> Rep DSA_Params x
    $cto :: forall x. Rep DSA_Params x -> DSA_Params
    to :: forall x. Rep DSA_Params x -> DSA_Params
    Generic, Int -> DSA_Params -> ShowS
    [DSA_Params] -> ShowS
    DSA_Params -> String
    (Int -> DSA_Params -> ShowS)
    -> (DSA_Params -> String)
    -> ([DSA_Params] -> ShowS)
    -> Show DSA_Params
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> DSA_Params -> ShowS
    showsPrec :: Int -> DSA_Params -> ShowS
    $cshow :: DSA_Params -> String
    show :: DSA_Params -> String
    $cshowList :: [DSA_Params] -> ShowS
    showList :: [DSA_Params] -> ShowS
    Show, Typeable)

    instance A.ToJSON DSA_Params where
      toJSON :: DSA_Params -> Value
    toJSON (DSA_Params (DSA.Params PublicNumber
    p PublicNumber
    g PublicNumber
    q)) = (PublicNumber, PublicNumber, PublicNumber) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (PublicNumber
    p, PublicNumber
    g, PublicNumber
    q)

    instance Pretty DSA_Params where
      pretty :: forall ann. DSA_Params -> Doc ann
    pretty (DSA_Params (DSA.Params PublicNumber
    p PublicNumber
    g PublicNumber
    q)) = (PublicNumber, PublicNumber, PublicNumber) -> Doc ann
    forall ann. (PublicNumber, PublicNumber, PublicNumber) -> Doc ann
    forall a ann. Pretty a => a -> Doc ann
    pretty (PublicNumber
    p, PublicNumber
    g, PublicNumber
    q)

    instance Hashable DSA_Params where
      hashWithSalt :: Int -> DSA_Params -> Int
    hashWithSalt Int
    s (DSA_Params (DSA.Params PublicNumber
    p PublicNumber
    g PublicNumber
    q)) =
        Int
    s Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    p Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    g Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    q

    instance Hashable DSA_PublicKey where
      hashWithSalt :: Int -> DSA_PublicKey -> Int
    hashWithSalt Int
    s (DSA_PublicKey (DSA.PublicKey Params
    p PublicNumber
    y)) =
        Int
    s Int -> DSA_Params -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` Params -> DSA_Params
    DSA_Params Params
    p Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    y

    instance Hashable DSA_PrivateKey where
      hashWithSalt :: Int -> DSA_PrivateKey -> Int
    hashWithSalt Int
    s (DSA_PrivateKey (DSA.PrivateKey Params
    p PublicNumber
    x)) =
        Int
    s Int -> DSA_Params -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` Params -> DSA_Params
    DSA_Params Params
    p Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    x

    instance Hashable RSA_PublicKey where
      hashWithSalt :: Int -> RSA_PublicKey -> Int
    hashWithSalt Int
    s (RSA_PublicKey (RSA.PublicKey Int
    size PublicNumber
    n PublicNumber
    e)) =
        Int
    s Int -> Int -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` Int
    size Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    n Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    e

    instance Hashable RSA_PrivateKey where
      hashWithSalt :: Int -> RSA_PrivateKey -> Int
    hashWithSalt Int
    s (RSA_PrivateKey (RSA.PrivateKey PublicKey
    pub PublicNumber
    d PublicNumber
    p PublicNumber
    q PublicNumber
    dP PublicNumber
    dQ PublicNumber
    qinv)) =
        Int
    s Int -> RSA_PublicKey -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicKey -> RSA_PublicKey
    RSA_PublicKey PublicKey
    pub Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    d Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber
    p Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt`
        PublicNumber
    q Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt`
        PublicNumber
    dP Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt`
        PublicNumber
    dQ Int -> PublicNumber -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt`
        PublicNumber
    qinv

    instance Hashable ECDSA_PublicKey where
      hashWithSalt :: Int -> ECDSA_PublicKey -> Int
    hashWithSalt Int
    s (ECDSA_PublicKey (ECDSA.PublicKey Curve
    curve PublicPoint
    q)) =
        Int
    s Int -> String -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` Curve -> String
    forall a. Show a => a -> String
    show Curve
    curve Int -> String -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicPoint -> String
    forall a. Show a => a -> String
    show PublicPoint
    q -- FIXME: don't use show

    instance Hashable ECDSA_PrivateKey where
      hashWithSalt :: Int -> ECDSA_PrivateKey -> Int
    hashWithSalt Int
    s (ECDSA_PrivateKey (ECDSA.PrivateKey Curve
    curve PublicNumber
    d)) =
        Int
    s Int -> String -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` Curve -> String
    forall a. Show a => a -> String
    show Curve
    curve Int -> String -> Int
    forall a. Hashable a => Int -> a -> Int
    `hashWithSalt` PublicNumber -> String
    forall a. Show a => a -> String
    show PublicNumber
    d -- FIXME: don't use show

    newtype ECurvePoint =
      ECurvePoint
        { ECurvePoint -> PublicPoint
    unECurvepoint :: ECCT.Point
        }
      deriving (Typeable ECurvePoint
    Typeable ECurvePoint =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> ECurvePoint -> c ECurvePoint)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c ECurvePoint)
    -> (ECurvePoint -> Constr)
    -> (ECurvePoint -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c ECurvePoint))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e))
        -> Maybe (c ECurvePoint))
    -> ((forall b. Data b => b -> b) -> ECurvePoint -> ECurvePoint)
    -> (forall r r'.
        (r -> r' -> r)
        -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r)
    -> (forall r r'.
        (r' -> r -> r)
        -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r)
    -> (forall u. (forall d. Data d => d -> u) -> ECurvePoint -> [u])
    -> (forall u.
        Int -> (forall d. Data d => d -> u) -> ECurvePoint -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint)
    -> Data ECurvePoint
    ECurvePoint -> Constr
    ECurvePoint -> DataType
    (forall b. Data b => b -> b) -> ECurvePoint -> ECurvePoint
    forall a.
    Typeable a =>
    (forall (c :: * -> *).
     (forall d b. Data d => c (d -> b) -> d -> c b)
     -> (forall g. g -> c g) -> a -> c a)
    -> (forall (c :: * -> *).
        (forall b r. Data b => c (b -> r) -> c r)
        -> (forall r. r -> c r) -> Constr -> c a)
    -> (a -> Constr)
    -> (a -> DataType)
    -> (forall (t :: * -> *) (c :: * -> *).
        Typeable t =>
        (forall d. Data d => c (t d)) -> Maybe (c a))
    -> (forall (t :: * -> * -> *) (c :: * -> *).
        Typeable t =>
        (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c a))
    -> ((forall b. Data b => b -> b) -> a -> a)
    -> (forall r r'.
        (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall r r'.
        (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> a -> r)
    -> (forall u. (forall d. Data d => d -> u) -> a -> [u])
    -> (forall u. Int -> (forall d. Data d => d -> u) -> a -> u)
    -> (forall (m :: * -> *).
        Monad m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> (forall (m :: * -> *).
        MonadPlus m =>
        (forall d. Data d => d -> m d) -> a -> m a)
    -> Data a
    forall u. Int -> (forall d. Data d => d -> u) -> ECurvePoint -> u
    forall u. (forall d. Data d => d -> u) -> ECurvePoint -> [u]
    forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r
    forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r
    forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECurvePoint
    forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECurvePoint -> c ECurvePoint
    forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECurvePoint)
    forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECurvePoint)
    $cgfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECurvePoint -> c ECurvePoint
    gfoldl :: forall (c :: * -> *).
    (forall d b. Data d => c (d -> b) -> d -> c b)
    -> (forall g. g -> c g) -> ECurvePoint -> c ECurvePoint
    $cgunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECurvePoint
    gunfold :: forall (c :: * -> *).
    (forall b r. Data b => c (b -> r) -> c r)
    -> (forall r. r -> c r) -> Constr -> c ECurvePoint
    $ctoConstr :: ECurvePoint -> Constr
    toConstr :: ECurvePoint -> Constr
    $cdataTypeOf :: ECurvePoint -> DataType
    dataTypeOf :: ECurvePoint -> DataType
    $cdataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECurvePoint)
    dataCast1 :: forall (t :: * -> *) (c :: * -> *).
    Typeable t =>
    (forall d. Data d => c (t d)) -> Maybe (c ECurvePoint)
    $cdataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECurvePoint)
    dataCast2 :: forall (t :: * -> * -> *) (c :: * -> *).
    Typeable t =>
    (forall d e. (Data d, Data e) => c (t d e))
    -> Maybe (c ECurvePoint)
    $cgmapT :: (forall b. Data b => b -> b) -> ECurvePoint -> ECurvePoint
    gmapT :: (forall b. Data b => b -> b) -> ECurvePoint -> ECurvePoint
    $cgmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r
    gmapQl :: forall r r'.
    (r -> r' -> r)
    -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r
    $cgmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r
    gmapQr :: forall r r'.
    (r' -> r -> r)
    -> r -> (forall d. Data d => d -> r') -> ECurvePoint -> r
    $cgmapQ :: forall u. (forall d. Data d => d -> u) -> ECurvePoint -> [u]
    gmapQ :: forall u. (forall d. Data d => d -> u) -> ECurvePoint -> [u]
    $cgmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> ECurvePoint -> u
    gmapQi :: forall u. Int -> (forall d. Data d => d -> u) -> ECurvePoint -> u
    $cgmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    gmapM :: forall (m :: * -> *).
    Monad m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    $cgmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    gmapMp :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    $cgmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    gmapMo :: forall (m :: * -> *).
    MonadPlus m =>
    (forall d. Data d => d -> m d) -> ECurvePoint -> m ECurvePoint
    Data, ECurvePoint -> ECurvePoint -> Bool
    (ECurvePoint -> ECurvePoint -> Bool)
    -> (ECurvePoint -> ECurvePoint -> Bool) -> Eq ECurvePoint
    forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
    $c== :: ECurvePoint -> ECurvePoint -> Bool
    == :: ECurvePoint -> ECurvePoint -> Bool
    $c/= :: ECurvePoint -> ECurvePoint -> Bool
    /= :: ECurvePoint -> ECurvePoint -> Bool
    Eq, (forall x. ECurvePoint -> Rep ECurvePoint x)
    -> (forall x. Rep ECurvePoint x -> ECurvePoint)
    -> Generic ECurvePoint
    forall x. Rep ECurvePoint x -> ECurvePoint
    forall x. ECurvePoint -> Rep ECurvePoint x
    forall a.
    (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
    $cfrom :: forall x. ECurvePoint -> Rep ECurvePoint x
    from :: forall x. ECurvePoint -> Rep ECurvePoint x
    $cto :: forall x. Rep ECurvePoint x -> ECurvePoint
    to :: forall x. Rep ECurvePoint x -> ECurvePoint
    Generic, Int -> ECurvePoint -> ShowS
    [ECurvePoint] -> ShowS
    ECurvePoint -> String
    (Int -> ECurvePoint -> ShowS)
    -> (ECurvePoint -> String)
    -> ([ECurvePoint] -> ShowS)
    -> Show ECurvePoint
    forall a.
    (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
    $cshowsPrec :: Int -> ECurvePoint -> ShowS
    showsPrec :: Int -> ECurvePoint -> ShowS
    $cshow :: ECurvePoint -> String
    show :: ECurvePoint -> String
    $cshowList :: [ECurvePoint] -> ShowS
    showList :: [ECurvePoint] -> ShowS
    Show, Typeable)

    instance A.ToJSON ECurvePoint where
      toJSON :: ECurvePoint -> Value
    toJSON (ECurvePoint (ECCT.Point PublicNumber
    x PublicNumber
    y)) = (PublicNumber, PublicNumber) -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON (PublicNumber
    x, PublicNumber
    y)
      toJSON (ECurvePoint PublicPoint
    ECCT.PointO) = String -> Value
    forall a. ToJSON a => a -> Value
    A.toJSON String
    "point at infinity"

    instance A.FromJSON ECurvePoint where
      parseJSON :: Value -> Parser ECurvePoint
    parseJSON (A.Object Object
    v) = String -> Parser ECurvePoint
    forall a. HasCallStack => String -> a
    error String
    "FIXME: whatsit"
      parseJSON Value
    _ = Parser ECurvePoint
    forall a. Parser a
    forall (m :: * -> *) a. MonadPlus m => m a
    mzero