airtable.go 644 B

12345678910111213141516171819202122
  1. package rules
  2. import (
  3. "github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
  4. "github.com/zricethezav/gitleaks/v8/config"
  5. )
  6. func Airtable() *config.Rule {
  7. // define rule
  8. r := config.Rule{
  9. Description: "Uncovered a possible Airtable API Key, potentially compromising database access and leading to data leakage or alteration.",
  10. RuleID: "airtable-api-key",
  11. Regex: generateSemiGenericRegex([]string{"airtable"}, alphaNumeric("17"), true),
  12. Keywords: []string{"airtable"},
  13. }
  14. // validate
  15. tps := []string{
  16. generateSampleSecret("airtable", secrets.NewSecret(alphaNumeric("17"))),
  17. }
  18. return validate(r, tps, nil)
  19. }