Package: purple-xmpp-http-upload
Version: 0.2.4-2
Severity: normal
Tags: patch
Uploads fail with HTTP 401 against Prosody 13 (mod_http_file_share), and Pidgin
reports "cancelled the transfer". Cause: src/jabber_http_file_upload.c reads the
XEP-0363 slot's <header name="Authorization"> under the British spelling
("Authorisation") and sends it under that name, so the token never reaches the
server. Prosody 13 requires the header.
The attached one-line patch looks the header up under the standard name (keeping
the misspelling as a fallback) and sends "Authorization:". Upstream
(github.com/Junker/purple-xmpp-http-upload) is archived since 2025-09, so this
cannot
be fixed there.Description: Send the XEP-0363 slot token as "Authorization", not "Authorisation"
The plugin read the slot's <header name="Authorization"> under the British
spelling and sent it under that name, so the token never reached the server.
Prosody's mod_http_file_share (13.x) requires it and answers 401; Pidgin shows
the transfer as cancelled. Accept both spellings in the slot, send the standard
one. Upstream (github.com/Junker/purple-xmpp-http-upload) is archived (2025-09).
Author: FA <[email protected]>
Origin: vendor
Forwarded: not-needed, upstream archived; filed with Debian instead
Last-Update: 2026-11-19
--- purple-xmpp-http-upload-0.2.4.orig/src/jabber_http_file_upload.c
+++ purple-xmpp-http-upload-0.2.4/src/jabber_http_file_upload.c
@@ -95,11 +95,18 @@ static void jabber_hfu_http_send_connect
httpurl = purple_http_url_parse(hfux->put_url);
if (str_equal(js_data->ns, NS_HTTP_FILE_UPLOAD_V0)) {
- char *a = g_hash_table_lookup(hfux->put_headers, "Authorisation");
+ /* XEP-0363 names the header "Authorization" (and so does every server,
+ * Prosody's mod_http_file_share included, which answers 401 without it).
+ * The original looked it up and sent it as "Authorisation", so the token
+ * never reached the server. Accept either spelling in the slot, always
+ * send the standard one. -- fpa 2026-11-19 */
+ char *a = g_hash_table_lookup(hfux->put_headers, "Authorization");
char *c = g_hash_table_lookup(hfux->put_headers, "Cookie");
char *e = g_hash_table_lookup(hfux->put_headers, "Expires");
+ if(!a)
+ a = g_hash_table_lookup(hfux->put_headers, "Authorisation");
if(a)
- auth = g_strdup_printf("Authorisation: %s\r\n", a);
+ auth = g_strdup_printf("Authorization: %s\r\n", a);
if(c)
cookie = g_strdup_printf("Cookie: %s\r\n", c);
if(e)