ブロックチェーンでの時間はどの位正確なのか?という質問をよくされる。
そして、実際の要件で時間が問題になることが多いので、簡単にまとめる。
概要
- 各ノードは時間に嘘をつける
- ビットコインなどのパブリックの実装では、ある程度の幅の範囲の時間でないといけない実装になっている
ざっくりしかまとめる時間がないので、そのまま公開
Bitcoin wiki
A timestamp is accepted as valid if it is greater than the median timestamp of previous 11 blocks, and less than the network-adjusted time + 2 hours. “Network-adjusted time” is the median of the timestamps returned by all nodes connected to you.
QA: StackExchange
- Which is the reliability of a transaction timestamp? – Bitcoin Stack Exchange
-
timestamp – How accurate is Bitcoin network time? – Bitcoin Stack Exchange
- The median time advertised by peers (if between ±70 minutes from system time)
- System time
So block timestamps are:
- < 2 hours from “network time”.
- > median of last 11 blocks.
- Satoshi did NOT introduce a transaction timestamp in bitcoin software : Bitcoin
-
We need a standard for Bitcoin blockchain timestamps! Proposal Inside! Feedback please! : Bitcoin
Blog
Bitcoin Blockchain Timestamping Overview
List of timestamping services by using Bitcoin blockchain
https://docs.google.com/spreadsheets/d/1rTxK5sVsktBYkwFZH6TLWKN7FTBXDuN2G1ePED6Rscg/edit#gid=0