vectordotdev/vector

Add API key validation in Datadog logs source

オープン

#6,809 opened on 2021/03/18

 (1 件のコメント) (0 件のリアクション) (0 人の担当者)Rust (2,126 件のフォーク)batch import
good first issuesource: datadog_agent

Repository metrics

Stars
 (21,837 個のスター)
PR merge metrics
 (PR metrics pending)

説明

Following #6744 Vector is able to receive log from a Datadog agent.

The source could be improved by allowing api key filtering:

[sources.addUnit]
type = "datadog_logs"
address = "0.0.0.0.0:8080"
# New config param suggestion to support multiple api key
# the behaviour would be subject to the drop_on_invalid_api_key value
valid_api_keys = ["123456", "789abc" ]
# If this is true a log coming with a unknown API key would be dropped
# else the API key would just be ignored and not saved in the event
drop_on_invalid_api_key = true

This would allow to address two usecases :

  • Basic authentication (drop_on_invalid_api_key = true)
  • Prevent unknown API keys to be used (i.e. avoid leaking logs lines to a 3rd party org)

One could argue that we could also support API key blacklisting, it could be addressed later thought.

コントリビューターガイド