Reorganize packages
This commit is contained in:
@@ -8,12 +8,12 @@ import (
|
||||
"os/signal"
|
||||
"time"
|
||||
|
||||
"github.com/gliderlabs/ssh"
|
||||
sshlib "github.com/gliderlabs/ssh"
|
||||
"github.com/urfave/cli/v2"
|
||||
"github.uio.no/torjus/apiary"
|
||||
"github.uio.no/torjus/apiary/config"
|
||||
"github.uio.no/torjus/apiary/honeypot"
|
||||
"github.uio.no/torjus/apiary/honeypot/store"
|
||||
"github.uio.no/torjus/apiary/honeypot/ssh"
|
||||
"github.uio.no/torjus/apiary/honeypot/ssh/store"
|
||||
"github.uio.no/torjus/apiary/web"
|
||||
"go.uber.org/zap"
|
||||
"go.uber.org/zap/zapcore"
|
||||
@@ -82,7 +82,7 @@ func ActionServe(c *cli.Context) error {
|
||||
}
|
||||
|
||||
// Setup honeypot
|
||||
hs, err := honeypot.NewHoneypotServer(cfg.Honeypot, s)
|
||||
hs, err := ssh.NewHoneypotServer(cfg.Honeypot, s)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -123,7 +123,7 @@ func ActionServe(c *cli.Context) error {
|
||||
// Start ssh server
|
||||
go func() {
|
||||
loggers.rootLogger.Info("Starting SSH server")
|
||||
if err := hs.ListenAndServe(); err != nil && err != ssh.ErrServerClosed {
|
||||
if err := hs.ListenAndServe(); err != nil && err != sshlib.ErrServerClosed {
|
||||
loggers.rootLogger.Warnw("SSH server returned error", "error", err)
|
||||
}
|
||||
}()
|
||||
|
Reference in New Issue
Block a user