Uh oh!
There was an error while loading. Please reload this page.
Hash event UID to make sure it's not too long for PushProvider notifications - #19252
Conversation
782bfa3 to
79ed9fcComparekesselb
commented
Feb 1, 2020
tcitworld
commented
Feb 1, 2020
notifications Signed-off-by: Thomas Citharel <tcit@tcit.fr>
79ed9fc to
41fa057Comparetcitworld
commented
Feb 5, 2020
/backport to stable18 |
tcitworld
commented
Feb 5, 2020
/backport to stable17 |
| $eventDetails['calendar_displayname'] = $calendarDisplayName; | ||
| $eventUUID = (string) $vevent->UID; | ||
| // Empty Notification ObjectId will be catched by OC\Notification\Notification | ||
| $eventUUIDHash = $eventUUID ? hash('sha256', $eventUUID, false) : ''; |
There was a problem hiding this comment.
Notifications object ID is limited to 64 characters, event UID is not. A Sha256 hash is limited to 64 characters.
Seems to be the reason.
There was a problem hiding this comment.
And as it's happening through a background task the performance difference shouldn't be an issue.
nickvergessen
commented
Feb 6, 2020
THe thing is, that basically means we need to be able to resolve sha256 in the future for direct links to calendar events |
@nickvergessen Wouldn't we use |
szaimen
commented
Feb 22, 2020
Any progres here? :) |
nickvergessen
commented
Feb 25, 2020
link field is also limited to 4k chars. anyway. In worst case the calendar app has to do a mapping: "if event not found and uid.length === 64 check somewhere else for a reverse match" |
nickvergessen
commented
Feb 25, 2020
/backport to stable18 |
nickvergessen
commented
Feb 25, 2020
/backport to stable17 |
backport to stable18 in #19639 |
backport to stable17 in #19640 |
Notifications object ID is limited to 64 characters, event UID is not. A Sha256 hash is limited to 64 characters.