(CVE-2023-2971) Typora Local File Disclosure (Patch Bypass)
Typora before 1.7.0-dev on Windows and Linux mishandles paths in the typora://app/typemark/ scheme, letting a crafted webpage read local files and send them to a remote server. This can be triggered when a user opens a malicious markdown file or pastes text from a malicious webpage into Typora.
starlabs.sg
Published on starlabs.sg
Typora is a popular cross-platform markdown editor that allows users to create and edit markdown files with a real-time preview feature. It supports various formatting options such as headings, bold, italics, and more.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely improper path handling in the typora://app/typemark/ scheme allows traversal outside the intended directory, enabling local file access.
Impact
A crafted webpage could access local files and exfiltrate them to remote web servers, but only if the user opens a malicious markdown file or pastes text from a malicious webpage into Typora.
What the attacker needed
User opens a malicious markdown file; or pastes text from a malicious webpage
The fix
It should be fixed by correcting the path handling in Typora 1.7.0-dev and later.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
Typora is a markdown editor that can open special typora:// links. A flaw in how it handles file paths in those links lets a malicious webpage or markdown file make Typora read files on your computer and send them to an attacker. You would need to open a bad markdown file or paste text from a bad webpage into Typora for this to happen.
What is Path traversal?
Input that builds a file path escapes the intended folder, reading or writing files the application should never touch.