diff options
Diffstat (limited to 'xmpp-vala')
-rw-r--r-- | xmpp-vala/src/module/xep/0363_http_file_upload.vala | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/xmpp-vala/src/module/xep/0363_http_file_upload.vala b/xmpp-vala/src/module/xep/0363_http_file_upload.vala index 0acc9602..996128e2 100644 --- a/xmpp-vala/src/module/xep/0363_http_file_upload.vala +++ b/xmpp-vala/src/module/xep/0363_http_file_upload.vala @@ -72,6 +72,11 @@ public class Module : XmppStreamModule { Idle.add((owned) callback); return; } + if (!url_get.down().has_prefix("https://") || !url_put.down().has_prefix("https://")) { + e = new HttpFileTransferError.SLOT_REQUEST("Error getting upload/download url: Received non-https URL from server"); + Idle.add((owned) callback); + return; + } slot_result.headers = new HashMap<string, string>(); |