-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Appropriate length check in Notification.php #35015
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There is an issue(bug) when using UTF-8 symbols in any method, which checks the length of string as `isset($id[64])`. You can set only 32 UTF-8 symbols because they are 2 byte, and this "array" check seems inapropriate in this case, as it throws unexpected exceptions. Signed-off-by: natoponen <[email protected]>
|
Thanks for your first pull request and welcome to the community! Feel free to keep them coming! If you are looking for issues to tackle then have a look at this selection: https://github.com/nextcloud/server/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22 |
|
/backport to stable25 |
|
/backport to stable24 |
|
/backport to stable23 |
|
The backport to stable24 failed. Please do this backport manually. |
|
The backport to stable25 failed. Please do this backport manually. |
|
The backport to stable23 failed. Please do this backport manually. |
|
/backport to stable24 |
|
/backport to stable25 |
|
/backport to stable23 |
|
The backport to stable24 failed. Please do this backport manually. |
|
The backport to stable23 failed. Please do this backport manually. |
|
The backport to stable25 failed. Please do this backport manually. |
|
/backport to stable25 |
|
/backport to stable24 |
|
/backport to stable23 |
|
The backport to stable23 failed. Please do this backport manually. |
|
/backport to stable23 |
|
This breaks on MySQL without utf8mb4 support. |
There is an issue(bug) when using UTF-8 symbols in any method, which checks the length of string as
isset($id[64])in Notification.php.You can set only 32 UTF-8 symbols because they are 2 byte, and this "array" check seems inapropriate in this case, as it throws unexpected exceptions for strings with length less than 64 symbols (in UTF-8).
Close #35016