com.apple.WebKit.Networking deny mach-lookup com.apple.diagnosticd

Our iOS Application use HTTPServer to get a map data and use WKWebView to display 3DMap.

We tried to start this application on iOS16, but it can not display 3DMap.

When I researched console log, I found below error.

kernel  Sandbox: com.apple.WebKit.Networking(693) deny(1) mach-lookup com.apple.diagnosticd

When HTTPServer is started, this error is occurred. This error is not occurred on iOS15.

If anyone know this error, Could you let me know why it occurred and how can I fix it?

When I researched console log, I found below error.

That’s almost certainly a red herring. It’s probably not log noise, in that it’s correlated with this problem, but I suspect it’s a symptom rather than a cause (WebKit is trying to contact diagnosticd to report the problem).

When HTTPServer is started, this error is occurred.

I’d like to clarify this. If you start the HTTP server without firing up the web view, do you still see this log entry?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Hi, eskimo.

Thank you for your reply.

I’d like to clarify this. If you start the HTTP server without firing up the web view, do you still see this log entry?

When I tried this, the error is not occurred! Also do not start http server and fire up the web view, the error is occurred.

So.. I guess this cause of this error is WKWebKit.

When I tried this, the error is not occurred!

OK. So the next step is to issue a request to your HTTP server to make sure it’s actually working properly. Keep WebKit out of the picture for the moment by issuing that request with NSURLSession. Does that work?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Hi, eskimo. Thank you for your reply.

OK. So the next step is to issue a request to your HTTP server to make sure it’s actually working properly. Keep WebKit out of the picture for the moment by issuing that request with NSURLSession. Does that work?

I get the below log when I started my application on iOS 15.

com.apple.WebKit.Networking [xxxxx Hostname#ef409651:32123 tcp, bundle id: [My application bundle id], url hash: bfa405ab, context: com.apple.CFNetwork.NSURLSession.{xxxxxx}{(null)}{Y}{2}, proc: xxxxxx, effective proc: xxxxxx, pid: 348] start

But when I started on iOS16, I can not get this message.

So I think NSURLSession is not working on iOS16.

So I think NSURLSession is not working on iOS16.

I’m not sure how you’re drawing that conclusion from that evidence.

My advice is that you write code that uses NSURLSession to issue a request to your server. If you do that, does it succeed? If not, what error do you get back?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Hi, eskimo. Thank you for your reply.

My advice is that you write code that uses NSURLSession to issue a request to your server. If you do that, does it succeed? If not, what error do you get back?

I wrote code that uses NSURLSession request to out server and tried to do it. It was succeed.. I'm not sure what wrong is ..

So, let me recap your current situation, just to make sure I understand it correctly:

  • Your app has an embedded web server.

  • You are able to request data from that web server using NSURLSession.

  • But the same request fails if you run it from your app’s WKWebView.

  • And this worked just fine on iOS 15.

Is that right?

Does this fail on real hardware? Or the simulator? Or both?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Hi, eskimo. Thank you for your reply.

Is that right?

Yes, all of them are right.

Does this fail on real hardware? Or the simulator? Or both?

Both of them fail..

Thanks in advance.

OK, then I’ve got nothing. I can’t think of any reason why the loopback request would work with NSURLSession but fail with WKWebView.

Are you able to reproduce this in a small test project? Note that you don’t need your full HTTP server there, you only need a listener that accepts and prints the incoming HTTP request. You’ll see one of two things:

  • The listener gets a connection from WKWebView. This tells you that the networking side of this is working and there’s something going wrong at the HTTP layer.

  • The listener does not get the connection. This tells you there’s a problem with the networking itself.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Hi, eskimo.

We tried getting http request with NSURLProtocol and we could get http requests and responses.

https://developer.apple.com/documentation/foundation/nsurlprotocol

But all of request was successed. There was not error response.

So we think there is the cause in drawing library.

Actually, we use cesiumJS. And we tried to run a cesium sample application(Hello world) on iOS16, the same issue is occurred.

I wrote the result on Cesium Forum.

https://community.cesium.com/t/3dmap-does-not-show-on-ios16/21236

Please let us know if you have any idea..

This is a bit tangential but I've noticed 'com.apple.WebKit.Networking' has some odd behaviour on macOS.

For example, it tried today to connect to ' r20.rs6.net' on my MacBook Pro 15 2019 which belongs to an online marketing company called 'Constant Contact, Inc.' But that was the very first connection request from this agent after booting up.

Perhaps it was prompted by a tracking pixel in an email, or something to that effect... that took precedence.

Maybe 'com.apple.WebKit.Networking' is also behaving in some obscure manner here?

com.apple.WebKit.Networking deny mach-lookup com.apple.diagnosticd
 
 
Q