mirror of
https://github.com/phishingclub/phishingclub.git
synced 2026-02-12 08:02:44 +00:00
fixed remove legacy admin IP blocking config field
Signed-off-by: Ronni Skansing <rskansing@gmail.com>
This commit is contained in:
@@ -16,6 +16,5 @@
|
||||
"database": {
|
||||
"engine": "sqlite3",
|
||||
"dsn": "file:/app/.dev/db.sqlite3"
|
||||
},
|
||||
"ip_allow_list": []
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,6 +20,5 @@
|
||||
"log": {
|
||||
"path": "",
|
||||
"errorPath": ""
|
||||
},
|
||||
"ip_allow_list": []
|
||||
}
|
||||
}
|
||||
|
||||
@@ -98,12 +98,11 @@ type (
|
||||
|
||||
// AdministrationServer ConfigDTO administration
|
||||
AdministrationServer struct {
|
||||
TLSHost string `json:"tls_host"`
|
||||
TLSAuto bool `json:"tls_auto"`
|
||||
TLSCertPath string `json:"tls_cert_path"`
|
||||
TLSKeyPath string `json:"tls_key_path"`
|
||||
Address string `json:"address"`
|
||||
AllowList []string `json:"ip_allow_list"`
|
||||
TLSHost string `json:"tls_host"`
|
||||
TLSAuto bool `json:"tls_auto"`
|
||||
TLSCertPath string `json:"tls_cert_path"`
|
||||
TLSKeyPath string `json:"tls_key_path"`
|
||||
Address string `json:"address"`
|
||||
}
|
||||
|
||||
// PhishingServer ConfigDTO phishing
|
||||
@@ -471,8 +470,6 @@ func FromDTO(dto *ConfigDTO) (*Config, error) {
|
||||
|
||||
// ToDTO converts a *Config to a *ConfigDTO
|
||||
func (c *Config) ToDTO() *ConfigDTO {
|
||||
allowList := make([]string, 0)
|
||||
|
||||
return &ConfigDTO{
|
||||
ACME: ACME{
|
||||
Email: c.acme.Email,
|
||||
@@ -483,7 +480,6 @@ func (c *Config) ToDTO() *ConfigDTO {
|
||||
TLSCertPath: c.TLSCertPath(),
|
||||
TLSKeyPath: c.TLSKeyPath(),
|
||||
Address: c.AdminNetAddress(),
|
||||
AllowList: allowList,
|
||||
},
|
||||
PhishingServer: PhishingServer{
|
||||
Http: c.phishingHTTPNetAddress.String(),
|
||||
|
||||
@@ -7,8 +7,7 @@
|
||||
"tls_auto": false,
|
||||
"tls_cert_path": "/app/data/certs/admin/public.pem",
|
||||
"tls_key_path": "/app/data/certs/admin/private.pem",
|
||||
"address": "0.0.0.0:8000",
|
||||
"ip_allow_list": []
|
||||
"address": "0.0.0.0:8000"
|
||||
},
|
||||
"phishing": {
|
||||
"http": "0.0.0.0:8080",
|
||||
|
||||
@@ -15,8 +15,7 @@ if [ ! -f /app/config/config.json ]; then
|
||||
"tls_auto": false,
|
||||
"tls_cert_path": "/app/config/certs/admin/public.pem",
|
||||
"tls_key_path": "/app/config/certs/admin/private.pem",
|
||||
"address": "0.0.0.0:8000",
|
||||
"ip_allow_list": []
|
||||
"address": "0.0.0.0:8000"
|
||||
},
|
||||
"phishing": {
|
||||
"http": "0.0.0.0:8080",
|
||||
|
||||
Reference in New Issue
Block a user