Files
kolibrios/programs/develop/libraries
Swarnadeep Paul 05ecfe005c Add robust UTF-8 character validation and length check
Implemented the `is_valid_utf8_char` procedure to safely validate UTF-8
sequences and return their byte length (1-4, or 0 if invalid).

This routine implements strict Unicode compliance checks, including:
- Rejection of overlong encodings (e.g., checking 0xC0/0xC1, and strict
bounds for 0xE0/0xF0).
- Prevention of surrogate half decoding (restricting 0xED bounds).
- Enforcement of the maximum Unicode scalar value limit (U+10FFFF).
- Safe handling of null-terminators and truncated sequences.

This provides a secure foundation for upgrading the codepoint and
grapheme counting functions in upcoming commits.
2026-03-21 12:37:43 +05:30
..
2014-09-12 15:15:23 +00:00
2021-05-22 19:09:11 +00:00
2014-09-12 15:15:23 +00:00
2024-06-03 00:34:02 +01:00
2013-10-02 16:44:03 +00:00
2015-11-27 09:20:48 +00:00
2015-12-02 15:56:46 +00:00
2024-01-04 22:20:35 +00:00
2014-09-12 15:15:23 +00:00
2014-09-12 15:15:23 +00:00
2024-06-03 00:34:02 +01:00
2014-09-12 15:15:23 +00:00
2012-11-05 11:12:45 +00:00
2014-09-12 15:15:23 +00:00