You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/code-security/secret-scanning/defining-custom-patterns-for-secret-scanning.md
+10-4
Original file line number
Diff line number
Diff line change
@@ -69,10 +69,7 @@ Before defining a custom pattern, you must ensure that {% data variables.product
69
69
{% data reusables.advanced-security.secret-scanning-new-custom-pattern %}
70
70
{% data reusables.advanced-security.secret-scanning-add-custom-pattern-details %}{% ifversion fpt or ghec or ghes > 3.4 or ghae-issue-5499 %}
71
71
1. When you're ready to test your new custom pattern, to identify matches in the repository without creating alerts, click **Save and dry run**.
72
-
1. When the dry run finishes, you'll see a sample of results (up to 1000) from the repository. Review the results and identify any false positive results.
73
-

74
-
1. Edit the new custom pattern to fix any problems with the results, then click **Save and dry run** to test your changes.
{% data reusables.advanced-security.secret-scanning-dry-run-results %}
76
73
{% endif %}
77
74
{% data reusables.advanced-security.secret-scanning-create-custom-pattern %}
78
75
@@ -111,18 +108,27 @@ aAAAe9
111
108
112
109
Before defining a custom pattern, you must ensure that you enable {% data variables.product.prodname_secret_scanning %} for the repositories that you want to scan in your organization. To enable {% data variables.product.prodname_secret_scanning %} on all repositories in your organization, see "[Managing security and analysis settings for your organization](/organizations/keeping-your-organization-secure/managing-security-and-analysis-settings-for-your-organization)."
113
110
111
+
{% ifversion ghes < 3.5 or ghae %}
114
112
{% note %}
115
113
116
114
**Note:** As there is no dry-run functionality, we recommend that you test your custom patterns in a repository before defining them for your entire organization. That way, you can avoid creating excess false-positive {% data variables.product.prodname_secret_scanning %} alerts.
117
115
118
116
{% endnote %}
117
+
{% endif %}
119
118
120
119
{% data reusables.profile.access_org %}
121
120
{% data reusables.profile.org_settings %}
122
121
{% data reusables.organizations.security-and-analysis %}
123
122
{% data reusables.repositories.navigate-to-ghas-settings %}
124
123
{% data reusables.advanced-security.secret-scanning-new-custom-pattern %}
125
124
{% data reusables.advanced-security.secret-scanning-add-custom-pattern-details %}
125
+
{%- if secret-scanning-org-dry-runs %}
126
+
1. When you're ready to test your new custom pattern, to identify matches in select repositories without creating alerts, click **Save and dry run**.
127
+
1. Search for and select the repositories where you want to perform the dry run. You can select up to 10 repositories.
128
+

129
+
1. When you're ready to test your new custom pattern, click **Dry run**.
130
+
{% data reusables.advanced-security.secret-scanning-dry-run-results %}
131
+
{%- endif %}
126
132
{% data reusables.advanced-security.secret-scanning-create-custom-pattern %}
127
133
128
134
After your pattern is created, {% data variables.product.prodname_secret_scanning %} scans for any secrets in repositories in your organization, including their entire Git history on all branches. Organization owners and repository administrators will be alerted to any secrets found and can review the alert in the repository where the secret is found. For more information on viewing {% data variables.product.prodname_secret_scanning %} alerts, see "[Managing alerts from {% data variables.product.prodname_secret_scanning %}](/code-security/secret-security/managing-alerts-from-secret-scanning)."
1. When the dry run finishes, you'll see a sample of results (up to 1000) from the repository. Review the results and identify any false positive results.
2
+

3
+
1. Edit the new custom pattern to fix any problems with the results, then, to test your changes, click **Save and dry run**.
0 commit comments