| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Simplex.FileTransfer.Transport
Documentation
xftpClientHandshakeStub :: c 'TClient -> Maybe KeyPairX25519 -> KeyHash -> VersionRangeXFTP -> Bool -> Maybe (ServiceCredentials, KeyPairEd25519) -> ExceptT TransportError IO (THandle XFTPVersion c 'TClient) Source #
xftpALPNv1 :: ALPN Source #
data XFTPClientHandshake Source #
Constructors
| XFTPClientHandshake | |
Fields
| |
Instances
| Encoding XFTPClientHandshake Source # | |
Defined in Simplex.FileTransfer.Transport Methods smpEncode :: XFTPClientHandshake -> ByteString Source # smpDecode :: ByteString -> Either String XFTPClientHandshake Source # smpP :: Parser XFTPClientHandshake Source # | |
data XFTPServerHandshake Source #
Constructors
| XFTPServerHandshake | |
Fields
| |
Instances
| Encoding XFTPServerHandshake Source # | |
Defined in Simplex.FileTransfer.Transport Methods smpEncode :: XFTPServerHandshake -> ByteString Source # smpDecode :: ByteString -> Either String XFTPServerHandshake Source # smpP :: Parser XFTPServerHandshake Source # | |
data XFTPClientHello Source #
Constructors
| XFTPClientHello | |
Fields
| |
Instances
| Encoding XFTPClientHello Source # | |
Defined in Simplex.FileTransfer.Transport Methods smpEncode :: XFTPClientHello -> ByteString Source # smpDecode :: ByteString -> Either String XFTPClientHello Source # smpP :: Parser XFTPClientHello Source # | |
type THandleXFTP c p = THandle XFTPVersion c p Source #
type THandleParamsXFTP p = THandleParams XFTPVersion p Source #
type VersionXFTP = Version XFTPVersion Source #
data XFTPVersion Source #
Instances
pattern VersionXFTP :: Word16 -> VersionXFTP Source #
data XFTPErrorType Source #
Constructors
| BLOCK | incorrect block format, encoding or signature size |
| SESSION | incorrect SMP session ID (TLS Finished message / tls-unique binding RFC5929) |
| HANDSHAKE | incorrect handshake command |
| CMD | SMP command is unknown or has invalid syntax |
Fields | |
| AUTH | command authorization error - bad signature or non-existing SMP queue |
| BLOCKED | command with the entity that was blocked |
Fields | |
| SIZE | incorrent file size |
| QUOTA | storage quota exceeded |
| DIGEST | incorrent file digest |
| CRYPTO | file encryption/decryption failed |
| NO_FILE | no expected file body in request/response or no file on the server |
| HAS_FILE | unexpected file body |
| FILE_IO | file IO error |
| TIMEOUT | file sending or receiving timeout |
| INTERNAL | internal server error |
| DUPLICATE_ | used internally, never returned by the server (to be removed) |
Instances
data XFTPRcvChunkSpec Source #
Constructors
| XFTPRcvChunkSpec | |
Fields
| |
Instances
| Show XFTPRcvChunkSpec Source # | |
Defined in Simplex.FileTransfer.Transport Methods showsPrec :: Int -> XFTPRcvChunkSpec -> ShowS show :: XFTPRcvChunkSpec -> String showList :: [XFTPRcvChunkSpec] -> ShowS | |
data ReceiveFileError Source #
receiveFile :: (Int -> IO ByteString) -> XFTPRcvChunkSpec -> ExceptT XFTPErrorType IO () Source #
sendEncFile :: Handle -> (Builder -> IO ()) -> SbState -> Word32 -> IO () Source #
receiveEncFile :: (Int -> IO ByteString) -> SbState -> XFTPRcvChunkSpec -> ExceptT XFTPErrorType IO () Source #
receiveSbFile :: (Int -> IO ByteString) -> Handle -> SbState -> Word32 -> IO (Either ReceiveFileError ()) Source #