diff -r 58d977250f6f ssh/client_auth.go --- a/ssh/client_auth.go Mon Apr 14 10:43:20 2014 -0700 +++ b/ssh/client_auth.go Tue Apr 15 12:05:40 2014 +0200 @@ -43,15 +43,20 @@ auth = nil for _, a := range config.Auth { candidateMethod := a.method() + found := false for _, meth := range methods { if meth != candidateMethod { continue } if !tried[meth] { auth = a + found = true break } } + if found { + break + } } } return fmt.Errorf("ssh: unable to authenticate, attempted methods %v, no supported methods remain", keys(tried))