Post

Replies

Boosts

Views

Activity

Reply to How to validate in a webview using the certificate of a cryptographic card
I extend this post with the method that I override of the webview, and that is missing in the previous code: func webView(_ webView: WKWebView, didReceive challenge: URLAuthenticationChallenge, completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) {    let method = challenge.protectionSpace.authenticationMethod    switch method {    case NSURLAuthenticationMethodClientCertificate:        sendClientCertificate(for: challenge, via: completionHandler)    default:     completionHandler(.performDefaultHandling, .none)    }   }
Mar ’23