Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle non-ASCII-only in AS::MessagePack#signature?
Because `ActiveSupport::MessagePack::Serializer::SIGNATURE` includes a non-ASCII-only byte (`"\xCC"`), it raises `Encoding::CompatibilityError` when compared with another string that is not encoded with `Encoding::BINARY` and also includes a non-ASCII-only byte. To prevent that, this commit changes `AS::MessagePack#signature?` to directly compare the first two bytes of both strings. Fixes #48196.
- Loading branch information