| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Simplex.Messaging.Notifications.Transport
Synopsis
- ntfBlockSize :: Int
- data NTFVersion
- type VersionNTF = Version NTFVersion
- type VersionRangeNTF = VersionRange NTFVersion
- pattern VersionNTF :: Word16 -> VersionNTF
- initialNTFVersion :: VersionNTF
- authBatchCmdsNTFVersion :: VersionNTF
- invalidReasonNTFVersion :: VersionNTF
- currentClientNTFVersion :: VersionNTF
- currentServerNTFVersion :: VersionNTF
- supportedClientNTFVRange :: VersionRangeNTF
- legacyServerNTFVRange :: VersionRangeNTF
- supportedServerNTFVRange :: VersionRangeNTF
- alpnSupportedNTFHandshakes :: [ALPN]
- type THandleNTF (c :: TransportPeer -> Type) (p :: TransportPeer) = THandle NTFVersion c p
- data NtfServerHandshake = NtfServerHandshake {
- ntfVersionRange :: VersionRangeNTF
- sessionId :: SessionId
- authPubKey :: Maybe (SignedExact PubKey)
- data NtfClientHandshake = NtfClientHandshake {}
- encodeAuthEncryptCmds :: Encoding a => VersionNTF -> Maybe a -> ByteString
- authEncryptCmdsP :: VersionNTF -> Parser a -> Parser (Maybe a)
- ntfServerHandshake :: Transport c => APrivateSignKey -> c 'TServer -> KeyPairX25519 -> KeyHash -> VersionRangeNTF -> ExceptT TransportError IO (THandleNTF c 'TServer)
- ntfClientHandshake :: Transport c => c 'TClient -> KeyHash -> VersionRangeNTF -> Bool -> Maybe (ServiceCredentials, KeyPairEd25519) -> ExceptT TransportError IO (THandleNTF c 'TClient)
- ntfThHandleServer :: forall (c :: TransportPeer -> Type). THandleNTF c 'TServer -> VersionNTF -> VersionRangeNTF -> PrivateKeyX25519 -> THandleNTF c 'TServer
- ntfThHandleClient :: forall (c :: TransportPeer -> Type). THandleNTF c 'TClient -> VersionNTF -> VersionRangeNTF -> Maybe (PublicKeyX25519, CertChainPubKey) -> THandleNTF c 'TClient
- ntfThHandle_ :: forall (c :: TransportPeer -> Type) (p :: TransportPeer). THandleNTF c p -> VersionNTF -> VersionRangeNTF -> Maybe (THandleAuth p) -> THandleNTF c p
- ntfTHandle :: forall c (p :: TransportPeer). Transport c => c p -> THandleNTF c p
Documentation
ntfBlockSize :: Int Source #
data NTFVersion Source #
Instances
type VersionNTF = Version NTFVersion Source #
type VersionRangeNTF = VersionRange NTFVersion Source #
pattern VersionNTF :: Word16 -> VersionNTF Source #
type THandleNTF (c :: TransportPeer -> Type) (p :: TransportPeer) = THandle NTFVersion c p Source #
data NtfServerHandshake Source #
Constructors
| NtfServerHandshake | |
Fields
| |
Instances
| Encoding NtfServerHandshake Source # | |
Defined in Simplex.Messaging.Notifications.Transport Methods smpEncode :: NtfServerHandshake -> ByteString Source # smpDecode :: ByteString -> Either String NtfServerHandshake Source # smpP :: Parser NtfServerHandshake Source # | |
data NtfClientHandshake Source #
Constructors
| NtfClientHandshake | |
Fields
| |
Instances
| Encoding NtfClientHandshake Source # | |
Defined in Simplex.Messaging.Notifications.Transport Methods smpEncode :: NtfClientHandshake -> ByteString Source # smpDecode :: ByteString -> Either String NtfClientHandshake Source # smpP :: Parser NtfClientHandshake Source # | |
encodeAuthEncryptCmds :: Encoding a => VersionNTF -> Maybe a -> ByteString Source #
authEncryptCmdsP :: VersionNTF -> Parser a -> Parser (Maybe a) Source #
ntfServerHandshake :: Transport c => APrivateSignKey -> c 'TServer -> KeyPairX25519 -> KeyHash -> VersionRangeNTF -> ExceptT TransportError IO (THandleNTF c 'TServer) Source #
Notifcations server transport handshake.
ntfClientHandshake :: Transport c => c 'TClient -> KeyHash -> VersionRangeNTF -> Bool -> Maybe (ServiceCredentials, KeyPairEd25519) -> ExceptT TransportError IO (THandleNTF c 'TClient) Source #
Notifcations server client transport handshake.
ntfThHandleServer :: forall (c :: TransportPeer -> Type). THandleNTF c 'TServer -> VersionNTF -> VersionRangeNTF -> PrivateKeyX25519 -> THandleNTF c 'TServer Source #
ntfThHandleClient :: forall (c :: TransportPeer -> Type). THandleNTF c 'TClient -> VersionNTF -> VersionRangeNTF -> Maybe (PublicKeyX25519, CertChainPubKey) -> THandleNTF c 'TClient Source #
ntfThHandle_ :: forall (c :: TransportPeer -> Type) (p :: TransportPeer). THandleNTF c p -> VersionNTF -> VersionRangeNTF -> Maybe (THandleAuth p) -> THandleNTF c p Source #
ntfTHandle :: forall c (p :: TransportPeer). Transport c => c p -> THandleNTF c p Source #