Skip to content

Commit

Permalink
bugfix see golang/go#19767
Browse files Browse the repository at this point in the history
  • Loading branch information
mylxsw committed Aug 30, 2017
1 parent 7838bb4 commit 7fab0ae
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.idea
.vscode
bin/remote-tail*
yunsom.toml
8 changes: 6 additions & 2 deletions ssh/ssh.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ package ssh

import (
"fmt"
"golang.org/x/crypto/ssh"
"io/ioutil"
"os"
"path/filepath"

"golang.org/x/crypto/ssh"
)

type Client struct {
Expand All @@ -17,7 +18,10 @@ type Client struct {
}

func (this *Client) Connect() error {
conf := ssh.ClientConfig{User: this.User}
conf := ssh.ClientConfig{
User: this.User,
HostKeyCallback: ssh.InsecureIgnoreHostKey(),
}

if this.Password != "" {
conf.Auth = append(conf.Auth, ssh.Password(this.Password))
Expand Down

0 comments on commit 7fab0ae

Please sign in to comment.