Skip to content

fix: constrain rendered markdown link and image destinations - #23

Closed
Alexi5000 wants to merge 7 commits into
OpenKnots:mainfrom
Alexi5000:fix/markdown-url-boundary
Closed

Alexi5000 wants to merge 7 commits into
OpenKnots:mainfrom
Alexi5000:fix/markdown-url-boundary

Conversation

@Alexi5000

Copy link
Copy Markdown

The markdown renderer forwards link/image URLs unchanged. Filter the final parsed block tree recursively so file, data, vbscript, javascript and credential-bearing URLs cannot become active destinations; retain HTTP(S), relative links and mailto/tel links. Seven React-render regressions cover nested lists, image destinations, text/formatting and fenced code; six fail with the original unfiltered tree. All112 tests, typecheck and static frontend production build pass; browser rendering confirms only safe link remains. Existing regex normalizer findings are not dismissed; React renders its output as escaped text, and a broader formatting migration is out of scope.

Alexi5000 and others added 7 commits October 17, 2026 23:26
Co-authored-by: zocomputer <help@zocomputer.com>
Co-authored-by: zocomputer <help@zocomputer.com>
* fix: refresh security dependencies and prefer native secret scanner

* fix: declare recursive callbacks safely for current React lint rules

---------

Co-authored-by: zocomputer <help@zocomputer.com>
Co-authored-by: zocomputer <help@zocomputer.com>
)

* fix: validate preview and Spotify URLs and protect token-store keys

* fix: use maps for externally keyed token updates

---------

Co-authored-by: zocomputer <help@zocomputer.com>
Co-authored-by: zocomputer <help@zocomputer.com>
@Alexi5000

Copy link
Copy Markdown
Author

Closing because this repair is being validated in the maintained Alexi5000/BobKnots fork; this PR targeted the upstream repository unintentionally.

@Alexi5000 Alexi5000 closed this Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant