From: Daniel Stenberg Date: Fri, 20 Dec 2024 07:42:20 +0000 (+0100) Subject: examples/synctime.c: remove references to dead URLs and functionality X-Git-Tag: curl-8_12_0~311 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ed732e359612c07e03aa48e9b60cf40c5fbac27f;p=thirdparty%2Fcurl.git examples/synctime.c: remove references to dead URLs and functionality This example can use the Date: header of any server so there is no point in linking to ancient URLs describeing a setup at NIST that no longer exists. Closes #15786 --- diff --git a/docs/examples/synctime.c b/docs/examples/synctime.c index 6c495f4ae9..b39f99caf2 100644 --- a/docs/examples/synctime.c +++ b/docs/examples/synctime.c @@ -26,24 +26,12 @@ * */ /* This example code only builds as-is on Windows. - * - * While Unix/Linux user, you do not need this software. - * You can achieve the same result as synctime using curl, awk and date. - * Set proxy as according to your network, but beware of proxy Cache-Control. - * - * To set your system clock, root access is required. - * # date -s "`curl -sI https://nist.time.gov/timezone.cgi?UTC/s/0 \ - * | awk -F': ' '/Date: / {print $2}'`" - * - * To view remote webserver date and time. - * $ curl -sI https://nist.time.gov/timezone.cgi?UTC/s/0 \ - * | awk -F': ' '/Date: / {print $2}' * * Synchronising your computer clock via Internet time server usually relies * on DAYTIME, TIME, or NTP protocols. These protocols provide good accurate - * time synchronization but it does not work well through a - * firewall/proxy. Some adjustment has to be made to the firewall/proxy for - * these protocols to work properly. + * time synchronization but it does not work well through a firewall/proxy. + * Some adjustment has to be made to the firewall/proxy for these protocols to + * work properly. * * There is an indirect method. Since most webserver provide server time in * their HTTP header, therefore you could synchronise your computer clock @@ -64,12 +52,6 @@ * 6. Webserver data should not be cached by the proxy server. Some * webserver provide Cache-Control to prevent caching. * - * References: - * https://web.archive.org/web/20100228012139/ \ - * tf.nist.gov/timefreq/service/its.htm - * https://web.archive.org/web/20100409024302/ \ - * tf.nist.gov/timefreq/service/firewall.htm - * * Usage: * This software synchronises your computer clock only when you issue * it with --synctime. By default, it only display the webserver's clock.