this post was submitted on 19 Apr 2026
14 points (85.0% liked)

Programming

26579 readers
252 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] matsdis@piefed.social 5 points 1 day ago* (last edited 1 day ago) (1 children)

The authenticated encryption of HTTPS similarly protects the CDN-based web clock approach. This avoids situations where an attacker-in-the-middle tampers with insecure NTP responses, messing up your system’s clock.

Almost... there is this fun thing called a delay attack that works despite encryption! (I'll admit that it's probably not a practical concern.)

Anyway, the article talks about time measurements through an absurd amount of abstraction layers. Please don't ever call this "simple" or even "cloud-native time" or the like.

If you start trying to improve this setup you'll find so many face-palm moments. Like TCP retransmissions (which the article mentions, to be fair). You'd have to use WebRTC to avoid that, which I bet the CDN network doesn't support. Or the fact that web browser timers have intentionally reduced precision to resist fingerprinting. (Granted, if you are still in the milliseconds range it is not a problem.)

[–] robalex@programming.dev 3 points 18 hours ago

Ooo, great find on the delay attack. I'll read up on that one today, but I think you're right.

The terms I'm using for this are web-native and a demo. Certainly not simple.