Skip to content
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

feat(notifications_push_repository): Verify push notification signature #2659

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

provokateurin
Copy link
Member

Closes #213

We don't need to catch the exception, as we can not do anything about it and it should never happen, unless the Nextcloud server or the UnifiedPush provider are compromised.

@provokateurin provokateurin force-pushed the feat/notifications_push_repository/verify-notification-signature branch from 181c2f9 to a10e9de Compare November 17, 2024 21:02
base64.decode(signature),
);
if (!valid) {
throw Exception('Failed to verify push notification signature!');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should add a custom PushNotificationException instead of throwing a generic one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Verify signatures of incoming push notifications
2 participants