▄▄             ▄▄▄  ▄▄▄ Power
█  █ ▄▄▄▄ ▄▄▄▄▄ █  █ █  █
█▄▄█ █▄▄▄ █ █ █ █▀▀▄ █▀▀▄
█  █ ▄▄▄█ █ █ █ █▄▄▀ █▄▄▀

/ aa about.it ad amd64 and.who api asm asmbb asmbb.features authentication bbcode best bugs cares chat common debian deck design dll docker email embed fast feature files fossil fresh.ide friendly gamedev heap help hiawatha i18n incredible interop learning libfresh limit links linux mailing.list meme meta.http-equiv minimag money mysql neo nginx numbers orly os outage pass password post-by-email programmers programming proile read-by-email resources safety script.alert.xss secret seo skins sodom source sourcecode subdirectory subforum support tags templates test test123 type very.ugly video work xss игнат котики парола русский тест уеб.програмиране хабр.наполеон
Categories Threads

Experimental BBCode parser needs tests RSS

The library

In order to allow more easy migrating from the old forum engines to AsmBB, I started to write a BBCode markup parser library.

After finished and tested, it will be included in AsmBB engine this way providing second optional markup language for better user experience.

The sources of the engine are of course open and located in the repository here: https://asm32.info/fossil/repo/bbcode

In the attached file (at the end of the post) I included precompiled binaries of the test application, for Linux ( bbcode ) and Windows ( bbcode.exe ), together with my BBCode test file ( test.bbcode ) and some small images, needed for proper display of the rendered page in the browser.

The library generates HTML5 output. Notice that in HTML5 some tags are allowed to not be closed. In the generated output such tags are: html, head, body, p and li. All other tags must be closed and if not, it should be considered a bug and fixed.


The binaries for Windows and Linux read the STDIN for BBCode and write the HTML5 output to STDOUT. So in order to convert some BBCode file you need to enter in the console:

./bbcode < test.bbcode > test.html

In Windows you may remove the ./ prefix.

How you can help the project

The project needs more tests.

Try to modify test.bbcode or create your own BBCode test file that crashes the program, or create broken HTML that the browsers can't display properly. Consider the crashes and possible XSS injections as a primary targets.

Report this broken BBCode to me (email to johnfound at asm32 dot info) or attach a file in this thread. I will fix the bugs and update the attached archive accordingly.

Thanks in advance!

Attached files:
FileSizeUploadedDownloadsMD5 hash
bbcode.tar.gz78064 bytes26.09.20181491d771e0383d1a3f012deb771751bd840
AsmBB v2.5 (check-in: d3a7fac8228a901e); SQLite v3.27.2 (check-in: bd49a8271d650fa8);

©2016..2018 John Found; Licensed under EUPL.
Powered by Assembly language
Created with Fresh IDE

Icons are made by Egor Rumyantsev, vaadin and icomoon from www.flaticon.com