neko-obfs-0.1.0.0: src/Type.hs
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE OverloadedStrings #-}
module Type where
import Control.Lens
import Data.Text (Text)
data Role = Local | Remote
deriving (Show, Eq)
data Config = Config
{
_localHost :: Text
, _localPort :: Integer
, _remoteHost :: Text
, _remotePort :: Integer
, _forwardHost :: Text
, _forwardPort :: Integer
, _role :: Role
, _bound :: Integer
, _randomness :: Integer
, _timeoutInSeconds :: 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
, _bound = 1024
, _randomness = 300
, _timeoutInSeconds = 3600
}