add support for partial authentication

Multi-step authentication is activated disabling all single-step
auth methods for a given user
This commit is contained in:
Nicola Murino
2020-04-09 23:32:42 +02:00
parent a0fe4cf5e4
commit b1c7317cf6
20 changed files with 498 additions and 75 deletions

View File

@@ -484,7 +484,7 @@ func TestUploadFiles(t *testing.T) {
func TestWithInvalidHome(t *testing.T) {
u := dataprovider.User{}
u.HomeDir = "home_rel_path"
_, err := loginUser(u, dataprovider.SSHLoginMethodPassword, "", "")
_, err := loginUser(u, dataprovider.SSHLoginMethodPassword, "", nil)
if err == nil {
t.Errorf("login a user with an invalid home_dir must fail")
}