Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/MHSanaei/3x-ui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkonstpic <156318483+konstpic@users.noreply.github.com>2025-09-28 22:00:16 +0300
committermhsanaei <ho3ein.sanaei@gmail.com>2025-09-28 22:04:54 +0300
commit28a17a80ec0c4a0f82e8acfca351651d762b3ec9 (patch)
tree7902b7b4cba04bce816ad17c9490f7228574a096 /web/entity/entity.go
parent30565833889171afe5c934f97bc0e767534e8310 (diff)
feat: add ldap component (#3568)
* add ldap component * fix: fix russian comments, tls cert verify default true * feat: remove replaces go mod for local dev
Diffstat (limited to 'web/entity/entity.go')
-rw-r--r--web/entity/entity.go26
1 files changed, 25 insertions, 1 deletions
diff --git a/web/entity/entity.go b/web/entity/entity.go
index adb60972..de054e2b 100644
--- a/web/entity/entity.go
+++ b/web/entity/entity.go
@@ -74,7 +74,31 @@ type AllSetting struct {
SubJsonFragment string `json:"subJsonFragment" form:"subJsonFragment"` // JSON subscription fragment configuration
SubJsonNoises string `json:"subJsonNoises" form:"subJsonNoises"` // JSON subscription noise configuration
SubJsonMux string `json:"subJsonMux" form:"subJsonMux"` // JSON subscription mux configuration
- SubJsonRules string `json:"subJsonRules" form:"subJsonRules"` // JSON subscription routing rules
+ SubJsonRules string `json:"subJsonRules" form:"subJsonRules"`
+
+ // LDAP settings
+ LdapEnable bool `json:"ldapEnable" form:"ldapEnable"`
+ LdapHost string `json:"ldapHost" form:"ldapHost"`
+ LdapPort int `json:"ldapPort" form:"ldapPort"`
+ LdapUseTLS bool `json:"ldapUseTLS" form:"ldapUseTLS"`
+ LdapBindDN string `json:"ldapBindDN" form:"ldapBindDN"`
+ LdapPassword string `json:"ldapPassword" form:"ldapPassword"`
+ LdapBaseDN string `json:"ldapBaseDN" form:"ldapBaseDN"`
+ LdapUserFilter string `json:"ldapUserFilter" form:"ldapUserFilter"`
+ LdapUserAttr string `json:"ldapUserAttr" form:"ldapUserAttr"` // e.g., mail or uid
+ LdapVlessField string `json:"ldapVlessField" form:"ldapVlessField"`
+ LdapSyncCron string `json:"ldapSyncCron" form:"ldapSyncCron"`
+ // Generic flag configuration
+ LdapFlagField string `json:"ldapFlagField" form:"ldapFlagField"`
+ LdapTruthyValues string `json:"ldapTruthyValues" form:"ldapTruthyValues"`
+ LdapInvertFlag bool `json:"ldapInvertFlag" form:"ldapInvertFlag"`
+ LdapInboundTags string `json:"ldapInboundTags" form:"ldapInboundTags"`
+ LdapAutoCreate bool `json:"ldapAutoCreate" form:"ldapAutoCreate"`
+ LdapAutoDelete bool `json:"ldapAutoDelete" form:"ldapAutoDelete"`
+ LdapDefaultTotalGB int `json:"ldapDefaultTotalGB" form:"ldapDefaultTotalGB"`
+ LdapDefaultExpiryDays int `json:"ldapDefaultExpiryDays" form:"ldapDefaultExpiryDays"`
+ LdapDefaultLimitIP int `json:"ldapDefaultLimitIP" form:"ldapDefaultLimitIP"`
+ // JSON subscription routing rules
}
// CheckValid validates all settings in the AllSetting struct, checking IP addresses, ports, SSL certificates, and other configuration values.