Bitcoin Forum
November 04, 2025, 11:21:56 PM *
News: Pumpkin carving contest
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Wetin be OP_CHECKSIG and OP_RETURN: for beginners  (Read 114 times)
Hypnotizer (OP)
Member
**
Offline Offline

Activity: 70
Merit: 67


View Profile
October 31, 2025, 04:25:19 PM
Merited by Nightwalker(NW) (1)
 #1

Good day my pipo, you know at some point as a beginner, you go dey wonder wen you see pipo talking about OP_CHECKSIG  or OP_RETURN, Wetin e mean?
Nah Wetin make me create the thread bedat make I fit explain Wetin dem dey mean for beginners make dem get basic understanding of Wetin OP_CHECKSIG  or Wetin OP_RETURN dey mean.


Wetin be OP_CHECKSIG

OP_CHECKSIG nah opcode for bitcoin scripting language , wey dey part of transactions validation process and e dey verify whether the signature for a given transaction input nah valid signature and to make sure say nah the owner of the money Nahim dey spend am.

To confirm say the pesin wey wan spend the bitcoin get the private key associated with public key provided in the transaction, OP_CHECKSIG dey check the given signature whether e dey valid for the given public key.

OP_CHECKSIG dey collect  two input from the stack, which are: The signature (wey dem use the private key create) and The public key wey dey associated with the bitcoin address. And OP_CHECKSIG dey output a true or false value (Boolean value) wey dey show if the input is valid or not.

Where OP_CHECKSIG dey applicable

•Transaction Validation
•Pay-to-Public-Key-Hash (P2PKH)- The most common script type

To validate the standard of a bitcoin transactions, OP_CHECKSIG is used. The wallet software wey pesin dey use go create a transaction wey contain  the necessary signatures, wen ever pesin dey try  to spend him bitcoins. The Bitcoin nodes go com use OP_CHECKSIG to verify the validity of these signatures before dem accept and add the transaction in a block.

OP_CHECKSIG nah very important part of bitcoin security wey dey keep the security of bitcoin network, by making sure say nah only the rightful owner fit spend him bitcoin.




Note: This is just a thread to explain what OP_CHECKSIG and what OP_RETURN basically mean for beginners, anyone wanting to know more about it can learn from various ebooks and websites.

You can Read more here: https://en.bitcoin.it/wiki/OP_CHECKSIG



Explaination about what OP_RETURN is will be on the next reply.
Hypnotizer (OP)
Member
**
Offline Offline

Activity: 70
Merit: 67


View Profile
October 31, 2025, 04:25:56 PM
Last edit: October 31, 2025, 04:37:48 PM by Hypnotizer
 #2

For OP_RETURN explanation, you can visit this thread.
Emjay24
Full Member
***
Offline Offline

Activity: 287
Merit: 123



View Profile
October 31, 2025, 04:33:01 PM
 #3

Reserved for OP_RETURN explanation
We've a current Topic where is explained on this same board by promise444c5, so there may be no need for yours at the moment. It's thoughtful of you to want to enlighten us on it actually. You can go ahead and drop your views as a form of contribution there, I think it would be better that way.

Frankolala
Hero Member
*****
Offline Offline

Activity: 1246
Merit: 683


Leading Crypto Sports Betting & Casino Platform


View Profile
October 31, 2025, 05:01:51 PM
 #4

Reserved for OP_RETURN explanation
We've a current Topic where is explained on this same board by promise444c5, so there may be no need for yours at the moment. It's thoughtful of you to want to enlighten us on it actually. You can go ahead and drop your views as a form of contribution there, I think it would be better that way.
It's not the same thread mate. That other thread is only about OP_RETURN but this one is talking about both OP_CHECKSIG and OP_RETURN.

OP_RETURN allows you to store arbitrary data on bitcoin blockchain and any coins send to OP_RETURN is unspendable. While OP_CHECKSIG verifies if you are the true owner of the private keys of the wallet you want to spend from through verifying your wallet signature with your pubkey. Which means that it confirms your identity and authenticity to avoid theft.

..Stake.com..   ▄████████████████████████████████████▄
   ██ ▄▄▄▄▄▄▄▄▄▄            ▄▄▄▄▄▄▄▄▄▄ ██  ▄████▄
   ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██  ██████
   ██ ██████████ ██      ██ ██████████ ██   ▀██▀
   ██ ██      ██ ██████  ██ ██      ██ ██    ██
   ██ ██████  ██ █████  ███ ██████  ██ ████▄ ██
   ██ █████  ███ ████  ████ █████  ███ ████████
   ██ ████  ████ ██████████ ████  ████ ████▀
   ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██
   ██            ▀▀▀▀▀▀▀▀▀▀            ██ 
   ▀█████████▀ ▄████████████▄ ▀█████████▀
  ▄▄▄▄▄▄▄▄▄▄▄▄███  ██  ██  ███▄▄▄▄▄▄▄▄▄▄▄▄
 ██████████████████████████████████████████
▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
█  ▄▀▄             █▀▀█▀▄▄
█  █▀█             █  ▐  ▐▌
█       ▄██▄       █  ▌  █
█     ▄██████▄     █  ▌ ▐▌
█    ██████████    █ ▐  █
█   ▐██████████▌   █ ▐ ▐▌
█    ▀▀██████▀▀    █ ▌ █
█     ▄▄▄██▄▄▄     █ ▌▐▌
█                  █▐ █
█                  █▐▐▌
█                  █▐█
▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█
▄▄█████████▄▄
▄██▀▀▀▀█████▀▀▀▀██▄
▄█▀       ▐█▌       ▀█▄
██         ▐█▌         ██
████▄     ▄█████▄     ▄████
████████▄███████████▄████████
███▀    █████████████    ▀███
██       ███████████       ██
▀█▄       █████████       ▄█▀
▀█▄    ▄██▀▀▀▀▀▀▀██▄  ▄▄▄█▀
▀███████         ███████▀
▀█████▄       ▄█████▀
▀▀▀███▄▄▄███▀▀▀
..PLAY NOW..
Mia Chloe
Legendary
*
Offline Offline

Activity: 882
Merit: 1487


Contact me for your designs...


View Profile
October 31, 2025, 07:32:58 PM
 #5

A thread like this already exists but nevertheless it's actually better than the countless repetition posts about investing and Forex trading by people that don't even trade Forex all over the board. Currently I don't have smerits to dish out buh I'll keep your post on the waiting list.

Nevertheless consider this an urge to improve quality and make more detailed explanations when you are talking technicals it's way better than blindly writing what you may have found on an article.

Ambatman
Hero Member
*****
Offline Offline

Activity: 812
Merit: 1012


Don't tell anyone


View Profile WWW
October 31, 2025, 08:05:59 PM
 #6

Adding to what the OP has said, OP codes like the above are instructions in scripts that define spending transactions.
And they usually self explanatory like the name implies.
OP_CHECKSIG -Operation check signatures. Which helps in defining validity.

OP_Return -Operation Return. Return is a function that allows quick or early exit in programming though its usually a success but in OP Return it fails.
Hence the name.
When there's an OP Return it's like saying Abort mission. Fail the script. Burn UTXO and  Keep data.
Meaning you purposely want the script to fail.
It's like saying This is a message and not money

promise444c5
Hero Member
*****
Offline Offline

Activity: 826
Merit: 606


All things are numbers


View Profile WWW
November 01, 2025, 02:11:21 AM
 #7

Here you can get more details here : https://en.bitcoin.it/wiki/OP_CHECKSIG
Quote
Where OP_CHECKSIG dey applicable

•Transaction Validation
•Pay-to-Public-Key-Hash (P2PKH)- The most common script type


It is also used in P2WPKH but not like the normal locking script, you can call it a P2WPKH witness program…

It is normally interpreted during spending, so the real checking script is created internally unlike P2PKH, where the scriptPubKey contains the full locking script, a P2WPKH scriptPubKey only contains the version number and a 20-byte public key hash.

The checking script works the same way as a normal P2PKH script but the scriptSig, which is supposed to contain the public key and signature, is empty in P2WPKH. The witness field (remember ‘pay-to-witness’) holds those data instead. The node then uses the sig. and pubKey for the  checking logic.

OP_DUP ->Duplicates the pushed public key
OP_HASH160 -> hash the public key
<20-byte hash> -> the hash from the scriptPubKey
OP_HASH160 <hash> OP_EQUALVERIFY -> Verify if the pub key has matches the 20-bytes else it fails
OP_CHECKSIG -> verifies the signature against the pubKey( the remaining one on the stack)
Code:
 OP_DUP OP_HASH160 <pubKeyHash> OP_EQUALVERIFY OP_CHECKSIG 

Enough yapping, you can read it here : https://en.bitcoin.it/wiki/BIP_0141 and https://learnmeabitcoin.com/technical/script/p2wpkh/

If it looks confusing start from here:
https://en.bitcoin.it/wiki/Script
https://bitcointalk.org/index.php?topic=5507824.0

 
█▄
R


▀▀██████▄▄
████████████████
▀█████▀▀▀█████
████████▌███▐████
▄█████▄▄▄█████
████████████████
▄▄██████▀▀
LLBIT▀█ 
  TH#1 SOLANA CASINO  
████████████▄
▀▀██████▀▀███
██▄▄▀▀▄▄████
████████████
██████████
███▀████████
▄▄█████████
████████████
████████████
████████████
████████████
█████████████
████████████▀
████████████▄
▀▀▀▀▀▀▀██████
████████████
███████████
██▄█████████
████▄███████
████████████
█░▀▀████████
▀▀██████████
█████▄█████
████▀▄▀████
▄▄▄▄▄▄▄██████
████████████▀
........5,000+........
GAMES
 
......INSTANT......
WITHDRAWALS
..........HUGE..........
REWARDS
 
............VIP............
PROGRAM
 .
   PLAY NOW    
Emjay24
Full Member
***
Offline Offline

Activity: 287
Merit: 123



View Profile
November 01, 2025, 05:13:58 AM
 #8

Reserved for OP_RETURN explanation
We've a current Topic where is explained on this same board by promise444c5, so there may be no need for yours at the moment. It's thoughtful of you to want to enlighten us on it actually. You can go ahead and drop your views as a form of contribution there, I think it would be better that way.
It's not the same thread mate. That other thread is only about OP_RETURN but this one is talking about both OP_CHECKSIG and OP_RETURN.
Perhaps if you carefully read my reply and what I quoted above, there would be no need for this. OP already saw reasons with my point and agreed with me. I was talking only about the space he reserved to explain OP_RETURN and not the whole thread, I saw no need to explain again what have been explained on an active thread still within this board, you can go back and read with more clarity if you wish.

Pages: [1]
  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!