tls-0.3.1: TLS/SSL protocol native implementation (Server and Client)ContentsIndex
Network.TLS.Struct
Portabilityunknown
Stabilityexperimental
MaintainerVincent Hanquez <vincent@snarc.org>
Description
the Struct module contains all definitions and values of the TLS protocol
Documentation
type Bytes = ByteString
data Version
Constructors
SSL2
SSL3
TLS10
TLS11
TLS12
show/hide Instances
data ConnectionEnd
Constructors
ConnectionServer
ConnectionClient
show/hide Instances
data CipherType
Constructors
CipherStream
CipherBlock
CipherAEAD
show/hide Instances
data CipherData
Constructors
CipherData
cipherDataContent :: Bytes
cipherDataMAC :: Maybe Bytes
cipherDataPadding :: Maybe Bytes
show/hide Instances
type Extension = (Word16, [Word8])
newtype EncryptedData
Constructors
EncryptedData ByteString
show/hide Instances
data CertificateType
Constructors
CertificateType_RSA_Sign
CertificateType_DSS_Sign
CertificateType_RSA_Fixed_DH
CertificateType_DSS_Fixed_DH
CertificateType_RSA_Ephemeral_dh
CertificateType_DSS_Ephemeral_dh
CertificateType_fortezza_dms
CertificateType_Unknown Word8
show/hide Instances
data HashAlgorithm
Constructors
HashNone
HashMD5
HashSHA1
HashSHA224
HashSHA256
HashSHA384
HashSHA512
HashOther Word8
show/hide Instances
data SignatureAlgorithm
Constructors
SignatureAnonymous
SignatureRSA
SignatureDSS
SignatureECDSA
SignatureOther Word8
show/hide Instances
data ProtocolType
Constructors
ProtocolType_ChangeCipherSpec
ProtocolType_Alert
ProtocolType_Handshake
ProtocolType_AppData
show/hide Instances
data TLSError
Constructors
Error_Misc String
Error_Certificate String
Error_Digest ([Word8], [Word8])
Error_Packet String
Error_Packet_Size_Mismatch (Int, Int)
Error_Packet_unexpected String String
Error_Internal_Packet_Remaining Int
Error_Internal_Packet_ByteProcessed Int Int Int
Error_Unknown_Version Word8 Word8
Error_Unknown_Type String
show/hide Instances
data ServerDHParams
Constructors
ServerDHParams
dh_p :: Integerprime modulus
dh_g :: Integergenerator
dh_Ys :: Integerpublic value (g^X mod p)
show/hide Instances
data ServerRSAParams
Constructors
ServerRSAParams
rsa_modulus :: Integer
rsa_exponent :: Integer
show/hide Instances
data ServerKeyXchgAlgorithmData
Constructors
SKX_DH_Anon ServerDHParams
SKX_DHE_DSS ServerDHParams [Word8]
SKX_DHE_RSA ServerDHParams [Word8]
SKX_RSA (Maybe ServerRSAParams)
SKX_DH_DSS (Maybe ServerRSAParams)
SKX_DH_RSA (Maybe ServerRSAParams)
show/hide Instances
data Packet
Constructors
Handshake Handshake
Alert (AlertLevel, AlertDescription)
ChangeCipherSpec
AppData ByteString
show/hide Instances
data Header
Constructors
Header ProtocolType Version Word16
show/hide Instances
newtype ServerRandom
Constructors
ServerRandom Bytes
show/hide Instances
newtype ClientRandom
Constructors
ClientRandom Bytes
show/hide Instances
newtype ClientKeyData
Constructors
ClientKeyData Bytes
show/hide Instances
serverRandom :: Bytes -> Maybe ServerRandom
clientRandom :: Bytes -> Maybe ClientRandom
type FinishedData = [Word8]
newtype Session
Constructors
Session (Maybe Bytes)
show/hide Instances
data AlertLevel
Constructors
AlertLevel_Warning
AlertLevel_Fatal
show/hide Instances
data AlertDescription
Constructors
CloseNotify
UnexpectedMessage
BadRecordMac
DecryptionFailed
RecordOverflow
DecompressionFailure
HandshakeFailure
BadCertificate
UnsupportedCertificate
CertificateRevoked
CertificateExpired
CertificateUnknown
IllegalParameter
UnknownCa
AccessDenied
DecodeError
DecryptError
ExportRestriction
ProtocolVersion
InsufficientSecurity
InternalError
UserCanceled
NoRenegotiation
show/hide Instances
data HandshakeType
Constructors
HandshakeType_HelloRequest
HandshakeType_ClientHello
HandshakeType_ServerHello
HandshakeType_Certificate
HandshakeType_ServerKeyXchg
HandshakeType_CertRequest
HandshakeType_ServerHelloDone
HandshakeType_CertVerify
HandshakeType_ClientKeyXchg
HandshakeType_Finished
show/hide Instances
data Handshake
Constructors
ClientHello !Version !ClientRandom !Session ![CipherID] ![CompressionID] (Maybe [Extension])
ServerHello !Version !ServerRandom !Session !CipherID !CompressionID (Maybe [Extension])
Certificates [Certificate]
HelloRequest
ServerHelloDone
ClientKeyXchg Version ClientKeyData
ServerKeyXchg ServerKeyXchgAlgorithmData
CertRequest [CertificateType] (Maybe [(HashAlgorithm, SignatureAlgorithm)]) [Word8]
CertVerify [Word8]
Finished FinishedData
show/hide Instances
numericalVer :: Version -> (Word8, Word8)
verOfNum :: (Word8, Word8) -> Maybe Version
class TypeValuable a where
Methods
valOfType :: a -> Word8
valToType :: Word8 -> Maybe a
show/hide Instances
packetType :: Packet -> ProtocolType
typeOfHandshake :: Handshake -> HandshakeType
Produced by Haddock version 2.7.2