Index: chrome/browser/extensions/api/certificate_provider/certificate_provider_api.h |
diff --git a/chrome/browser/extensions/api/certificate_provider/certificate_provider_api.h b/chrome/browser/extensions/api/certificate_provider/certificate_provider_api.h |
index bc4ec19752bd8f6605fc8805833953e044b7da47..77e124aa3d397939bd45d4cab5c4fc08cd71f90e 100644 |
--- a/chrome/browser/extensions/api/certificate_provider/certificate_provider_api.h |
+++ b/chrome/browser/extensions/api/certificate_provider/certificate_provider_api.h |
@@ -45,6 +45,34 @@ class CertificateProviderInternalReportSignatureFunction |
CERTIFICATEPROVIDERINTERNAL_REPORTSIGNATURE); |
}; |
+// The maximum number of times per minute, extension is allowed to show PIN |
+// dialog again after user closed the previous one. |
+extern const int MAX_CLOSED_DIALOGS_PER_10_MINUTES; |
+ |
+class CertificateProviderShowPinDialogFunction |
+ : public UIThreadExtensionFunction { |
+ private: |
+ ~CertificateProviderShowPinDialogFunction() override; |
+ ResponseAction Run() override; |
+ bool ShouldSkipQuotaLimiting() const override; |
+ void GetQuotaLimitHeuristics( |
+ extensions::QuotaLimitHeuristics* heuristics) const override; |
+ void OnInputReceived(const base::string16& value); |
+ |
+ DECLARE_EXTENSION_FUNCTION("certificateProvider.showPinDialog", |
+ CERTIFICATEPROVIDER_SHOWPINDIALOG); |
+}; |
+ |
+class CertificateProviderClosePinDialogFunction |
+ : public UIThreadExtensionFunction { |
+ private: |
+ ~CertificateProviderClosePinDialogFunction() override; |
+ ResponseAction Run() override; |
+ |
+ DECLARE_EXTENSION_FUNCTION("certificateProvider.closePinDialog", |
+ CERTIFICATEPROVIDER_CLOSEPINDIALOG); |
+}; |
+ |
} // namespace extensions |
#endif // CHROME_BROWSER_EXTENSIONS_API_CERTIFICATE_PROVIDER_CERTIFICATE_PROVIDER_API_H_ |