VictoriaMetrics/lib/flagutil
Roman Khavronenko 029060af60
app/vmbackup: introduce new flag type URL (#6152)
The new flag type is supposed to be used for specifying URL values which
could contain sensitive information such as auth tokens in GET params or
HTTP basic authentication.

The URL flag also allows loading its value from files if `file://`
prefix is specified. As example, the new flag type was used in
app/vmbackup as it requires specifying `authKey` param for making the
snapshot.

See related issue
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5973

Thanks to @wasim-nihal for initial implementation
https://github.com/VictoriaMetrics/VictoriaMetrics/pull/6060

---------

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2024-04-24 10:57:54 +02:00
..
testdata all: allow dynamically reading *AuthKey flag values from files and urls 2024-01-21 22:03:38 +02:00
array.go all: add support for specifying multiple -httpListenAddr options 2024-02-09 03:15:04 +02:00
array_test.go all: add support for specifying multiple -httpListenAddr options 2024-02-09 03:15:04 +02:00
bytes.go docs/CHANGELOG.md: support empty command-line flag values in short array notation 2024-02-07 20:53:13 +02:00
bytes_test.go docs/CHANGELOG.md: support empty command-line flag values in short array notation 2024-02-07 20:53:13 +02:00
dict.go app/{vmagent,vmalert}: add the ability to set OAuth2 endpoint params via the corresponding *.oauth2.endpointParams command-line flags 2023-12-20 21:35:28 +02:00
dict_test.go all: add support for specifying multiple -httpListenAddr options 2024-02-09 03:15:04 +02:00
duration.go docs/CHANGELOG.md: support empty command-line flag values in short array notation 2024-02-07 20:53:13 +02:00
duration_test.go docs/CHANGELOG.md: support empty command-line flag values in short array notation 2024-02-07 20:53:13 +02:00
flag.go lib/flagutil: do not expose sensitive info (passwords, keys and urls) at /flags page 2021-10-20 00:51:26 +03:00
password.go lib: consistently use atomic.* types instead of atomic.* functions 2024-02-24 02:07:53 +02:00
password_test.go all: allow dynamically reading *AuthKey flag values from files and urls 2024-01-21 22:03:38 +02:00
secret.go app/vmagent: substitute -remoteWrite.url with secret-url value in logs, since it may contain sensitive info such as passwords or auth tokens 2020-09-16 22:36:25 +03:00
url.go app/vmbackup: introduce new flag type URL (#6152) 2024-04-24 10:57:54 +02:00
url_test.go app/vmbackup: introduce new flag type URL (#6152) 2024-04-24 10:57:54 +02:00
usage.go lib/flagutil: make golangci-lint happy by using strings.TrimPrefix instead of manual prefix removal via strings.HasPrefix 2020-12-03 22:07:57 +02:00