Skip to content

Commit

Permalink
Merge pull request opencontainers#2041 from jburianek/notify-socket-p…
Browse files Browse the repository at this point in the history
…ermissions

Change the permissions of the notify listener socket to rwx for everyone
  • Loading branch information
crosbymichael committed Sep 18, 2019
2 parents bf27c2f + 7a9ffa8 commit 7507c64
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions notify_socket.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"bytes"
"fmt"
"net"
"os"
"path/filepath"

"github.com/opencontainers/runtime-spec/specs-go"
Expand Down Expand Up @@ -60,6 +61,12 @@ func (s *notifySocket) setupSocket() error {
return err
}

err = os.Chmod(s.socketPath, 0777)
if err != nil {
socket.Close()
return err
}

s.socket = socket
return nil
}
Expand Down

0 comments on commit 7507c64

Please sign in to comment.