afero
afero copied to clipboard
A FileSystem Abstraction System for Go
When conducting tests, there are times when I want to create a read-only file, But i found that there is no option available to create a read-only file. I know...
Added flags to `const_bsds.go` and `const_win_unix.go` to allow for building on WASIp1 (Go 1.21) Closes #399
Or I need to open the file and then truncate it, as a workaround.
Hello, we are a team researching the dependency management mechanism of Golang. During our analysis, we came across your project and noticed that it contains a vulnerability (CVE-2022-32149). In your...
Since GO 1.17, ioutil.TempDir has called MkdirTemp for it's implementation. Since at least October of 2020, MkdirTemp has [checked the input prefix for os.PathSeparator](https://cs.opensource.google/go/go/+/refs/tags/go1.20.5:src/os/tempfile.go;l=62;bpv=0;bpt=0). This PR adds that check and...
I recently update a project from `v1.3.3` to `v1.8.2` and it looks like file mode is not preserved when creating files using `MemMapFs`. I'm trying to write a file with...
golang.org/x/text versions before 0.3.8 are vulnerable to CVE-2022-32149: > An attacker may cause a denial of service by crafting an Accept-Language header which ParseAcceptLanguage will take significant time to parse....
Hi, here's the reproduction of the issue: https://go.dev/play/p/Kl7rlp4q_ZO basically when using `CacheOnReadFs` with any base layer it fails with "bad file descriptor" error.
Adds a test that fails for the current MemMapFs when creating files in nested directories with synonyms for the path (i.e. full path, relative path, explict relative path). Also fixes...
As the title says is it possible to convert and embed.FS to a MemMapFS? This way I can make the memory FS writable too. I want to use that FS...