0% found this document useful (0 votes)
5 views

Module2_Lect2_202425

The presentation covers Bitcoin concepts, focusing on keys, addresses, and wallets, emphasizing the role of asymmetric cryptography in establishing ownership and enabling secure transactions. It explains how private and public keys work together to create Bitcoin addresses and how transactions are validated through digital signatures. Additionally, it discusses elliptic curve cryptography and its significance in Bitcoin's security model.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Module2_Lect2_202425

The presentation covers Bitcoin concepts, focusing on keys, addresses, and wallets, emphasizing the role of asymmetric cryptography in establishing ownership and enabling secure transactions. It explains how private and public keys work together to create Bitcoin addresses and how transactions are validated through digital signatures. Additionally, it discusses elliptic curve cryptography and its significance in Bitcoin's security model.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

The material in this presentation belongs to St. Francis Institute of Technology and is solely for educational purposes.

Distribution and modifications of the content is prohibited.

Blockchain
and DLT
(BLCH)
ITC801

Subject In-charge
Dr. Joanne Gomes
Professor Dept. of Information Technology SFIT
Room No. 316
email: [email protected]
Module 2
Lecture 2
Bitcoin
Topics:
• Bitcoin Concepts: keys, addresses and wallets
Asymmetric Keys
Bitcoin Concepts: keys
• Bitcoin is based on public key cryptography Receive Funds Sign transactions
• Ownership of bitcoin is established through digital
keys, bitcoin addresses, and digital signatures.

• The digital keys are independent of the bitcoin


protocol and are created and stored by users in a
file, or database, called a wallet without reference
to the blockchain or access to the internet.

Wallet
• Keys enables bitcoin, to have properties like
decentralized trust and control, ownership
attestation, & cryptographic-proof security model.

• Bitcoin transactions requires a valid digital


signature (witness) to be included in the
blockchain, which can only be generated with a
secret key; anyone with a copy of that key has
control of the bitcoin.
keys, Wallet, bitcoin address & Digital Sign
Bitcoin Address
Pair of Asymmetric Keys Bank account number and Secret pin
• Keys come in pairs: private (secret) & public key. Keys
Wallet-1
• Public key is like bank account number and the Bitcoin Address Wallet-2
private key as similar to the secret PIN, or sign on
a check, that provides control over the account
and proves ownership of an account

• These keys are managed by wallet software and


user rarely sees them.
Wallet-3
• In the payment portion of a bitcoin transaction,
the recipient’s public key is represented by its
digital fingerprint, called a bitcoin address, similar
Bitcoin is implied by the Transaction
to the beneficiary's name on a check.

• Bitcoin address is derived from Key and Key Ring


– public key or
– Script

Wallet Address & Bitcoin Address


Crypto-Wallet with Multiple Bitcoin Addresses
• A crypto-wallet is a collection of private keys that correspond to bitcoin addresses.
• The wallet is generally a text file on disk
Creating Bitcoin Address from public Key
• Creating one bitcoin account Private Key

secret PIN or bank account Beneficiary


sign number Name
Elliptic Curve
Multiplication

Public
Key
Hashing
&
Encoding

Bitcoin
Address
Why Use Asymmetric or Public key Cryptography?

• Asymmetric cryptography used in Bitcoin because it has ability to generate digital signatures.

• There is a mathematical relationship between the public and the private key that allows the
private key to be used to generate signatures on messages.

• Through the presentation of the public key and signature, everyone in the bitcoin network can
verify and accept the transaction as valid, confirming that the person transferring the bitcoin
owned them at the time of the transfer.

Mathematical Relation & One Way Function


Private Key

• Private Key
– used to create signatures required to spend bitcoin by proving ownership of funds used in a transaction
– must remain secret at all times
– should be backed up and protected from accidental loss.

• The private key is generated by picking up a simple random number between 1 and 2256
(between 1 and n - 1, where n = 1.158 * 1077), in such a way that it should not be predictable or
repeatable. Example:

1E99423A4ED27608A15A2616A2B0E9E52CED330AC530EDCC32C8FFC6A526AEDD
Public Keys
• The public key is calculated from the Private Key
private key using elliptic curve
multiplication, which is irreversible
K=k*G
where k is the private key, G is a
constant point called the
Elliptic Curve
generator point, and K is the resulting
Multiplication
public key.

• Because the generator point is always the


same for all bitcoin users, a private key k
multiplied with G will always result in the
same public key K.
• Compressed and uncompressed Public key Public Key
Elliptic Curve Cryptography
• Elliptic curve cryptography (ECC) is a type of asymmetric or
public key cryptography, evolved from Diffie Hellman, based on
the discrete logarithm problem as expressed by addition and
multiplication on the points of an elliptic curve.

• Elliptic curve is made up of the points satisfying the equation:


y²=x³ + ax + b.
– Any point on the curve can be mirrored over the x-axis and the curve
will stay the same.
– Any non-vertical line will intersect the curve in three places or fewer.
Point addition is the addition of two
• In elliptic curve math, there is a point O called the “point at points P and Q on an elliptic curve
infinity,” or “Zero Point” which roughly corresponds to the role of to obtain another point R on the
same elliptic curve.
zero in addition.
Elliptic Curve Cryptography
• In elliptic curve cryptography 0 is additive identity, 0 = -0
• Case-1: Point at infinity
– Adding identity to any point results in that other point,
– For any point P on the curve P + 0 = P
• Case-2: Point Negation
• Point negation is finding such a point, that adding it to itself will result in
point at infinity
• If P and Q have the same x values but different y values
– then the line passing through them will be vertical tangent line
P =(x, y), Q = (x, -y), then P + Q + 0 = 0 which means P = -Q
• Case-3: Point addition
• If two points P and Q on the elliptic curve have different x, y
coordinates,
– then draw a straight line between them and find third point of intersection R
which is also on the elliptic curve
P =(x1, y1), Q = (x2, y2), then P + Q + R = 0 which means P + Q = -R -R
Elliptic Curve Cryptography
• Case-4: Point doubling
• If two points P and Q on the elliptic curve have different x, y coordinates,
– P =(x1, y1), Q = (x2, y2), then P + Q + R = 0 which means P + Q = -R
-P
– If line is tangent to the curve at Q then R = Q, and P + Q + Q = 0 , -P =2Q
– if line is tangent to the curve at P the R = P and P – Q + P = 0, Q = 2P
• If here is only one point P and if line is tangent to the curve at P then
P + P + 0 = 0, 2P = 0, P = 0

Point of Infinity

• If P1 is the “point at infinity,” then P1 + P2 = P2.


• Similarly, if P2 is the point at infinity, then P1 + P2 = P1.
• This shows how the point at infinity plays the role of zero in addition
Diffie Hellman
• Pick up point at infinity G on the curve such that the
smallest value of n, for which nG = 0, be a very large
prime number. Example:
• Bob’s private key is a random number (dB) and the
Bob's public key (QB) will be: QB=dB×G
• Alice will do the same and generate her public key
(QA) from her private key (dA): QA=dA×G
• They then exchange their public keys.
• Alice will then use Bob's public key and her private
key to calculate: SharekeyAlice = dA×QB = dA×dB×G
• Bob will then use Alice's public key and his private
key to calculate : SharekeyBob = dB×QA = dB×dA×G
• The keys will thus match.
• The public key is calculated from the private key using
elliptic curve multiplication, which is irreversible:
• Public key, K = k * G, where k is the private key, G is
a constant point called the generator point,
Bitcoin Address

• Bitcoin address produced from public keys & consist of


a string of numbers & letters beginning with the digit “1”
A = RIPEMD160(SHA256(K))

• Shared with anyone who wants to send you money and it


appears in a transaction as the “recipient” of the funds.

• Bitcoin address is 160 bit (20 byte).


– Example:
1J7mdg5rbQyUHENYdx39WVWK7fsLpEoXZy
• Bitcoin addresses are encoded as “Base58Check” and a
checksum to help human readability, avoid ambiguity, &
protect against errors in address transcription and entry.
Base58Check Encoded Public Hash
Thank You

You might also like