]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Another corner case in url parsing
authorVsevolod Stakhov <vsevolod@rspamd.com>
Tue, 25 Oct 2022 06:14:42 +0000 (07:14 +0100)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Tue, 25 Oct 2022 06:14:42 +0000 (07:14 +0100)
src/libserver/url.c

index 7be9d020aa3582ede2f3b360705e1d416529d000..04069a85304443e5ce0394c367d67fbf609e4d8a 100644 (file)
@@ -2894,7 +2894,9 @@ url_web_end (struct url_callback_data *cb,
        if (last < cb->end && (*last == '>' && last != match->newline_pos)) {
                /* We need to ensure that url also starts with '>' */
                if (match->st != '<') {
-                       return FALSE;
+                       if (last + 1 < cb->end && g_ascii_isspace(last[1])) {
+                               return FALSE;
+                       }
                }
        }