change level for log message

tls
fangdingjun 6 years ago
parent e821ce6ecb
commit 3a5b7b1bd6

@ -2,10 +2,11 @@ package main
import (
"bytes"
"io/ioutil"
"github.com/fangdingjun/go-log"
"github.com/go-yaml/yaml"
"golang.org/x/crypto/ssh"
"io/ioutil"
"log"
)
type listen struct {
@ -51,7 +52,7 @@ func loadConfig(f string) (*serverConfig, error) {
for i := range c.Users {
buf1, err := ioutil.ReadFile(c.Users[i].AuthorizedKeyFile)
if err != nil {
log.Printf("read publickey for %s failed, ignore", c.Users[i].Username)
log.Warnf("read publickey for %s failed, ignore", c.Users[i].Username)
continue
}

@ -298,7 +298,7 @@ func (sc *Server) handleTcpipForward(req *ssh.Request) {
for {
c, err := l.Accept()
if err != nil {
log.Errorf("%s", err.Error())
log.Debugf("%s", err.Error())
return
}
log.Debugf("accept connection from %s", c.RemoteAddr())

Loading…
Cancel
Save