1
0
mirror of https://github.com/bitcoin/bips.git synced 2025-06-30 12:42:43 +00:00

chore(bip-0046): improve timelock point in time explanation

This commit is contained in:
theborakompanioni 2024-05-27 10:25:14 +02:00
parent 722a388ae3
commit a6f1cf3e0d
No known key found for this signature in database
GPG Key ID: E8070AF0053AAC0D

View File

@ -77,7 +77,7 @@ For <tt>index</tt>, addresses are numbered from 0 in a sequentially increasing m
=== Timelock derivation ===
The timelock used in the time-locked address is derived from the <tt>index</tt>. The timelock is a unix time. It is always the first of the month at midnight. The <tt>index</tt> counts upwards the months from January 2020, ending in December 2099. At 12 months per year for 80 years this totals 960 timelocks. Note that care must be taken with the year 2038 problem on 32-bit systems.
The timelock used in the time-locked address is derived from the <tt>index</tt>. The timelock is a unix time. It is always at the start of the first second at the beginning of the month (see [[#Test vectors|Test vectors]]). The <tt>index</tt> counts upwards the months from January 2020, ending in December 2099. At 12 months per year for 80 years this totals 960 timelocks. Note that care must be taken with the year 2038 problem on 32-bit systems.
<pre>
year = 2020 + index // 12