Compare commits

...
2 Commits
Author SHA1 Message Date
clawbot 828f1c7bc5 coreruleset: name the changes in the gitea tests' comments
check / check (push) Waiting to run
Two comments in gitea_test.go still named sww's changes to the Core Rule
Set by their old numbers, "the eighth change" and "the tenth change".
They now say gitea's fixes and Drupal's fixes.

Model: opus-5-5
2026-11-19 17:30:58 +00:00
sneak 8e3879a0c9 coreruleset: embed the apps' fixes as one directory (closes #430)
check / check (push) Failing after 2m10s
The nine app files move to internal/coreruleset/apps/ and are embedded
once as appFixes. An app's name is its file's name; the per-app
variables go, and apps keeps only gitea's and Forgejo's cookies and
forkOf. Comments and SPEC name each of sww's changes to the Core Rule
Set by what it does instead of by number. The directives Coraza gets
are unchanged.

Model: opus-5-5
2026-11-19 16:35:33 +00:00
12 changed files with 81 additions and 101 deletions

No files matched your search

+31 -30
View File
@@ -817,8 +817,8 @@ The supported apps are:
- `vaultwarden`; - `vaultwarden`;
- `wordpress`. - `wordpress`.
Each app's fixes are in one file, such as `internal/coreruleset/gitea.conf`, and Each app's fixes are in one file named for the app, such as
one entry of `apps` in `internal/coreruleset/coreruleset.go`. gitea's fixes are: `internal/coreruleset/apps/gitea.conf`. gitea's fixes are:
1. Ten parameters are not checked against the Core Rule Set's lists of system 1. Ten parameters are not checked against the Core Rule Set's lists of system
files (930120), shell paths (932160) and command names (932260), on any path: files (930120), shell paths (932160) and command names (932260), on any path:
@@ -851,8 +851,8 @@ one entry of `apps` in `internal/coreruleset/coreruleset.go`. gitea's fixes are:
3. On gitea's paths, some fields skip the rules that refused ordinary gitea 3. On gitea's paths, some fields skip the rules that refused ordinary gitea
requests there. They are the fields where gitea sends a search, a file's name requests there. They are the fields where gitea sends a search, a file's name
or text, a commit message, a branch name or a repository's name. or text, a commit message, a branch name or a repository's name.
`internal/coreruleset/gitea.conf` lists each rule and the request it refused. `internal/coreruleset/apps/gitea.conf` lists each rule and the request it
The fields are: refused. The fields are:
- `q` on gitea's searches of code, of issues and pull requests, and of - `q` on gitea's searches of code, of issues and pull requests, and of
commits. A code search holds code, such as `<script>`, commits. A code search holds code, such as `<script>`,
`SELECT * FROM users WHERE` or `../`. The searches of issues and pull `SELECT * FROM users WHERE` or `../`. The searches of issues and pull
@@ -1037,7 +1037,7 @@ one entry of `apps` in `internal/coreruleset/coreruleset.go`. gitea's fixes are:
- The `Content-Range` header of an artifact upload from - The `Content-Range` header of an artifact upload from
`actions/upload-artifact@v3` (920450). `actions/upload-artifact@v3` (920450).
- The passwords in a body, for each rule that random passwords set off. The - The passwords in a body, for each rule that random passwords set off. The
numbers are in `internal/coreruleset/gitea.conf`. numbers are in `internal/coreruleset/apps/gitea.conf`.
- `password` on these paths: - `password` on these paths:
- `/user/login`, `/user/sign_up`, `/user/activate`; - `/user/login`, `/user/sign_up`, `/user/activate`;
- `/user/link_account_signin` and `/user/link_account_signup`; - `/user/link_account_signin` and `/user/link_account_signup`;
@@ -1069,8 +1069,8 @@ one entry of `apps` in `internal/coreruleset/coreruleset.go`. gitea's fixes are:
such as `owner/python3-app` would have that push refused. such as `owner/python3-app` would have that push refused.
WordPress's fixes: on WordPress's paths, some fields skip the rules that refused WordPress's fixes: on WordPress's paths, some fields skip the rules that refused
ordinary WordPress requests there. `internal/coreruleset/wordpress.conf` lists ordinary WordPress requests there. `internal/coreruleset/apps/wordpress.conf`
each rule and the request it refused. The REST API has four addresses: lists each rule and the request it refused. The REST API has four addresses:
- `/wp-json/...` - `/wp-json/...`
- `/index.php/wp-json/...` - `/index.php/wp-json/...`
@@ -1162,9 +1162,9 @@ Elsewhere WordPress's fixes do not apply. The paths are those of WordPress at
the site root. the site root.
Drupal's fixes: on Drupal's paths, some fields skip the rules that refused Drupal's fixes: on Drupal's paths, some fields skip the rules that refused
ordinary Drupal requests there. `internal/coreruleset/drupal.conf` lists each ordinary Drupal requests there. `internal/coreruleset/apps/drupal.conf` lists
rule and the request it refused. These query fields skip the lists of system each rule and the request it refused. These query fields skip the lists of
files and command names (930120, 932120, 932250, 932260): system files and command names (930120, 932120, 932250, 932260):
- On every page under `/admin`: `title`, `name`, `user`, `filename`, `filemime`, - On every page under `/admin`: `title`, `name`, `user`, `filename`, `filemime`,
`info`, `subject`, `author_name`, `search`, `q` and `destination`. `info`, `subject`, `author_name`, `search`, `q` and `destination`.
@@ -1254,10 +1254,10 @@ first path segment of two or three lowercase letters, optionally followed by a
hyphen and more letters, so `/api` counts too. hyphen and more letters, so `/api` counts too.
MediaWiki's fixes: on MediaWiki's paths, some fields skip the rules that refused MediaWiki's fixes: on MediaWiki's paths, some fields skip the rules that refused
ordinary MediaWiki requests there. `internal/coreruleset/mediawiki.conf` lists ordinary MediaWiki requests there. `internal/coreruleset/apps/mediawiki.conf`
each rule and the request it refused. These fields skip the lists of system lists each rule and the request it refused. These fields skip the lists of
files and command names (930120, 932120, 932250, 932260), in the query or the system files and command names (930120, 932120, 932250, 932260), in the query or
body: the body:
- On MediaWiki's pages, which are `/index.php` and the paths under `/index.php/` - On MediaWiki's pages, which are `/index.php` and the paths under `/index.php/`
and `/wiki/`: and `/wiki/`:
@@ -1363,9 +1363,9 @@ Elsewhere these fields keep every rule. The paths are those of MediaWiki at the
site root or under `/w/`. site root or under `/w/`.
Mastodon's fixes: on Mastodon's paths, some fields skip the rules that refused Mastodon's fixes: on Mastodon's paths, some fields skip the rules that refused
ordinary Mastodon requests there. `internal/coreruleset/mastodon.conf` lists ordinary Mastodon requests there. `internal/coreruleset/apps/mastodon.conf`
each rule and the request it refused. These fields skip the lists of system lists each rule and the request it refused. These fields skip the lists of
files and command names (930120, 932120, 932250, 932260), in the query: system files and command names (930120, 932120, 932250, 932260), in the query:
- On the API's search, accounts and admin accounts, under `/api/v1/` and - On the API's search, accounts and admin accounts, under `/api/v1/` and
`/api/v2/`, the searches and names `q`, `acct`, `username`, `display_name`, `/api/v2/`, the searches and names `q`, `acct`, `username`, `display_name`,
@@ -1526,7 +1526,7 @@ every rule.
Vaultwarden's fixes: on Vaultwarden's paths, some fields skip the rules that Vaultwarden's fixes: on Vaultwarden's paths, some fields skip the rules that
refused ordinary Vaultwarden requests there. refused ordinary Vaultwarden requests there.
`internal/coreruleset/vaultwarden.conf` lists each rule and the request it `internal/coreruleset/apps/vaultwarden.conf` lists each rule and the request it
refused. The apps encrypt vault items, folders, collections and sends before refused. The apps encrypt vault items, folders, collections and sends before
sending them, so those fields skip no rules. The fields below hold plain text. sending them, so those fields skip no rules. The fields below hold plain text.
@@ -1577,8 +1577,8 @@ has a parameter of the same name.
`token` in the body of `/admin`, the admin token typed on the admin page, skips `token` in the body of `/admin`, the admin token typed on the admin page, skips
each rule that random passwords set off. The numbers are in each rule that random passwords set off. The numbers are in
`internal/coreruleset/vaultwarden.conf`. It applies only when the query has no `internal/coreruleset/apps/vaultwarden.conf`. It applies only when the query has
`token` parameter. `' OR '1'='1`, `../../etc/passwd`, `; cat /etc/passwd` and no `token` parameter. `' OR '1'='1`, `../../etc/passwd`, `; cat /etc/passwd` and
`<img src=x onerror=x()>` sent as the token reach Vaultwarden; `<img src=x onerror=x()>` sent as the token reach Vaultwarden;
`<script>alert(1)</script>` and `javascript:alert(1)` are still refused. `<script>alert(1)</script>` and `javascript:alert(1)` are still refused.
@@ -1600,7 +1600,7 @@ Elsewhere these fields keep every rule.
Nextcloud's fixes: on Nextcloud's paths, some fields skip the rules that refused Nextcloud's fixes: on Nextcloud's paths, some fields skip the rules that refused
ordinary Nextcloud requests there, and its WebDAV methods are allowed. ordinary Nextcloud requests there, and its WebDAV methods are allowed.
`internal/coreruleset/nextcloud.conf` lists each rule and the request it `internal/coreruleset/apps/nextcloud.conf` lists each rule and the request it
refused. refused.
The sync client and the Files app use WebDAV on these paths: The sync client and the Files app use WebDAV on these paths:
@@ -1610,7 +1610,8 @@ The sync client and the Files app use WebDAV on these paths:
- `/remote.php/webdav/`; - `/remote.php/webdav/`;
- `/public.php/webdav/`. - `/public.php/webdav/`.
These methods are allowed there, besides those of the first change: These methods are allowed there, besides `PUT`, `PATCH` and `DELETE`, which
every app gets:
- `PROPFIND` and `PROPPATCH`; - `PROPFIND` and `PROPPATCH`;
- `MKCOL`; - `MKCOL`;
@@ -1754,7 +1755,7 @@ gets gitea's fixes too. Forgejo's own fixes hold only what Forgejo sends and
gitea does not. gitea does not.
On Forgejo's paths, some fields skip the rules that refused ordinary Forgejo On Forgejo's paths, some fields skip the rules that refused ordinary Forgejo
requests there. `internal/coreruleset/forgejo.conf` lists each rule and the requests there. `internal/coreruleset/apps/forgejo.conf` lists each rule and the
request it refused. request it refused.
`q` skips rules on some of Forgejo's searches. The searches are: `q` skips rules on some of Forgejo's searches. The searches are:
@@ -1800,10 +1801,10 @@ The Core Rule Set reads the request without the `flash` cookie, in which Forgejo
puts what gitea puts in `gitea_flash` (gitea's second fix). puts what gitea puts in `gitea_flash` (gitea's second fix).
Ghost's fixes: on Ghost's paths, some fields skip the rules that refused Ghost's fixes: on Ghost's paths, some fields skip the rules that refused
ordinary Ghost requests there. `internal/coreruleset/ghost.conf` lists each rule ordinary Ghost requests there. `internal/coreruleset/apps/ghost.conf` lists each
and the request it refused. Ghost's admin and integrations call the Admin API rule and the request it refused. Ghost's admin and integrations call the Admin
under `/ghost/api/admin/`. Themes and Ghost's scripts call the Content API under API under `/ghost/api/admin/`. Themes and Ghost's scripts call the Content API
`/ghost/api/content/`, and members call `/members/api/`. The admin calls under `/ghost/api/content/`, and members call `/members/api/`. The admin calls
ActivityPub, a service of its own, under `/.ghost/activitypub/`. ActivityPub, a service of its own, under `/.ghost/activitypub/`.
Eight rules refused words that name commands and files, such as `python3`, Eight rules refused words that name commands and files, such as `python3`,
@@ -1941,9 +1942,9 @@ That name holds `.profile`, a file on the list of system files, so the name
skips 930120 when a profile is saved. skips 930120 when a profile is saved.
The passwords skip each rule that random passwords set off. The numbers are in The passwords skip each rule that random passwords set off. The numbers are in
`internal/coreruleset/ghost.conf`. They are `password` when signing in, and the `internal/coreruleset/apps/ghost.conf`. They are `password` when signing in, and
passwords sent when creating the first staff user, accepting an invitation, and the passwords sent when creating the first staff user, accepting an invitation,
resetting or changing a password. `' OR '1'='1`, `../../etc/passwd`, and resetting or changing a password. `' OR '1'='1`, `../../etc/passwd`,
`; cat /etc/passwd` and `<img src=x onerror=x()>` sent as a password reach `; cat /etc/passwd` and `<img src=x onerror=x()>` sent as a password reach
Ghost; `<script>alert(1)</script>` and `javascript:alert(1)` are still refused. Ghost; `<script>alert(1)</script>` and `javascript:alert(1)` are still refused.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -37,9 +37,10 @@
SecRule &TX:app_nextcloud "@eq 0" \ SecRule &TX:app_nextcloud "@eq 0" \
"id:900090,phase:1,pass,nolog,skipAfter:END_NEXTCLOUD" "id:900090,phase:1,pass,nolog,skipAfter:END_NEXTCLOUD"
# The sync client and the Files app use these WebDAV methods besides those # The sync client and the Files app use these WebDAV methods besides PUT,
# the first change allows, on /remote.php/dav/ and /public.php/dav/ and on the # PATCH and DELETE, which sww allows for every app, on /remote.php/dav/ and
# older /remote.php/webdav/ and /public.php/webdav/. 911100 refused each: # /public.php/dav/ and on the older /remote.php/webdav/ and /public.php/webdav/.
# 911100 refused each:
# PROPFIND, PROPPATCH: listing a folder, marking a file a favourite # PROPFIND, PROPPATCH: listing a folder, marking a file a favourite
# MKCOL: making a folder, and starting a chunked upload # MKCOL: making a folder, and starting a chunked upload
# COPY, MOVE: copying, moving and renaming, and ending a chunked upload # COPY, MOVE: copying, moving and renaming, and ending a chunked upload
File renamed without changes.
+43 -65
View File
@@ -12,11 +12,10 @@
package coreruleset package coreruleset
import ( import (
_ "embed" "embed"
"errors" "errors"
"fmt" "fmt"
"io" "io"
"maps"
"net" "net"
"net/http" "net/http"
"net/netip" "net/netip"
@@ -35,7 +34,7 @@ import (
// directives are the Core Rule Set as sww runs it, with the // directives are the Core Rule Set as sww runs it, with the
// paranoia level for %d, bodyDirectives for the first %s while // paranoia level for %d, bodyDirectives for the first %s while
// SWW_WAF_CORE_RULE_SET_BODY_INSPECTION_SIZE is set, the exclusions file for // SWW_WAF_CORE_RULE_SET_BODY_INSPECTION_SIZE is set, the exclusions file for
// the second, and the directives of every app in apps for the third. // the second, and the fixes of every app in appFixes for the third.
// Each rule sww adds has an id from 900000 to 900999, the ids the // Each rule sww adds has an id from 900000 to 900999, the ids the
// Core Rule Set keeps for the rules that set it up, which // Core Rule Set keeps for the rules that set it up, which
// SWW_WAF_CORE_RULE_SET_DISABLED_RULES and the exclusions file refuse, so that no // SWW_WAF_CORE_RULE_SET_DISABLED_RULES and the exclusions file refuse, so that no
@@ -54,13 +53,12 @@ Include @crs-setup.conf.example
SecAction "id:900000,phase:1,pass,nolog,\ SecAction "id:900000,phase:1,pass,nolog,\
setvar:tx.blocking_paranoia_level=%d" setvar:tx.blocking_paranoia_level=%d"
# The first change: PUT, PATCH and DELETE are allowed besides GET, HEAD, # PUT, PATCH and DELETE are allowed besides GET, HEAD, POST and OPTIONS.
# POST and OPTIONS.
SecAction "id:900200,phase:1,pass,nolog,\ SecAction "id:900200,phase:1,pass,nolog,\
setvar:'tx.allowed_methods=GET HEAD POST OPTIONS PUT PATCH DELETE'" setvar:'tx.allowed_methods=GET HEAD POST OPTIONS PUT PATCH DELETE'"
# The second: Expect and Content-Encoding are taken off the Core Rule Set's # Expect and Content-Encoding are taken off the Core Rule Set's list of the
# list of the headers it refuses. Content-Encoding goes back on it for a # headers it refuses. Content-Encoding goes back on it for a
# body the Core Rule Set reads (900260 in bodyDirectives). # body the Core Rule Set reads (900260 in bodyDirectives).
SecAction "id:900250,phase:1,pass,nolog,\ SecAction "id:900250,phase:1,pass,nolog,\
setvar:'tx.restricted_headers_basic=/proxy/ /lock-token/ /content-range/ \ setvar:'tx.restricted_headers_basic=/proxy/ /lock-token/ /content-range/ \
@@ -86,18 +84,17 @@ SecRule ARGUMENTS_LIMIT_REACHED "@eq 1" "id:900300,phase:2,pass,\
# The apps' fixes come before the rules for the same reason. # The apps' fixes come before the rules for the same reason.
%s %s
# The fifth: only the rules for requests are loaded, and no response is # Only the rules for requests are loaded, and no response is inspected.
# inspected.
Include @owasp_crs/REQUEST-*.conf Include @owasp_crs/REQUEST-*.conf
# The third: redirect_uri is not checked for a URL naming an IP address or # redirect_uri is not checked for a URL naming an IP address or
# localhost. Coraza matches a parameter name here without regard to case. # localhost. Coraza matches a parameter name here without regard to case.
# ARGS holds the fields of a form data or multipart body Coraza reads as # ARGS holds the fields of a form data or multipart body Coraza reads as
# well as the query parameters, so a field of this name is left out too. # well as the query parameters, so a field of this name is left out too.
SecRuleUpdateTargetById 931100 "!ARGS:redirect_uri" SecRuleUpdateTargetById 931100 "!ARGS:redirect_uri"
SecRuleUpdateTargetById 934110 "!ARGS:redirect_uri" SecRuleUpdateTargetById 934110 "!ARGS:redirect_uri"
# The fourth: Referer is not checked for a Unix command without arguments # Referer is not checked for a Unix command without arguments
# or for Java starting a process. # or for Java starting a process.
SecRuleUpdateTargetById 932340 "!REQUEST_HEADERS:Referer" SecRuleUpdateTargetById 932340 "!REQUEST_HEADERS:Referer"
SecRuleUpdateTargetById 944110 "!REQUEST_HEADERS:Referer" SecRuleUpdateTargetById 944110 "!REQUEST_HEADERS:Referer"
@@ -122,9 +119,9 @@ SecRule REQUEST_HEADERS:Content-Type \
"@rx ^(?:application|text)/(?:[a-z0-9.-]+[+])?json" \ "@rx ^(?:application|text)/(?:[a-z0-9.-]+[+])?json" \
"id:900420,phase:1,pass,nolog,t:none,t:lowercase,ctl:requestBodyProcessor=JSON" "id:900420,phase:1,pass,nolog,t:none,t:lowercase,ctl:requestBodyProcessor=JSON"
# The rest of the second change: Content-Encoding is refused again on a # Content-Encoding goes back on the list of the headers the Core Rule Set
# body of a kind the Core Rule Set reads, since a compressed body cannot be # refuses (900250 in directives) for a body of a kind it reads, since a
# inspected. # compressed body cannot be inspected.
SecRule REQBODY_PROCESSOR "@rx ^(?:URLENCODED|MULTIPART|JSON|XML)$" \ SecRule REQBODY_PROCESSOR "@rx ^(?:URLENCODED|MULTIPART|JSON|XML)$" \
"id:900260,phase:1,pass,nolog,\ "id:900260,phase:1,pass,nolog,\
setvar:'tx.restricted_headers_basic=%%{tx.restricted_headers_basic} \ setvar:'tx.restricted_headers_basic=%%{tx.restricted_headers_basic} \
@@ -145,15 +142,19 @@ SecRule MULTIPART_STRICT_ERROR "!@eq 0" "id:900450,phase:2,pass,\
severity:'CRITICAL',setvar:'tx.inbound_anomaly_score_pl1=+5'" severity:'CRITICAL',setvar:'tx.inbound_anomaly_score_pl1=+5'"
` `
// app is an app whose ordinary requests the Core Rule Set would refuse, // appFixes holds the fixes of each app whose ordinary requests the Core
// with the fixes that let them pass. // Rule Set would refuse, in a file named for the app by the name
// SWW_WAF_APPS gives it, such as apps/gitea.conf. The fixes are Coraza
// exclusions, loaded before the Core Rule Set's rules. Their first rule
// skips to the marker they end with, unless Inspect sets the transaction
// variable named for the app, such as app_gitea. The skip reaches only
// phase 1, so a rule of a later phase must check that variable itself.
//
//go:embed apps/*.conf
var appFixes embed.FS
// app is what an app's file in appFixes cannot say about it.
type app struct { type app struct {
// directives are Coraza exclusions, loaded before the Core Rule Set's
// rules. Their first rule skips to the marker they end with, unless
// Inspect sets the transaction variable named for the app, such as
// app_gitea. The skip reaches only phase 1, so a rule of a later phase
// must check that variable itself.
directives string
// cookies are the cookies the Core Rule Set reads a request without. // cookies are the cookies the Core Rule Set reads a request without.
cookies []string cookies []string
// forkOf names the app this one is a fork of, "" for none. A hostname // forkOf names the app this one is a fork of, "" for none. A hostname
@@ -161,60 +162,34 @@ type app struct {
forkOf string forkOf string
} }
//go:embed gitea.conf // apps are the apps that need more than their file in appFixes, by the
var giteaDirectives string // name SWW_WAF_APPS gives each. flash is Forgejo's name for gitea_flash.
//go:embed wordpress.conf
var wordpressDirectives string
//go:embed drupal.conf
var drupalDirectives string
//go:embed mediawiki.conf
var mediawikiDirectives string
//go:embed mastodon.conf
var mastodonDirectives string
//go:embed vaultwarden.conf
var vaultwardenDirectives string
//go:embed nextcloud.conf
var nextcloudDirectives string
//go:embed forgejo.conf
var forgejoDirectives string
//go:embed ghost.conf
var ghostDirectives string
// apps are the apps whose fixes sww has, by the name SWW_WAF_APPS gives each.
// flash is Forgejo's name for gitea_flash.
// //
//nolint:gochecknoglobals // a constant cannot be a map //nolint:gochecknoglobals // a constant cannot be a map
var apps = map[string]app{ var apps = map[string]app{
"drupal": {directives: drupalDirectives},
"forgejo": { "forgejo": {
directives: forgejoDirectives, cookies: []string{"flash"},
cookies: []string{"flash"}, forkOf: "gitea",
forkOf: "gitea",
}, },
"ghost": {directives: ghostDirectives},
"gitea": { "gitea": {
directives: giteaDirectives, cookies: []string{"gitea_flash", "redirect_to"},
cookies: []string{"gitea_flash", "redirect_to"},
}, },
"mastodon": {directives: mastodonDirectives},
"mediawiki": {directives: mediawikiDirectives},
"nextcloud": {directives: nextcloudDirectives},
"vaultwarden": {directives: vaultwardenDirectives},
"wordpress": {directives: wordpressDirectives},
} }
// AppNames returns the names of the apps whose fixes sww has, in // AppNames returns the names of the apps whose fixes sww has, in
// alphabetical order. // alphabetical order.
func AppNames() []string { func AppNames() []string {
return slices.Sorted(maps.Keys(apps)) // An embedded directory always reads.
files, _ := appFixes.ReadDir("apps")
names := make([]string, len(files))
for i, file := range files {
names[i] = strings.TrimSuffix(file.Name(), ".conf")
}
slices.Sort(names)
return names
} }
// Params are what New needs. // Params are what New needs.
@@ -373,8 +348,11 @@ func New(params Params) (*CoreRuleSet, error) {
} }
var fixes strings.Builder var fixes strings.Builder
for _, name := range AppNames() { for _, name := range AppNames() {
fixes.WriteString(apps[name].directives + "\n") // An embedded file always reads.
file, _ := appFixes.ReadFile("apps/" + name + ".conf")
fixes.WriteString(string(file) + "\n")
} }
text := fmt.Sprintf(directives, params.ParanoiaLevel, body, exclusions, text := fmt.Sprintf(directives, params.ParanoiaLevel, body, exclusions,
+3 -3
View File
@@ -17,7 +17,7 @@ const (
) )
// giteaSearches are searches of the pages gitea and Forgejo share whose q // giteaSearches are searches of the pages gitea and Forgejo share whose q
// skips the lists of system files and command names, in the eighth change. // skips the lists of system files and command names, in gitea's fixes.
// gitea serves its admin pages under /-/admin/ and Forgejo under /admin/. // gitea serves its admin pages under /-/admin/ and Forgejo under /admin/.
// //
//nolint:gochecknoglobals // a constant cannot be a list //nolint:gochecknoglobals // a constant cannot be a list
@@ -222,8 +222,8 @@ func TestGiteaSearchExclusionsAreNarrow(t *testing.T) {
} }
// Under /admin/, where Forgejo serves its admin pages, only the hard // Under /admin/, where Forgejo serves its admin pages, only the hard
// values are left out: the tenth change lets them through in q on every // values are left out: Drupal's fixes let them through in q on every path
// path there, for Drupal. // there.
for _, target := range []string{ for _, target := range []string{
"/admin/packages/delete?q=", "/admin/packages/delete?q=",
"/admin/packages?other=", "/admin/packages?other=",