Settings in groups; the log on its own page
Settings is grouped into Access (users, sign-in, iOS app and API tokens), Web interface (address and HTTPS, Decoy), Logs & history and Upkeep (updates, backup). Session length moved to Sign-in and no longer asks for a restart. Log level, log size and traffic history share one card; the country lookup is its own switch. Each card says how it saves. The log viewer moved to a new Log page in the sidebar, with a filter for changes only, and the Dashboard's Log link opens it.
This commit is contained in:
@@ -1195,6 +1195,17 @@ func TestMFA(t *testing.T) {
|
||||
c3("POST", "/auth/login/recovery", map[string]string{"ticket": ticket, "code": codes[0].(string)}, 401)
|
||||
c3("POST", "/auth/login/recovery", map[string]string{"ticket": ticket, "code": codes[1].(string)}, 200)
|
||||
|
||||
// Session length needs no restart; the listen address does.
|
||||
web := store.Get().Web
|
||||
web.SessionHours = 24
|
||||
if r := adm("PATCH", "/settings", map[string]any{"web": web}, 200); r["restartRequired"] != false || store.Get().Web.SessionHours != 24 {
|
||||
t.Fatalf("session length: %v", r)
|
||||
}
|
||||
web.Listen = "127.0.0.1:9443"
|
||||
if r := adm("PATCH", "/settings", map[string]any{"web": web}, 200); r["restartRequired"] != true {
|
||||
t.Fatalf("listen address: %v", r)
|
||||
}
|
||||
|
||||
// Required for everyone: a user without it can only set it up.
|
||||
adm("PATCH", "/settings", map[string]any{"signin": map[string]bool{"requireMfa": true}}, 200)
|
||||
u := adm("POST", "/users", map[string]any{"username": "eve", "password": "eve's password 1", "mustChangePassword": false}, 201)["user"].(map[string]any)
|
||||
|
||||
Reference in New Issue
Block a user