Skip to content

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

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.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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