バルス!
ついに大型アップデートが来たのでアップデートしてみました!(バージョンアップ)
というか予想以上に簡単だったので、特に検証とかやらず本番稼働してるものに当てました。
(恐ろしい…)
■v0.4.0
https://github.com/future-architect/vuls
・スキャン精度大幅向上
・レポートの情報量アップ(?が減る)
・fast(sudoなし、サーバ低負荷のスキャンモード)をデフォルトに
大まかに言うとこんな感じ。?は確かに助かる!w
■How to Update to the Latest Version
https://github.com/future-architect/vuls#how-to-update-to-the-latest-version
では参考にしてアップデート(バージョンアップ)してみる
■v0.4.0 to update
・environment
1 2 3 4 5 |
$ vuls -v vuls v0.3.0 fecd1ad $ go version go version go1.8.3 linux/amd64 |
・Update go-cve-dictionary
1 2 3 4 5 6 7 8 9 10 |
[~/go/src/github.com/kotakanbe/go-cve-dictionary] $ cd $GOPATH/src/github.com/kotakanbe/go-cve-dictionary [~/go/src/github.com/kotakanbe/go-cve-dictionary] $ git pull $ rm -rf vendor $ make install go get -u github.com/golang/dep/... dep ensure go install -ldflags "-X 'main.version=v0.1.1' -X 'main.revision=c20fa7e'" |
・Update goval-dictionary
1 2 3 4 5 6 7 8 9 10 11 |
[~/go/src/github.com/kotakanbe/goval-dictionary] $ cd $GOPATH/src/github.com/kotakanbe/goval-dictionary [~/go/src/github.com/kotakanbe/goval-dictionary] $ git pull $ rm -rf vendor $ make install fatal: No names found, cannot describe anything. go get -u github.com/golang/dep/... dep ensure go install -ldflags "-X 'main.version=' -X 'main.revision=3523cc1'" |
・Update vuls
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
[~/go/src/github.com/kotakanbe/goval-dictionary] $ cd $GOPATH/src/github.com/future-architect/vuls [~/go/src/github.com/future-architect/vuls] $ git pull $ rm -rf vendor $ make install go get -u github.com/golang/dep/... dep ensure go install -ldflags "-X 'main.version=v0.4.0' -X 'main.revision=0ba490c'" [~/go/src/github.com/future-architect/vuls] $ vuls -v vuls v0.4.0 0ba490c |
■こんなエラーが出たあなた!
・その1
1 2 3 4 5 6 |
ensure Solve(): No versions of github.com/kotakanbe/logrus-prefixed-formatter met constraints: master: Unable to update checked out version: fatal: reference is not a tree: 75edb2e85a38873f0318be05a458446681d1022f master: Unable to update checked out version: fatal: reference is not a tree: 75edb2e85a38873f0318be05a458446681d1022f make: *** [dep] Error 1 |
・その2
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 |
util/logutil.go:29:2: cannot find package "github.com/kotakanbe/logrus-prefixed-formatter" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/github.com/kotakanbe/logrus-prefixed-formatter (vendor tree) /usr/local/go.1.8/src/github.com/kotakanbe/logrus-prefixed-formatter (from $GOROOT) /home/vuls/go/src/github.com/kotakanbe/logrus-prefixed-formatter (from $GOPATH) vendor/github.com/jinzhu/gorm/dialects/postgres/postgres.go:7:2: cannot find package "github.com/lib/pq" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/github.com/lib/pq (vendor tree) /usr/local/go.1.8/src/github.com/lib/pq (from $GOROOT) /home/vuls/go/src/github.com/lib/pq (from $GOPATH) vendor/github.com/jinzhu/gorm/dialects/postgres/postgres.go:8:2: cannot find package "github.com/lib/pq/hstore" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/github.com/lib/pq/hstore (vendor tree) /usr/local/go.1.8/src/github.com/lib/pq/hstore (from $GOROOT) /home/vuls/go/src/github.com/lib/pq/hstore (from $GOPATH) vendor/github.com/jroimartin/gocui/attribute.go:7:8: cannot find package "github.com/nsf/termbox-go" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/github.com/nsf/termbox-go (vendor tree) /usr/local/go.1.8/src/github.com/nsf/termbox-go (from $GOROOT) /home/vuls/go/src/github.com/nsf/termbox-go (from $GOPATH) scan/executil.go:33:2: cannot find package "golang.org/x/crypto/ssh" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/golang.org/x/crypto/ssh (vendor tree) /usr/local/go.1.8/src/golang.org/x/crypto/ssh (from $GOROOT) /home/vuls/go/src/golang.org/x/crypto/ssh (from $GOPATH) scan/executil.go:34:2: cannot find package "golang.org/x/crypto/ssh/agent" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/golang.org/x/crypto/ssh/agent (vendor tree) /usr/local/go.1.8/src/golang.org/x/crypto/ssh/agent (from $GOROOT) /home/vuls/go/src/golang.org/x/crypto/ssh/agent (from $GOPATH) vendor/github.com/sirupsen/logrus/text_formatter.go:13:2: cannot find package "golang.org/x/crypto/ssh/terminal" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/golang.org/x/crypto/ssh/terminal (vendor tree) /usr/local/go.1.8/src/golang.org/x/crypto/ssh/terminal (from $GOROOT) /home/vuls/go/src/golang.org/x/crypto/ssh/terminal (from $GOPATH) vendor/github.com/cenkalti/backoff/context.go:6:2: cannot find package "golang.org/x/net/context" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/golang.org/x/net/context (vendor tree) /usr/local/go.1.8/src/golang.org/x/net/context (from $GOROOT) /home/vuls/go/src/golang.org/x/net/context (from $GOPATH) vendor/github.com/parnurzeal/gorequest/gorequest.go:32:2: cannot find package "golang.org/x/net/publicsuffix" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/golang.org/x/net/publicsuffix (vendor tree) /usr/local/go.1.8/src/golang.org/x/net/publicsuffix (from $GOROOT) /home/vuls/go/src/golang.org/x/net/publicsuffix (from $GOPATH) vendor/github.com/sirupsen/logrus/terminal_linux.go:10:8: cannot find package "golang.org/x/sys/unix" in any of: /home/vuls/go/src/github.com/future-architect/vuls/vendor/golang.org/x/sys/unix (vendor tree) /usr/local/go.1.8/src/golang.org/x/sys/unix (from $GOROOT) /home/vuls/go/src/golang.org/x/sys/unix (from $GOPATH) make: *** [install] Error 1 |
↑きっとgoのバージョン古いからだろうな….と1.9系にしてみましたが、
1 2 |
$ go version go version go1.9 linux/amd64 |
変わらず。。。
そしてREADMEを読んでみた。
もしエラーが出る場合は $GOPATH/pkg
を削除してから実行する
これかい!w
消したらエラーなくなりスムーズにアップデートされた。
■まとめ
そういえばVuls Repo(Web ui)のほうもgoのhttpパッケージで
動くようになったので次回ブログします〜
0件のコメント