bugGNU Screen - Bugs: bug #62097, UTF-8 should be limited to valid...


bug #62097: UTF-8 should be limited to valid range

Submitter:  Carl Drougge <drougge>
Submitted:  Tue 22 Feb 2022 07:24:08 PM UTC
Category:  Program Logic Severity:  3 - Normal
Priority:  * 5 - Normal Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open Release:  None
Fixed Release:  None Planned Release:  None
Work Required:  None
* Mandatory Fields

Add a New Comment (Rich Markup)

Comment Type & Canned Response:
       No canned response available


Tue 22 Feb 2022 07:45:30 PM UTC, comment #1: 

Sorry, I should have actually tried the V5 patch and noticed the compiler warning (harmless though it is). Fixed patch attached.

(file #52906)

Carl Drougge <drougge>
Tue 22 Feb 2022 07:24:08 PM UTC, original submission:  

The current UTF-8 encoding can emit invalid UTF-8 sequences for out of range unicode values. I have attached patches for both V4 and V5.

The unpatched V4 code also contains clearly incorrect logic for overlong UTF-8 sequences that modern compilers will warn about (which I have removed).

Carl Drougge <drougge>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by drougge (Submitted the item)

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.





    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-02-22 drougge Attached File- Added 0001-UTF-8-Replace-out-of-range-unicode-with-U-FFFD.v5.again.patch, #52906
    2022-02-22 drougge Attached File- Added 0001-UTF-8-Replace-out-of-range-unicode-with-U-FFFD.v4.patch, #52904
        Attached File- Added 0001-UTF-8-Replace-out-of-range-unicode-with-U-FFFD.v5.patch, #52905

    Back to the top

    Powered by Savane 3.9