Commit Graph
17613 Commits
Author SHA1 Message Date
Jan Kahmen 045a0b9c0a fix(mail): escape mail data placed in attributes of a compiled part
the generic attribute writer used for these two spots does not escape what it
writes, so a value taken from the message ends the attribute and starts a new
one. both are inside a part that is compiled, which is where an injected
handler runs.

* the organizer link took inEvent.organizer.email verbatim. a value such as
  mailto:x@y" onpointerover="... produced a live handler on the anchor, and an
  entity encoded scheme such as javascript: reached the href, where the
  browser decodes it. the href is now built as mailto: plus the parsed address
  and escaped as an attribute value.

* the attachment name paragraph of the image and the link viewer took
  filenameForDisplay verbatim. a quote inside an RFC 2231 encoded filename
  ended the title attribute. the writer escapes & < > there but not the quote,
  so the accessor drops the quote instead of escaping it, which keeps a plain
  filename such as A&B.pdf unchanged in the tooltip.

the img title of the image viewer is left alone: attributes of that element are
escaped by the framework already.
2026-08-17 23:48:41 +02:00
Jan Kahmen 8813677ecb fix(core): keep the @import cleanup working in stringWithoutHTMLInjection
the trailing while loop reuses the regex variable, which by then points at the
angular brace pattern whenever stripAngular is YES. that pattern has two
capture groups while the loop substitutes $1@im****$3, so NSRegularExpression
raises NSInvalidArgumentException and the NS_HANDLER swallows it.

give the @import pattern its own variable and use it in both the replacement
and the loop. the replacement also used the template of the block above, which
dropped the whole style element instead of masking the @import in place, so
test_stringWithoutHTMLInjection failed. it passes again, and a case with
stripAngular YES covers the loop.
2026-08-17 23:03:41 +02:00
Jan Kahmen 0d66d7503d fix(mail): stop interpreting iMIP card text fields as markup
the whole server built html of an iMIP card is rendered through sg-compile
(Message.service.js sets part.compile for UIxMailPartICalViewer), and the user
comment and the description are emitted with escapeHTML="NO". event data from
the invitation is therefore both an angular template and raw html.

47133fdf3 closed the description against interpolation with ng-non-bindable.
this closes both paths for every remaining field:

* ng-non-bindable on the user comment, the location, the organizer common name
  and the raw body shown when the calendar cannot be parsed
* the user comment and the description are read through accessors that escape
  them, so the url detection and insertBR produce the only markup left in the
  output

the marker sits on the leaf containers, not on md-card-content, so the buttons,
the delegation autocomplete and the attendee chips keep being compiled. url
detection still turns a bare url in a comment or a description into a link.
2026-08-17 23:03:41 +02:00
Hivert Quentin f7fce46371 chore(release): 5.12.10 SOGo-5.12.10 2026-08-13 10:17:59 +02:00
Hivert Quentin 2a8f20e080 i18n(hu): Update Hungarian translations 2026-08-13 10:03:55 +02:00
Hivert Quentin 41e2b7b1ab fix(bug): escape angularJS only if needed to keep legitimate directive 2026-08-12 10:53:51 +02:00
Hivert Quentin f0c23407bf chore(sendmail): disable sendmail for now 2026-08-11 17:34:50 +02:00
Hivert Quentin 1caa25711f fix(bug): incorrect method called 2026-08-11 17:06:27 +02:00
Hivert Quentin a156f4ce9f fix(passwordRecoveyr): get the domain from the user mail 2026-08-10 19:35:31 +02:00
Hivert Quentin 47133fdf3b fix(mail): escape angularJS directive for description 2026-08-10 19:34:25 +02:00
Hivert Quentin 78807d01ae fix(dav): properly parse MKCOL request 2026-08-10 19:31:32 +02:00
smizrahi aefc14b265 feat(sogo-tool): add init-user command to create a user's personal folders and preferences without a login 2026-07-15 15:03:37 +02:00
Vincent BonamyandQHivert a99a848064 Revert cleanup of usesCASAuthentication on c3234882eb - useful for CAS-specific frontend recovery logic 2026-06-15 08:56:23 +02:00
Hivert Quentin 3a78a3bbb4 fix(calendar): do not transmit og http status to external calendar 2026-06-09 10:26:58 +02:00
smizrahiandHivert Quentin f11f34cdef fix(mail): escape References/Organization/Newsgroups headers in HTML forward so message-id chevrons aren't parsed as HTML tags hiding the quoted body. Closes #6046. 2026-06-04 11:53:58 +02:00
smizrahiandHivert Quentin 39a35830e9 fix(ckeditor): Sync resized image width/height into style and HTML attributes so Outlook and other mail clients ignoring CSS aspect-ratio render the correct dimensions. Closes #6169. 2026-06-04 11:53:58 +02:00
smizrahiandHivert Quentin 6904911ac1 fix(mail): Some links broken in HTML rendering due to libxml2 (SOPE) only supporting HTML4 — when an anchor has no content between its opening and closing tags, store it and re-open it around the next element, closing </a> after that element's end tag. Closes #5961. Closes #6172. 2026-06-04 11:53:58 +02:00
Hivert Quentin fbd5bd19c6 Merge branch 'master' of github.com:Alinto/sogo 2026-05-29 01:00:09 -04:00
Hivert Quentin 97bbd7ed7f fix(tool): wrong method called 2026-05-28 14:57:59 +02:00
Hivert Quentin b5c83f5839 fix(event): clean import of event 2026-05-28 13:27:08 +02:00
Hivert Quentin b978ceb020 Merge branch 'master' of github.com:Alinto/sogo 2026-05-28 01:00:08 -04:00
Hivert Quentin d97472b93c chore(release): 5.12.9 SOGo-5.12.9 2026-05-27 10:25:16 +02:00
Hivert Quentin d823cadda0 i18n(es_ES): Update SpanishSpain translations 2026-05-27 10:22:10 +02:00
Hivert Quentin fd427f9196 i18n(ca): Update Catalan translations 2026-05-27 10:22:10 +02:00
Hivert Quentin b18f1a09f5 fix(event): clean import of event 2026-05-26 10:30:02 +02:00
Hivert Quentin accc1c2302 chore(js/css): update generated files 2026-05-20 01:01:08 -04:00
Hivert Quentin 6e590115fb fix(mail): do not encode non-html element 2026-05-19 10:01:46 +02:00
Hivert Quentin c45233c11e fix(pref): prevent onevent cleaning to remove legitimate words 2026-05-19 09:30:58 +02:00
Hivert Quentin 27ad4ddbab chore(js/css): update generated files 2026-05-13 01:01:07 -04:00
Jordi MallachandQHivert e27b083213 Update onEvent test to match expectation after the XSS fixes 2026-05-12 13:19:09 +02:00
Hivert Quentin be440baa23 fix(mail): render the subject without html when searching 2026-05-12 08:52:18 +02:00
Hivert Quentin 28c4daa504 chore(release): 5.12.8 SOGo-5.12.8 2026-05-11 09:20:31 +02:00
Hivert Quentin 4e5c2516d4 i18n(pl): Update Polish translations 2026-05-11 09:16:30 +02:00
Hivert Quentin baf26ae19d chore(js/css): update generated files 2026-05-09 01:01:08 -04:00
Hivert Quentin 0cb21f8fb9 fix(mail): correctly render mail when searching 2026-05-08 11:02:52 +02:00
Hivert Quentin d7232618e6 fix(css): do not escape css if missing 2026-05-08 10:25:54 +02:00
Hivert Quentin 93b82a0f60 fix(openid): check the userinfo mail + avoid infinite loop 2026-05-05 10:39:38 +02:00
Hivert Quentin 2af96d10d5 chore(js/css): update generated files 2026-05-05 01:01:07 -04:00
Hivert Quentin 29d0bbc9eb fix(mail): render properly the subject v2 2026-05-03 16:57:25 +02:00
Hivert Quentin 67ce01ec2a fix(mail): sanitise mail with ics (invitation to event) 2026-05-03 15:08:15 +02:00
Hivert Quentin 6119d6cf23 fix(mail): remove negative margin from mail 2026-04-24 09:16:31 +02:00
Hivert Quentin 0ddc4281b8 chore(js/css): update generated files 2026-04-24 01:01:04 -04:00
Hivert Quentin b7641be5c8 fix(UI): render properly the subject 2026-04-23 16:39:43 +02:00
Hivert Quentin d902756aaf fix(acl): fix folder path 2026-04-21 13:52:19 +02:00
Hivert QuentinandQHivert f9b71059f4 fix(acl): only add existing uid 2026-04-20 09:08:40 +02:00
Hivert Quentin ee2ebbb81c chore(js/css): update generated files 2026-04-02 01:01:12 -04:00
Hivert Quentin 6f0b4f9d05 chore(release): 5.12.7 SOGo-5.12.7 2026-03-30 10:19:00 +02:00
Hivert Quentin 40228c619b i18n(all): update several translations 2026-03-30 10:06:08 +02:00
Hivert Quentin d7f02b6083 fix(typo): pass the correct arg to checkLogin 2026-03-26 09:07:05 +01:00
tkerivenandGitHub 453ddceae9 Merge pull request #379 from Alinto/fix_6065
fix(sql): use proper sql adaptor for usr source
2026-03-25 17:20:52 +01:00