Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2237)

Unified Diff: chrome/browser/push_messaging/push_messaging_service_impl.h

Issue 2697793004: Push API: Validate storage before returning cached subscriptions (Closed)
Patch Set: Fix include Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/push_messaging/push_messaging_service_impl.h
diff --git a/chrome/browser/push_messaging/push_messaging_service_impl.h b/chrome/browser/push_messaging/push_messaging_service_impl.h
index 04dd34d517ba2450db8e80e5c662a0db909e13e0..b2bb4f994832901b9e056c75c95f21dd5d0ed9cc 100644
--- a/chrome/browser/push_messaging/push_messaging_service_impl.h
+++ b/chrome/browser/push_messaging/push_messaging_service_impl.h
@@ -83,11 +83,13 @@ class PushMessagingServiceImpl : public content::PushMessagingService,
int64_t service_worker_registration_id,
const content::PushSubscriptionOptions& options,
const RegisterCallback& callback) override;
- void GetEncryptionInfo(const GURL& origin,
- int64_t service_worker_registration_id,
- const std::string& sender_id,
- const EncryptionInfoCallback& callback) override;
- void Unsubscribe(const GURL& requesting_origin,
+ void GetSubscriptionInfo(const GURL& origin,
+ int64_t service_worker_registration_id,
+ const std::string& sender_id,
+ const std::string& subscription_id,
+ const SubscriptionInfoCallback& callback) override;
+ void Unsubscribe(content::PushUnregistrationReason reason,
+ const GURL& requesting_origin,
int64_t service_worker_registration_id,
const std::string& sender_id,
const UnregisterCallback&) override;
@@ -170,9 +172,14 @@ class PushMessagingServiceImpl : public content::PushMessagingService,
const std::string& p256dh,
const std::string& auth_secret);
- // GetEncryptionInfo method --------------------------------------------------
+ // GetSubscriptionInfo methods -----------------------------------------------
+
+ void DidValidateSubscription(const std::string& app_id,
+ const std::string& sender_id,
+ const SubscriptionInfoCallback& callback,
+ bool is_valid);
- void DidGetEncryptionInfo(const EncryptionInfoCallback& callback,
+ void DidGetEncryptionInfo(const SubscriptionInfoCallback& callback,
const std::string& p256dh,
const std::string& auth_secret) const;

Powered by Google App Engine
This is Rietveld 408576698