Ios14 connection issue on local network

Tags: #<Tag:0x00007f328aeec960>

I just upgraded my phone towards ios14 and the iOS companion app can no longer connect to my homeassistant server on my local network. External works fine.
I did allow the home assistant access to the local network.
If I look at a generic network ping app from my phone I am able to resolve and ping the HA host before opening the homeassistant app. As soon as I open the app it does not connect and indicates “a server with the specified hostname does not exist”
I then switch back to the ping app and all of a sudden this app is not able to resolve the host and indicates the error: kCFErrorDomainCFNetwork error 2
Tried different settings with external and internal url, no difference. Before the upgrade I only used the external url since my internal dns resolves the request to the internal host.
It seems to be a dns issue caused by the app.
Anyone a similar experience or ideas how to resolve this?

after further digging the issue seems to be DNS related. IOS14 seems to have some trouble switching between external and internal url’s with the same name but different adresses. In my case the external name is a cname, internal a direct A record. Perhaps the dns caching on IOS14 requires some more work. IOS14 has the new “Local Network” privilige build in, perhaps this has something to do with the issue as well.
Problem occurs especially when you do a refresh in the IOS app by swiping down This is where the error “Unable to connect” comes up.

Finally found someone with exactly the same issue.
Problem is related to dns caching when using cname records and switching between internal and external dns servers.