2 Commits
4 changed files with 13 additions and 11 deletions
+5
View File
@@ -1,2 +1,7 @@
# peercred-mini
A simple module for getting the PID and UID of processes accessing UNIX domain sockets and Windows named pipes.
# IMPORTANT - READ FOR FreeBSD+Windows SUPPORT!
There are replacements in the `go.mod` for this module. Make sure you maintain those
same replacements in your importing module, otherwise FreeBSD and Windows support will break
(support for those operating systems requires patched modules).
+4 -4
View File
@@ -1,12 +1,12 @@
module github.com/rwinkhart/peercred-mini
go 1.25.4
go 1.25.7
require (
github.com/Microsoft/go-winio v0.6.2
golang.org/x/sys v0.38.0
golang.org/x/sys v0.41.0
)
replace golang.org/x/sys => github.com/rwinkhart/sys v0.38.0
replace golang.org/x/sys => github.com/rwinkhart/sys v0.41.0
replace github.com/Microsoft/go-winio => github.com/rwinkhart/go-winio v0.1.0
replace github.com/Microsoft/go-winio => github.com/rwinkhart/go-winio v0.1.1
+4 -4
View File
@@ -1,4 +1,4 @@
github.com/rwinkhart/go-winio v0.1.0 h1:b72agLW+dETGmhR3VbcbwnStfgKfc5AfgJOXBJDkaHg=
github.com/rwinkhart/go-winio v0.1.0/go.mod h1:ZWa7ssZJT30CCDGJ7fk/2SBTq9BIQrrVjrcss0UW2s0=
github.com/rwinkhart/sys v0.38.0 h1:V1PGKcUutWtD3+VdHvyvfGtPy7PDXzKHNM1IzVq1ysY=
github.com/rwinkhart/sys v0.38.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
github.com/rwinkhart/go-winio v0.1.1 h1:kAJKiqneR7cUR01Wn5/doAAV4kOGTEGPug4oinXc5N4=
github.com/rwinkhart/go-winio v0.1.1/go.mod h1:ZWa7ssZJT30CCDGJ7fk/2SBTq9BIQrrVjrcss0UW2s0=
github.com/rwinkhart/sys v0.41.0 h1:pHB6HphVC132UXYZ6yeOk62abqgl+pyl5ZZnsk4iUKg=
github.com/rwinkhart/sys v0.41.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
-3
View File
@@ -46,9 +46,6 @@ func TestUnixSock(t *testing.T) {
defer c.Close()
creds := Get(c)
if err != nil {
t.Fatalf("Get: %v", err)
}
uid := creds.UID
if uid == "" {