1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef IOS_WEB_WEB_STATE_WK_WEB_VIEW_SSL_ERROR_UTIL_H_
6 #define IOS_WEB_WEB_STATE_WK_WEB_VIEW_SSL_ERROR_UTIL_H_
8 #import <Foundation/Foundation.h>
16 // NSErrorPeerCertificateChainKey from NSError's userInfo dict.
17 extern NSString
* const kNSErrorPeerCertificateChainKey
;
19 // Returns YES if geven error is a SSL error.
20 BOOL
IsWKWebViewSSLError(NSError
* error
);
22 // Fills SSLInfo object with information extracted from |error|. Callers are
23 // responsible to ensure that given |error| is an SSL error by calling
24 // |web::IsSSLError| function.
25 void GetSSLInfoFromWKWebViewSSLError(NSError
* error
, net::SSLInfo
* ssl_info
);
29 #endif // IOS_WEB_WEB_STATE_WK_WEB_VIEW_SSL_ERROR_UTIL_H_