package rootaws import ( "os" "github.com/carlosframework/platform/internal/safefile" ) func openCredentials(path string) (*os.File, error) { // safefile pins through O_PATH|O_NOFOLLOW, checks the inode and reopens // that descriptor, rejecting links and special files before opening them. return safefile.OpenFile(path, os.O_RDONLY, 0) }