Bugzilla – Attachment 190284 Details for
Bug 40993
Do not allow direct calls of value_builder scripts
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40993: Add Apache RewriteRule for hitting value_builder pages
399204e.patch (text/plain), 1.60 KB, created by
Martin Renvoize (ashimema)
on 2025-12-08 12:28:40 UTC
(
hide
)
Description:
Bug 40993: Add Apache RewriteRule for hitting value_builder pages
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2025-12-08 12:28:40 UTC
Size:
1.60 KB
patch
obsolete
>From 399204ec4f667862cd8cd1acf9e7a2cbbfb3e9dc Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Fri, 10 Oct 2025 11:54:46 +0200 >Subject: [PATCH] Bug 40993: Add Apache RewriteRule for hitting value_builder > pages > >Test plan: >Copy this file to /etc/koha. >Restart Apache. >Login to staff and hit a value builder page directly, e.g.: >YOUR_SERVER/cgi-bin/koha/cataloguing/value_builder/marc21_field_005.pl >Verify that you got redirected to 403. >Verify that you can still edit a biblio record and open e.g. the leader >plugin form. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Signed-off-by: David Cook <dcook@prosentient.com.au> >Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk> >--- > debian/templates/apache-shared-intranet.conf | 2 ++ > 1 file changed, 2 insertions(+) > >diff --git a/debian/templates/apache-shared-intranet.conf b/debian/templates/apache-shared-intranet.conf >index 1919288b120..0b8aa401794 100644 >--- a/debian/templates/apache-shared-intranet.conf >+++ b/debian/templates/apache-shared-intranet.conf >@@ -14,6 +14,8 @@ ScriptAlias /search "/usr/share/koha/intranet/cgi-bin/catalogue/search.pl" > # Protect dev package install > RewriteEngine on > RewriteRule ^/cgi-bin/koha/(C4|debian|docs|etc|installer/data|install_misc|Koha|misc|selenium|t|test|tmp|xt)/|\.PL$ /notfound [PT] >+# Do not allow hitting value_builder pages directly >+RewriteRule ^/cgi-bin/koha/cataloguing/value_builder/ /cgi-bin/koha/errors/403.pl [PT] > > RewriteRule ^/bib/([^\/]*)/?$ /cgi-bin/koha/catalogue/detail.pl?biblionumber=$1 [PT] > RewriteRule ^/isbn/([^\/]*)/?$ /search?q=isbn:$1 [PT] >-- >2.52.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 40993
:
187723
|
188185
|
188186
|
188187
| 190284 |
190285
|
191367
|
191368