Skip to content

bytes.decode("utf-8") can crash if invalid utf8 is found. #3

@Ekdohibs

Description

@Ekdohibs

I never triggered the bug itself but this can be a security concern if we want to prevent potential (depending on how weechat handles unicode) remote crashes.
Using bytes.decode("utf-8", "replace") should fix the issue.

Also, note that packet handling does no error catching whatsoever, so even a buggy network connection might be able to crash the packet handler.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions