Bugzilla – Attachment 154164 Details for
Bug 34369
Add CSRF protection to system preferences
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34369: Pass csrf token from syspref API client (for Vue app)
Bug-34369-Pass-csrf-token-from-syspref-API-client-.patch (text/plain), 1.38 KB, created by
Jonathan Druart
on 2023-08-03 08:04:03 UTC
(
hide
)
Description:
Bug 34369: Pass csrf token from syspref API client (for Vue app)
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2023-08-03 08:04:03 UTC
Size:
1.38 KB
patch
obsolete
>From c6b71099b6b79bfeed500df6d003233d82d9dd2b Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 1 Aug 2023 09:12:10 +0200 >Subject: [PATCH] Bug 34369: Pass csrf token from syspref API client (for Vue > app) > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > .../prog/js/vue/fetch/system-preferences-api-client.js | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/fetch/system-preferences-api-client.js b/koha-tmpl/intranet-tmpl/prog/js/vue/fetch/system-preferences-api-client.js >index 9cfcabf08f4..f37f3252ea4 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/vue/fetch/system-preferences-api-client.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/vue/fetch/system-preferences-api-client.js >@@ -16,7 +16,11 @@ export class SysprefAPIClient extends HttpClient { > update: (variable, value) => > this.post({ > endpoint: "", >- body: "pref_%s=%s".format(variable, value), >+ body: "pref_%s=%s&csrf_token=%s".format( >+ variable, >+ value, >+ csrf_token >+ ), > headers: { > "Content-Type": > "application/x-www-form-urlencoded;charset=utf-8", >-- >2.25.1
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 34369
:
154121
|
154122
|
154163
|
154164
|
154165
|
154237
|
154238
|
154239