gophish: github.com/gophish/gophish/config Index | Files

package config

import "github.com/gophish/gophish/config"

Package config implements a global configuration to be used with gophish.

Index

Package Files

config.go doc.go

Constants

const ServerName = "gophish"

ServerName is the server type that is returned in the transparency response.

Variables

var Version = ""

Version contains the current gophish version

type AdminServer Uses

type AdminServer struct {
    ListenURL            string   `json:"listen_url"`
    UseTLS               bool     `json:"use_tls"`
    CertPath             string   `json:"cert_path"`
    KeyPath              string   `json:"key_path"`
    CSRFKey              string   `json:"csrf_key"`
    AllowedInternalHosts []string `json:"allowed_internal_hosts"`
}

AdminServer represents the Admin server configuration details

type Config Uses

type Config struct {
    AdminConf      AdminServer `json:"admin_server"`
    PhishConf      PhishServer `json:"phish_server"`
    DBName         string      `json:"db_name"`
    DBPath         string      `json:"db_path"`
    DBSSLCaPath    string      `json:"db_sslca_path"`
    MigrationsPath string      `json:"migrations_prefix"`
    TestFlag       bool        `json:"test_flag"`
    ContactAddress string      `json:"contact_address"`
    Logging        *log.Config `json:"logging"`
}

Config represents the configuration information.

func LoadConfig Uses

func LoadConfig(filepath string) (*Config, error)

LoadConfig loads the configuration from the specified filepath

type PhishServer Uses

type PhishServer struct {
    ListenURL string `json:"listen_url"`
    UseTLS    bool   `json:"use_tls"`
    CertPath  string `json:"cert_path"`
    KeyPath   string `json:"key_path"`
}

PhishServer represents the Phish server configuration details

Package config imports 3 packages (graph) and is imported by 39 packages. Updated 2020-08-20. Refresh now. Tools for package owners.