Keşfet

False positive "Replier can only add posts at the end of a thread" from non-monotomic time()

XFdestek

Kurucu Üye
Katılım
25 May 2014
Mesajlar
5,010
Tepkime puanı
287
Konum
Türkiye
Web sitesi
fivetu.xyz
php's time() function is non-monotomic. This means it can technically go backwards, noticeable on machines which use a timesync service on a very busy forum

Consider the case;
  • UserA starts replying
    • finalSetup - Clock N, Post.post_date = N
  • Clock progress to N+1
  • Another users posts, updating the xf_threadrecord
    • xf_thread.last_post_date = N+1
  • Timsync causes the clock to be set to Clock N
  • UserA's request reloads the last post...

Lütfen içeriği görebilmek için Giriş yap yada Kayıt ol
 

Konu görüntüleyen kullanıcılar

Geri
Üst Alt