OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/callback_forward.h" | 12 #include "base/callback_forward.h" |
13 #include "content/public/browser/file_descriptor_info.h" | 13 #include "content/public/browser/file_descriptor_info.h" |
14 #include "content/public/common/content_client.h" | 14 #include "content/public/common/content_client.h" |
15 #include "content/public/common/window_container_type.h" | 15 #include "content/public/common/window_container_type.h" |
16 #include "net/base/mime_util.h" | |
16 #include "net/cookies/canonical_cookie.h" | 17 #include "net/cookies/canonical_cookie.h" |
17 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNotificationPresen ter.h" | 18 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNotificationPresen ter.h" |
18 | 19 |
19 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 20 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
20 #include "base/global_descriptors_posix.h" | 21 #include "base/global_descriptors_posix.h" |
21 #endif | 22 #endif |
22 | 23 |
23 | 24 |
24 class CommandLine; | 25 class CommandLine; |
25 class FilePath; | 26 class FilePath; |
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
316 | 317 |
317 // Selects a SSL client certificate and returns it to the |callback|. If no | 318 // Selects a SSL client certificate and returns it to the |callback|. If no |
318 // certificate was selected NULL is returned to the |callback|. | 319 // certificate was selected NULL is returned to the |callback|. |
319 virtual void SelectClientCertificate( | 320 virtual void SelectClientCertificate( |
320 int render_process_id, | 321 int render_process_id, |
321 int render_view_id, | 322 int render_view_id, |
322 const net::HttpNetworkSession* network_session, | 323 const net::HttpNetworkSession* network_session, |
323 net::SSLCertRequestInfo* cert_request_info, | 324 net::SSLCertRequestInfo* cert_request_info, |
324 const base::Callback<void(net::X509Certificate*)>& callback) {} | 325 const base::Callback<void(net::X509Certificate*)>& callback) {} |
325 | 326 |
326 // Adds a downloaded client cert. The embedder should ensure that there's | 327 // Adds a new installable crypto file. This is a downloaded resource |
327 // a private key for the cert, displays the cert to the user, and adds it upon | 328 // which satisfies net::IsSupportedCryptoMimeType(mime_type). |
328 // user approval. If the downloaded data could not be interpreted as a valid | 329 // Typically used to install an x509 user certificate. |
329 // certificate, |cert| will be NULL. | 330 // Note that it's up to the embedder to validate the data. |
330 virtual void AddNewCertificate( | 331 // |file_data| will be NULL if file_size is 0. |
332 virtual void AddNewCryptoFile( | |
Ryan Sleevi
2012/10/24 22:01:25
I would prefer the name "AddCertificates" be used
digit1
2012/10/25 13:57:38
yes, I wasn't a big fan of "CryptoFile", but since
| |
331 net::URLRequest* request, | 333 net::URLRequest* request, |
332 net::X509Certificate* cert, | 334 net::CryptoFileType file_type, |
335 const void* file_data, | |
336 size_t file_size, | |
333 int render_process_id, | 337 int render_process_id, |
334 int render_view_id) {} | 338 int render_view_id) {} |
335 | 339 |
336 // Returns a a class to get notifications about media event. The embedder can | 340 // Returns a a class to get notifications about media event. The embedder can |
337 // return NULL if they're not interested. | 341 // return NULL if they're not interested. |
338 virtual MediaObserver* GetMediaObserver(); | 342 virtual MediaObserver* GetMediaObserver(); |
339 | 343 |
340 // Asks permission to show desktop notifications. | 344 // Asks permission to show desktop notifications. |
341 virtual void RequestDesktopNotificationPermission( | 345 virtual void RequestDesktopNotificationPermission( |
342 const GURL& source_origin, | 346 const GURL& source_origin, |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
469 // This is called on a worker thread. | 473 // This is called on a worker thread. |
470 virtual | 474 virtual |
471 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( | 475 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( |
472 const GURL& url); | 476 const GURL& url); |
473 #endif | 477 #endif |
474 }; | 478 }; |
475 | 479 |
476 } // namespace content | 480 } // namespace content |
477 | 481 |
478 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 482 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
OLD | NEW |