Skip to content

Commit b9c1f9b

Browse files
Secret scanning: Add Extended metadata column to patterns table (#59525)
Co-authored-by: mc <42146119+mchammer01@users.noreply.github.com>
1 parent b7ecbde commit b9c1f9b

3 files changed

Lines changed: 8 additions & 5 deletions

File tree

content/code-security/reference/secret-security/supported-secret-scanning-patterns.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ The tables list the secrets supported by {% data variables.product.prodname_secr
4747
* Includes {% ifversion secret-scanning-alert-experimental-list %}default{% else %}high confidence{% endif %} tokens, which relate to supported patterns and specified custom patterns, as well as non-provider tokens such as private keys, which often result in false positives.{% endif %}
4848
* **Push protection:** Token for which leaks are reported to users on {% data variables.product.prodname_dotcom %}. Applies to repositories with {% data variables.product.prodname_secret_scanning %} and push protection enabled.
4949
* **Validity check:** Token for which a validity check is implemented. {% ifversion secret-scanning-validity-check-partner-patterns %}For partner tokens, {% data variables.product.prodname_dotcom %} sends the token to the relevant partner. Note that not all partners are based in the United States. For more information, see [{% data variables.product.prodname_AS %}](/free-pro-team@latest/site-policy/github-terms/github-terms-for-additional-products-and-features#advanced-security) in the Site Policy documentation.{% else %} Currently only applies to {% data variables.product.prodname_dotcom %} tokens.{% endif %}
50+
* **Metadata check:** Token for which extended metadata is available, providing additional context about the detected secret.
5051
* **Base64:** Token for which Base64-encoded versions are supported.
5152

5253
### Non-provider patterns
@@ -117,12 +118,12 @@ Precision levels are estimated based on the pattern type's typical false positiv
117118
{% ifversion fpt or ghec %}
118119

119120
> [!NOTE]
120-
> Validity checks are only available to users with {% data variables.product.prodname_team %} or {% data variables.product.prodname_enterprise %} who enable the feature as part of {% data variables.product.prodname_GH_secret_protection %}.
121+
> Validity and extended metadata checks are only available to users with {% data variables.product.prodname_team %} or {% data variables.product.prodname_enterprise %} who enable the feature as part of {% data variables.product.prodname_GH_secret_protection %}.
121122
122-
| Provider | Token | Partner | User | Push protection | Validity check | Base64 |
123-
|----|:----|:----:|:----:|:----:|:----:|:----:|
123+
| Provider | Token | Partner | User | Push protection | Validity check | Metadata check | Base64 |
124+
|----|:----|:----:|:----:|:----:|:----:|:----:|:----:|
124125
{%- for entry in secretScanningData %}
125-
| {{ entry.provider }} | {{ entry.secretType }} | {% if entry.isPublic %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.isPrivateWithGhas %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.hasPushProtection %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.hasValidityCheck %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.base64Supported %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} |
126+
| {{ entry.provider }} | {{ entry.secretType }} | {% if entry.isPublic %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.isPrivateWithGhas %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.hasPushProtection %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.hasValidityCheck %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.hasExtendedMetadata %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} | {% if entry.base64Supported %}<span role="img" class="octicon-bg-check" aria-label="Supported">✓</span>{% else %}<span role="img" class="octicon-bg-x" aria-label="Unsupported">✗</span>{% endif %} |
126127
{%- endfor %}
127128

128129
{% endif %}

src/secret-scanning/data/public-docs-schema.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export interface SecretScanningEntry {
1919
isPrivateWithGhas: boolean | string
2020
hasPushProtection: boolean | string
2121
hasValidityCheck: boolean | string
22-
hasExtendedMetadata?: boolean | string
22+
hasExtendedMetadata: boolean | string
2323
base64Supported: boolean | string
2424
isduplicate: boolean
2525
}
@@ -37,6 +37,7 @@ export default {
3737
'isPrivateWithGhas',
3838
'hasPushProtection',
3939
'hasValidityCheck',
40+
'hasExtendedMetadata',
4041
],
4142
properties: {
4243
provider: {

src/types/types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,7 @@ export type SecretScanningData = {
327327
isPrivateWithGhas: boolean
328328
hasPushProtection: boolean
329329
hasValidityCheck: boolean | string
330+
hasExtendedMetadata: boolean
330331
ismultipart?: boolean
331332
base64Supported: boolean
332333
isduplicate: boolean

0 commit comments

Comments
 (0)