neko-obfs-0.1.0.2: src/Type.hs
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE OverloadedStrings #-}
module Type where
import Control.Lens
import Data.Text (Text)
data Role = Local | Remote | Both
deriving (Show, Eq)
data Config = Config
{
_localHost :: Text
, _localPort :: Integer
, _remoteHost :: Text
, _remotePort :: Integer
, _forwardHost :: Text
, _forwardPort :: Integer
, _role :: Role
, _randomnessInBytes :: Integer
, _timeoutInSeconds :: Integer
, _debug :: Bool
, _mtu :: Integer
}
deriving (Show, Eq)
makeLenses ''Config
defaultConfig = Config
{
_localHost = "127.0.0.1"
, _localPort = 1080
, _remoteHost = "127.0.0.1"
, _remotePort = 13148
, _forwardHost = "127.0.0.1"
, _forwardPort = 1080
, _role = Local
, _randomnessInBytes = 256
, _timeoutInSeconds = 3600
, _debug = False
, _mtu = 4096
}