From e73a4441d12d3aedab1888f317fe8553deb5ba47 Mon Sep 17 00:00:00 2001 From: GrantBirki Date: Mon, 13 Nov 2023 14:02:22 -0700 Subject: [PATCH] update regex for PATs --- lib/patterns/default.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/patterns/default.rb b/lib/patterns/default.rb index df36139..31ad926 100644 --- a/lib/patterns/default.rb +++ b/lib/patterns/default.rb @@ -3,7 +3,7 @@ # This module contains the default patterns to redact. module Patterns DEFAULT = [ - /ghp_[a-zA-Z0-9]{36,}/, # GitHub Personal Access Token + /ghp_[A-Za-z0-9]{36,}|[0-9A-Fa-f]{40,}/, # GitHub Personal Access Token /github_pat_[a-zA-Z0-9]{22}_[a-zA-Z0-9]{59}/, # GitHub Personal Access Token (fine-grained) /ghs_[a-zA-Z0-9]{36}/ # Temporary GitHub Actions Tokens ].freeze