vmg/sundown
FreeStandards compliant, fast, secure markdown processing library in C
About vmg/sundown
Sundown is a high-performance, security-focused Markdown parsing library written in C, originally based on the Upskirt library by Natacha Porté. It is fully compliant with the official Markdown v1.0.0 and v1.0.3 test suites and offers extensive optional extensions including fenced code blocks, tables, autolinks, and strikethrough. The library is UTF-8 aware, has been rigorously security audited to prevent DOS attacks and malicious HTML, and is used in production to render all Markdown content on GitHub. Sundown's parser is decoupled from its renderer, allowing easy customization and creation of custom renderers. It is optimized for speed, often outperforming other alternatives by up to 40x when wrapped in dynamic languages like Python or Ruby. The library has zero dependencies, consisting of just 3 C source files and headers, and is written in standard C99.
Key Features
Pros & Cons
- Fully standards compliant with official test suites
- Very high performance due to C implementation
- Security audited and hardened against attacks
- Extensible with custom renderers
- Zero dependencies and easy to integrate
- C library, requiring bindings for use from other languages
- Relatively low-level API, not suitable for end-users directly