Files
gitleaks/cmd/generate/config/rules
icecream-monsterandEsther f77493274a adding jwt tokens with padding format "=" (#1031)
* adding jwt tokens with padding format =

* forgot to run go run main.go

* manually putting database.refractorlog back

Co-authored-by: Esther <esther.ay@snaptravel.com>
2022-11-22 15:55:03 -06:00
..
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-06-27 08:58:00 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-06-20 14:57:48 -05:00
2022-04-21 08:31:58 -05:00
2022-08-19 10:43:01 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-08-19 08:24:15 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-08-19 08:24:15 -05:00
2022-04-21 08:31:58 -05:00
2022-08-03 07:31:40 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-08-03 07:31:40 -05:00
2022-08-03 07:31:40 -05:00
2022-04-21 08:31:58 -05:00
2022-06-28 06:10:02 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-04-21 08:31:58 -05:00
2022-08-03 15:46:46 -05:00

package rules

import (
	"github.com/zricethezav/gitleaks/v8/cmd/generate/secrets"
	"github.com/zricethezav/gitleaks/v8/config"
)

func ReadMe() *config.Rule {
	// define rule
	r := config.Rule{
		RuleID:      "readme-api-token",
		Description: "Readme API token",
		Regex:       generateUniqueTokenRegex(`rdme_[a-z0-9]{70}`),
		SecretGroup: 1,
		Keywords: []string{
			"rdme_",
		},
	}

	// validate
	tps := []string{
		generateSampleSecret("api-token", "rdme_"+secrets.NewSecret(alphaNumeric("70"))),
	}
	return validate(r, tps, nil)
}