How long does ios cache a resolved DNS?
How long does ios cache a resolved DNS?
May I know from which apple official document I can get the answer?
I thought it should be 24hours? but cannot find a official doc for reference.
Thanks a lot.
How long does ios cache a resolved DNS?
May I know from which apple official document I can get the answer?
I thought it should be 24hours? but cannot find a official doc for reference.
Thanks a lot.
Apple will not provide such an answer.
The domain OWNER has the ability/responsibility to set TTL (Time To Live) for any given DNS record, and the client should honor that. Some hostnames that change rarely may have extremely long TTLs (weeks, months, or even years). Hostnames that change frequently may have very short TTLs (as short as a few seconds).
So Apple can't tell you how long IOS will cache a DNS response - it's up to the server.
It would be wrong for Apple to arbitrarily cache DNS records for 24 hours if the domain owner says it should live for 60 seconds, or 6 months.
I also believe that depends on the TTL value on the (authoritative) name server. Different domains, different TTL values. There are no such documents on how long iOS refreshes its cache. It should re-query after TTL expires.
How long does ios cache a resolved DNS?