Skip to content
This repository was archived by the owner on Mar 24, 2022. It is now read-only.

vmware-archive/concourse-filter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

8b9d400 · Mar 24, 2022

History

21 Commits
Feb 19, 2020
Mar 24, 2022
Mar 24, 2022
Feb 6, 2017
Jan 15, 2020
Feb 10, 2020
Jan 15, 2020
Jan 15, 2020
Jan 15, 2020
Jun 24, 2016

Repository files navigation

Concourse Filter

Redacts Stdout text that contain text from env variables

Compile

$ go build

Usage

$ export PASSWORD=password
$ ./test.sh |& ./concourse-filter

Sample output

Without the filter

➜  concourse-filter git:(master) ✗ ./test.sh
start test
password
dpasswordd
ls: password: No such file or directory
./test.sh: line 7: ech: command not found
stop test password

With the filter

➜  concourse-filter git:(master) ✗ ./test.sh |& ./concourse-filter
start test
[redacted]
d[redacted]d
ls: [redacted]: No such file or directory
./test.sh: line 7: ech: command not found
stop test [redacted]

Testing

go get ./...
ginkgo

Limitations

  • Cannot handle filtering of multi-token environment variable values (ex. SECRET='MULTI WORD SECRET'
  • The stderr based filtering only works on bash 4.x

About

Filters out os.Stdin text that contain text from env variables

Resources

License

Security policy

Stars

Watchers

Forks

Packages

No packages published