cmd/containerd-shim: require unix socket credentials

Signed-off-by: Stephen J Day <stephen.day@docker.com>
This commit is contained in:
Stephen J Day
2017-11-30 17:15:28 -08:00
parent 08f179386e
commit 2d966df174
9 changed files with 218 additions and 21 deletions

View File

@@ -1,4 +1,4 @@
// +build !linux,!windows
// +build !linux,!windows,!darwin
package main
@@ -22,6 +22,6 @@ func setupSignals() (chan os.Signal, error) {
return signals, nil
}
func newServer() *ttrpc.Server {
return ttrpc.NewServer()
func newServer() (*ttrpc.Server, error) {
return ttrpc.NewServer(ttrpc.WithServerHandshaker(ttrpc.UnixSocketRequireSameUser()))
}