How to create a SQL injection attack with Shift-JIS and CP932?
问题 I'm writing some unit tests to ensure my code isn't vulnerable to SQL injection under various charsets. According to this answer, you can create a vulnerability by injecting \xbf\x27 using one of the following charsets: big5 , cp932 , gb2312 , gbk and sjis This is because if your escaper is not configured correctly, it will see the 0x27 and try to escape it such that it becomes \xbf\x5c\x27 . However, \xbf\x5c is actually one character in these charsets, thus the quote ( 0x27 ) is left