carlos / platform Public

Clone
git clone https://amadan.net/carlos/platform

Plain git — no account needed to clone.

Download

Download this file

1package rootaws
2
3import (
4 "os"
5
6 "github.com/carlosframework/platform/internal/safefile"
7)
8
9func openCredentials(path string) (*os.File, error) {
10 // safefile pins through O_PATH|O_NOFOLLOW, checks the inode and reopens
11 // that descriptor, rejecting links and special files before opening them.
12 return safefile.OpenFile(path, os.O_RDONLY, 0)
13}
14