Executive brief
Joplin is a free and open-source note-taking application available across desktop and mobile platforms. A vulnerability in versions before 2.0.9 allows attackers to inject malicious code through button and form elements embedded in note text, which is then executed in a user's browser when they view the affected note. This could allow an attacker to steal a user's session data, credentials, or manipulate the contents of their notes.
Technical details
Joplin before 2.0.9 contains a Cross-site Scripting (XSS) vulnerability (CWE-79) in the note rendering engine that fails to properly filter form-related HTML elements (button, form, input, select, textarea, option, optgroup) from note bodies. An attacker can craft a note containing malicious form elements with event handlers or attributes that execute arbitrary JavaScript when the note is rendered. The attack requires user interaction (opening a malicious note) but no authentication is required for note creation if sharing is enabled. The vulnerability affects both the desktop and mobile applications. The fix, applied in version 2.0.9, adds these form elements to the disallowed tags list in the HTML sanitization logic.
Affected products
- Joplin Joplin before 2.0.9
Timeline
- 2021-08-03: disclosed
- 2022-05-24: advisory
- 2021: patched: Fixed in version 2.0.9