示例无效的utf8字符串? [英] Example invalid utf8 string?

查看:217
本文介绍了示例无效的utf8字符串?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在测试我的某些代码如何处理不良数据,并且我需要一些无效UTF-8的字节序列.

I'm testing how some of my code handles bad data, and I need a few series of bytes that are invalid UTF-8.

您能否发布一些理想的解释,以解释它们为什么不好/在哪里得到的?

Can you post some, and ideally, an explanation of why they are bad/where you got them?

推荐答案

看看您会发现许多UTF-8不规则的示例,包括寂寞的起始字节,丢失的连续字节,超长序列等.

You'll find examples of many UTF-8 irregularities, including lonely start bytes, continuation bytes missing, overlong sequences, etc.

这篇关于示例无效的utf8字符串?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆