Retrieve time from an NTP server
There’s a lot of code floating around the internet to communicate with NTP servers, unfortunately none of the ones I found actually worked. Here’s a low level implementation:
You can use any NTP host you want, ideally something local to you. Otherwise, you can use a random server from the NTP Server Pool.