warp-tls-3.0.1: HTTP over SSL/TLS support for Warp via the TLS package

Safe HaskellNone

Network.Wai.Handler.WarpTLS

Contents

Description

HTTP over SSL/TLS support for Warp via the TLS package.

Synopsis

Settings

certFile :: TLSSettings -> FilePathSource

File containing the certificate.

keyFile :: TLSSettings -> FilePathSource

onInsecure :: TLSSettings -> OnInsecureSource

Do we allow insecure connections with this server as well? Default is a simple text response stating that a secure connection is required.

Since 1.4.0

tlsLogging :: TLSSettings -> LoggingSource

The level of logging to turn on.

Default: defaultLogging.

Since 1.4.0

tlsAllowedVersions :: TLSSettings -> [Version]Source

The TLS versions this server accepts.

Default: '[TLS.TLS10,TLS.TLS11,TLS.TLS12]'.

Since 1.4.2

tlsCiphers :: TLSSettings -> [Cipher]Source

The TLS ciphers this server accepts.

Default: '[TLSExtra.cipher_AES128_SHA1, TLSExtra.cipher_AES256_SHA1, TLSEtra.cipher_RC4_128_MD5, TLSExtra.cipher_RC4_128_SHA1]'

Since 1.4.2

defaultTlsSettings :: TLSSettingsSource

Default TLSSettings. Use this to create TLSSettings with the field record name.

tlsSettingsSource

Arguments

:: FilePath

Certificate file

-> FilePath

Key file

-> TLSSettings 

A smart constructor for TLSSettings.

tlsSettingsMemorySource

Arguments

:: ByteString

Certificate bytes

-> ByteString

Key bytes

-> TLSSettings 

A smart constructor for TLSSettings, but uses in-memory representations of the certificate and key

Since 3.0.1

data OnInsecure Source

An action when a plain HTTP comes to HTTP over TLS/SSL port.

Constructors

DenyInsecure ByteString 
AllowInsecure 

Runner

runTLSSocket :: TLSSettings -> Settings -> Socket -> Application -> IO ()Source

Running Application with TLSSettings and Settings using specified Socket.

Exception