Bug #105668 | rpad function is not multibyte safe | ||
---|---|---|---|
Submitted: | 23 Nov 2021 3:19 | Modified: | 23 Nov 2021 4:40 |
Reporter: | x j | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Server: DML | Severity: | S3 (Non-critical) |
Version: | 8.0.26, 5.7, 8.0.27 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[23 Nov 2021 3:19]
x j
[23 Nov 2021 4:40]
MySQL Verification Team
Hello x j, Thank you for the report and test case. regards, Umesh
[24 Nov 2021 12:05]
Tor Didriksen
Posted by developer: Fixed by the patch for Bug#32668730: Change resolving and execution for LPAD and RPAD Bug#33238711: heap-buffer-overflow in Item_func_rpad::val_str mysql> select hex(rpad(a, 5, 0xe4ba8c)), rpad(a, 5, 0xe4ba8c) from t; +--------------------------------+----------------------+ | hex(rpad(a, 5, 0xe4ba8c)) | rpad(a, 5, 0xe4ba8c) | +--------------------------------+----------------------+ | E4B880E4BA8CE4BA8CE4BA8CE4BA8C | 一二二二二 | +--------------------------------+----------------------+ 1 row in set (0,00 sec)