Comment by ekidd

Comment by ekidd 5 hours ago

1 reply

For security reasons, the correct answer on how process invalid UTF-8 is (and needs to be) "throw away the data like it's radioactive, and return an error." Otherwise you leave yourself wide open to validation bypass attacks at many layers of your stack.

modeless 5 hours ago

This is only true because the interpretation is not defined, so different implementations do different things.