Bitcoin Forum
January 06, 2026, 02:26:01 PM *
News: Latest Bitcoin Core release: 30.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 2 [3]  All
  Print  
Author Topic: How do timelocked transactions work?  (Read 1319 times)
apogio
Legendary
*
Offline Offline

Activity: 1022
Merit: 2301



View Profile WWW
September 29, 2023, 07:01:41 PM
 #41


Both of you refer to locktime. I was referring to OP_CHECKLOCKTIMEVERIFY. They are completely different.


Brilliant thanks! That's exactly what I was asking for. I now how lock time works. I've actually tested it and used it in real life for educational purposes. The other thing you mention is exactly what I wanted. I ll check it out.


hosemary
Legendary
*
Offline Offline

Activity: 2996
Merit: 6800



View Profile
September 29, 2023, 07:26:53 PM
 #42

The other thing you mention is exactly what I wanted. I ll check it out.
If you want to use OP_CHECKLOCKTIMEVERIFY to lock output(s) of a transaction until a specified time/block height, you must create a timelocked address and that's what already discussed in this thread.
Take note that you can't send bitcoin to a regular address (a legacy or a bech32 address) and make the outputs locked until a specified time/block height.

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
worldofcoins
Sr. Member
****
Offline Offline

Activity: 2114
Merit: 476


View Profile
October 18, 2023, 11:43:19 PM
 #43

It will be rejected by mempool,

I tried to broadcast transactions before a valid date and got this error "the transaction was rejected by network rules. non-final"
This error above was the same in both cases of Block height and Date and Time.

I read that you can broadcast it 2 hours before it becomes valid (but never tested this).

I have set parameters today for hour 23:00, I'll try to broadcast the transaction around 21:10 and see if it's possible.
o_e_l_e_o
In memoriam
Legendary
*
Offline Offline

Activity: 2268
Merit: 18981


View Profile
October 19, 2023, 12:28:25 PM
Merited by worldofcoins (1)
 #44

I tried to broadcast transactions before a valid date and got this error "the transaction was rejected by network rules. non-final"
This is the standard error for transactions with a timelock which has not yet expired.

I have set parameters today for hour 23:00, I'll try to broadcast the transaction around 21:10 and see if it's possible.
It's not possible. I already tested this earlier in this thread here: https://asktom.cf/index.php?topic=2415595.msg62920786#msg62920786. Your transaction's timelock must have reached the exact block height or the exact network adjusted time to be accepted by a node.
worldofcoins
Sr. Member
****
Offline Offline

Activity: 2114
Merit: 476


View Profile
October 19, 2023, 08:38:47 PM
Last edit: October 19, 2023, 08:51:34 PM by worldofcoins
 #45

It's not possible. I already tested this earlier in this thread here: https://asktom.cf/index.php?topic=2415595.msg62920786#msg62920786. Your transaction's timelock must have reached the exact block height or the exact network adjusted time to be accepted by a node.

You're correct. I tried broadcasting the transaction 1 hour before and it didn't work.

Edit: I did that on my local time. Does it mean Coinbin uses the local timezone?
nc50lc
Legendary
*
Offline Offline

Activity: 3010
Merit: 8211


Self-proclaimed Genius


View Profile
October 20, 2023, 03:23:45 AM
 #46

Edit: I did that on my local time. Does it mean Coinbin uses the local timezone?
According to their source's javascript: "bootstrap-datetimepicker.min.js", the time picker uses "defaults={timeZone:"Etc/UTC",", AKA "UTC time zone".
Link to source: js/bootstrap-datetimepicker.min.js

Their service status page also uses the same timezone, link: https://status.coinb.in/

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
o_e_l_e_o
In memoriam
Legendary
*
Offline Offline

Activity: 2268
Merit: 18981


View Profile
October 20, 2023, 05:27:10 AM
 #47

Edit: I did that on my local time. Does it mean Coinbin uses the local timezone?
It uses unix time, which is what the bitcoin network uses as well to avoid issues with timezones, otherwise many nodes would incorrectly reject blocks from elsewhere in the world since their timestamps could differ by many hours.

Unix time is based on UTC time. Most block explorers will also show times based in UTC for this reason. Unix time is the number of seconds since 00:00 on 1st January 1970, UTC.

Pages: « 1 2 [3]  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!