MCPcopy
hub / github.com/larksuite/cli / auditFilePermissions

Function auditFilePermissions

internal/binding/audit_windows.go:21–26  ·  view source on GitHub ↗

auditFilePermissions skips POSIX permission-bit auditing on Windows because Go synthesizes mode bits from file attributes rather than NTFS ACLs.

(effectivePath string, allowReadableByOthers bool, label string)

Source from the content-addressed store, hash-verified

19// auditFilePermissions skips POSIX permission-bit auditing on Windows because
20// Go synthesizes mode bits from file attributes rather than NTFS ACLs.
21func auditFilePermissions(effectivePath string, allowReadableByOthers bool, label string) error {
22 if _, err := vfs.Stat(effectivePath); err != nil {
23 return fmt.Errorf("%s: cannot stat %q: %w", label, effectivePath, err)
24 }
25 return nil
26}

Callers

nothing calls this directly

Calls 1

StatFunction · 0.92

Tested by

no test coverage detected