Maintainer | John Galt <jgalt@centromere.net> |
---|---|
Stability | experimental |
Portability | POSIX |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Synopsis
- data InspectionError
- type ErrorPosition = (Int, Int)
- validateHandshakePattern :: HandshakePattern -> [InspectionError]
Types
data InspectionError Source #
Represents a single error associated with a pattern.
InitMultipleETokens
,InitMultipleSTokens
,RespMultipleETokens
,RespMultipleSTokens
-- multiplee
/s
tokens were encountered for a message originating with the initiator/responder.InitSecretNotRandom
,RespSecretNotRandom
-- From the protocol:
After performing a DH between a remote public key and any local private key that is not an ephemeral private key, the local party must not send any encrypted data (i.e. must not call ENCRYPT()) unless it has also performed a DH between an ephemeral private key and the remote public key.
DHInPreMsg
-- A DH token (such asee
ores
) was found in the pre-message portion of the handshake.PSKInPreMsg
-- Apsk
token was found in the pre-message portion of the handshake.PSKWithoutEToken
-- Apsk
token was used before ane
token was encountered.
Instances
Show InspectionError Source # | |
Defined in Crypto.Noise.Internal.Handshake.Validation showsPrec :: Int -> InspectionError -> ShowS # show :: InspectionError -> String # showList :: [InspectionError] -> ShowS # |
type ErrorPosition = (Int, Int) Source #
(message number, token number)
Represents the location within the pattern at which an error resides, starting with zero.
Functions
validateHandshakePattern :: HandshakePattern -> [InspectionError] Source #
Validates a HandshakePattern
according to the rules defined in section
7.1 and 9.3 of the protocol. If no violations are found, the result will be
an empty list.