Cryptography — Putting the Crypto Into Currency | Crypto.com (2024)

Cryptography — Putting the Crypto Into Currency | Crypto.com (1)

In this deep-dive article, we talk about one fundamental technology behind cryptocurrencies — cryptography — covering the basics of encryption, hash functions, and ciphers as an introduction to cryptography in action.

Introduction to Cryptography

Cryptography, in simplest terms, is to make communications secret. The ‘secret’ here means that, even in the presence of an eavesdropper who can monitor all communications, the intended message can still be delivered to the receiver while kept secret from others.

Cryptography often uses mathematical techniques to achieve desirable properties for secrecy. It is often associated with the process of ordinary plaintext being converted to ciphertext, which is text that only the intended receiver can decode. The process that converts plaintext to ciphertext is known as encryption, while the process of conversion from ciphertext to plaintext is called decryption. A cipher (or cypher) is an algorithm for performing encryption or decryption — a series of well-defined steps that can be followed as a procedure.

Cryptography — Putting the Crypto Into Currency | Crypto.com (2)

Cryptography is not something new, nor just for cryptocurrencies. It is widely used in daily life where information needs to be protected, like banking transaction passwords, email account passwords, and e-commerce transactions.

Blockchain and cryptocurrencies use cryptography in multiple ways — for wallets, transactions, security, and privacy-preserving protocols. For instance:

  • Public-key cryptography used in a transaction
  • Hashing for Bitcoin mining
  • Merkle Trees for transaction positioning in blocks

We can almost say that if you don’t understand cryptography, you don’t understand cryptocurrencies. To better learn, let’s dive deep into the world of cryptography.

Symmetric and Asymmetric Encryption and Hash Functions

Classification of cryptographic algorithms is based on the number of keys employed for encryption and decryption: symmetric encryption, asymmetric encryption, and hash functions.

Cryptography — Putting the Crypto Into Currency | Crypto.com (3)

Each has specific applications that are irreplaceable to each other. For example, asymmetric encryption is needed to generate the private/public key pairs, while hash functions are needed to produce unique digital fingerprints.

Symmetric Encryption

Symmetric encryption uses a single key for both encryption and decryption. The message sender uses the key to encrypt the plaintext and sends the ciphertext to the receiver, who applies the same key to decrypt the message and recover the plaintext. Symmetric key systems are faster and simpler (when compared to asymmetric key systems), but they don’t solve the key-exchange problem between sender and receiver if the key is not known in advance.

Cryptography — Putting the Crypto Into Currency | Crypto.com (4)

Symmetric cryptography schemes are further divided into block ciphers and stream ciphers.

Block ciphers

Block ciphers break the input into fixed-size (e.g., 128 bits) blocks, and each of the blocks is processed by several functions with the secret key. The algorithm determines the block length, key, and functions used in the process.

Some commonly used block ciphers include:

Data Encryption Standard (DES)

  • Block length = 64 bits
  • Key length = 56 bits

Created at IBM, DES was one of the most popular block symmetric ciphers in the early 1970s and is one of the most thoroughly examined encryption algorithms. It was adopted as a federal standard by the National Bureau of Standards (US) in 1976, and included in ANSI standards as the Data Encryption Algorithm for the private sector in 1981.

At the beginning of the twenty-first century, DES was considered insecure, mainly due to its relatively short secret key length, making it vulnerable to brute-force attacks.

Advanced Encryption Standard (AES)

  • Block length = 128 bits
  • Key length = 128, 192, or 256 bits

AES, a modern block symmetric cipher, is one of the most popular ciphers in the world. Developed in 1997 by Vincent Rijmen and Joan Daemen, it was later approved as a federal encryption standard in the United States in 2002.

AES is considered a solid and secure cipher. Over the years, there have been several attacks against different AES implementations, but they concern special cases and are not considered to be a threat to the AES algorithm itself.

Triple DES (3DES)

  • Block length = 64 bits
  • Key length = 56, 112, or 168 bits

3DES cipher was developed because DES encryption, invented in the early 1970s and protected by a 56-bit key, turned out to be too weak and easy to break using modern computers of that time.

Stream ciphers

Stream ciphers are more flexible than block ciphers, as they’re designed to encrypt individual characters (usually binary digits) of a plaintext message one at a time using an encryption transformation that varies with time. By contrast, block ciphers tend to encrypt plaintext blocks using a fixed encryption transformation simultaneously.

Overall, the hardware in stream ciphers is faster than block ciphers. Stream ciphers are also more appropriate and, in some cases, mandatory (e.g., in some telecommunications applications) when buffering is limited or when characters must be individually processed as they are received. Because they have limited or no error propagation, stream ciphers may also be advantageous in situations where transmission errors are highly probable.

Some popular stream ciphers include:

RC4

  • Key length = up to 2,048 bits

RC4 is a variable key-size stream cipher with byte-oriented operations that is widely used in popular protocols. For example, it is used to protect Internet traffic (Transport Layer Security, known as TLS) or to protect wireless networks (Wired Equivalent Privacy, or WEP).

One-Time Pad (OTP)

  • Key length = message length

The theory behind the One-Time Pad (OTP) is that the key must have at least the same length as the message (the plaintext) and consist of truly random numbers. Each letter of the plaintext is ‘mixed’ with one element from the OTP. This results in a ciphertext that has no relation with the plaintext when the key is unknown. At the receiving end, the same OTP is used to retrieve the original plaintext.

Salsa20

  • Key length = 32 bytes

Salsa20 is a cipher submitted to the eSTREAM project, running from 2004 to 2008, which was supposed to promote the development of stream ciphers. It’s considered to be a well-designed and efficient algorithm. There aren’t any known and effective attacks on the family of Salsa20 ciphers.

Asymmetric Encryption

Asymmetric encryption is also known as Public Key Cryptography (PKC). It uses two different keys for encryption and decryption. The key that needs to be kept secret is called the private key, while the key that doesn’t is called the public key. For instance, if A wants to send a message to B and ensure that B will be the only person able to comprehend the message, A can encrypt the message using the public key such that only B can decrypt the message using the private key.

First described publicly by Stanford University professor Martin Hellman and graduate student Whitfield Diffie in 1976, asymmetric encryption is described as a two-key cryptosystem in which two parties could engage in secure communication over a non-secure communications channel without having to share a common secret key.

Cryptography — Putting the Crypto Into Currency | Crypto.com (5)

While the public key and private key are different, they are mathematically related. But the mathematical relationship is usable only upon encryption and decryption, and others cannot derive the private key even if they know the public key.

Asymmetric cryptography algorithms are widely used in cryptocurrencies. For example, the wallet address is created from a public key, and only those who have the private key are able to use the money inside.

Some popular asymmetric encryption schemes include:

RSA

The public key and private key are not chosen arbitrarily. They need to be generated through specified procedures. The public key consists of two large integers (e, n), and the private key consists of two large integers (d, n). The three numbers e, d, and n are related in a special way, requiring a bit more mathematics:

Let’s assume you’re using an encoder that turns all English plaintext into Arabic numbers. For example, ‘Hey! Hey! Hey!’ is translated into ‘7! 7! 7!’ and ‘bitconnnnnnnnect’ is translated into ‘83333331’. Now, Alice wants to send the message ‘Hello’ (which is translated into ‘2’) to Bob.

The easiest method for Alice to send the message to Bob is by directly telling Bob ‘2’. But Alice and Bob don’t want their message to be seen by anyone else. Luckily, Bob knows RSA. He has created a public/private key pair and asked Alice to encode the message ‘2’ using the public key he provided.

Alice then encrypts the message ‘2’ using Bob’s public key (5, 14), and the encrypted message becomes ‘4’, meaning ‘Translate Server Error’. Even if an eavesdropper saw their message, they would have no idea why they are sending ‘4’ out.

Bob knows the ‘4’ is not Alice’s true message. He then decrypts the message with his private key, which he hasn’t told anyone (not even Alice). The private key is (11, 14), and by applying some decrypting procedures, Bob finds out the true message is ‘2’.

Cryptography — Putting the Crypto Into Currency | Crypto.com (6)

Let’s illustrate in a table how the above process works:

Cryptography — Putting the Crypto Into Currency | Crypto.com (7)

From Bob’s side, he only receives the encrypted message ‘4’. But by applying the decryption with his private key, he has successfully recovered the true message ‘2’.

So, how do we get the public key (5, 14) and private key (11, 14)?

Cryptography — Putting the Crypto Into Currency | Crypto.com (8)

This process is called RSA key generation.

For those who are interested, check out RSA encryption.

Elliptic Curve Cryptography (ECC)

ECC is an alternative asymmetric encryption algorithm to RSA. Similarly, it allows users to create a public/private key pair, but the algorithms/procedures used are different than RSA.

For example, for the elliptic curve (see below), the formula is y2 = x3 + ax + b, where a and b are the coefficients to determine the shape of the curve.

We start with a specific point on the curve. Next, we use a function (called the dot function) to find a new point. We repeat the dot function to hop around the curve until finally ending up at our last point. Let’s walk through the algorithm:

Cryptography — Putting the Crypto Into Currency | Crypto.com (9)

This is a great trapdoor function because, if one knows the location of the starting point (A) and the number of hops required to get to the ending point (E), it is very easy to find the ending point. On the other hand, if only the locations of the starting point and ending point are known, it is almost impossible to find how many hops it took to get there. So, in this example, we can define public key and private key as:

  • Public Key: Starting point A, ending point E
  • Private Key: Number of hops from A to E

To be more general, for a given elliptic curve (as shown below), the public key is (P, G), where P is the start point and G is the end point (a special pre-defined [constant] EC point), and the private key is k (k is an integer and P = k * G).

Cryptography — Putting the Crypto Into Currency | Crypto.com (10)

Diffie-Hellman Key Exchange Algorithm

The Diffie-Hellman algorithm is used to establish a shared secret that can be used for private communications while exchanging cryptographic keys over a public network.

Traditionally, encrypted communication between two parties required exchanging keys by some secure physical channel, such as paper key lists transported by a trusted courier. The Diffie-Hellman key exchange method allows for two parties with no prior knowledge of each other to jointly establish a shared secret key over an insecure channel. This key can then be used to encrypt subsequent communications using a symmetric key cipher (as discussed above).

To simplify the algorithm, we use the following image to present the procedure of this encryption. Please note that the letter P at the beginning is selected randomly in an elliptic curve, and G is a primitive root of P. The private keys of a and b are chosen randomly.

Cryptography — Putting the Crypto Into Currency | Crypto.com (11)

Alice and Bob can now use the same secret key (3) to encrypt the message between them without knowing this key in advance.

Hash Functions

Hash functions, also called message digests and one-way encryption, compress plaintext into a fixed-length text, called hash value (or digest). It is impossible to recover the hash value back into the plaintext.

Cryptography — Putting the Crypto Into Currency | Crypto.com (12)

A hash function should fullfil three security properties:

1) Collision-Resistant

It is computationally infeasible to find two different input strings that, if applied to the hash function, have the same output.

It can be expressed like:

It is difficult to find x and y, where H(x) = H(y), but x is not equal to y.

Please note that there have to be collisions since we are moving from a much larger input space t (any strings) to a fixed output space (2^256).

Application: Hash as a Message Digest. If we know that H(x) = H(y), it is safe to assume that x = y.

Example: To recognise a file that we saw before, remember its hash. This works because the hash is small.

2) Hidden

Given H(x), it is infeasible to find x. This can be explained as, if given the hashed version of x, we will not find x.

Cryptography — Putting the Crypto Into Currency | Crypto.com (13)

Application of Hiding Property: Commitment

This is the digital analogy of taking a value (a number), sealing it in an envelope, and putting that envelope on the table — where anyone can see it — thus committing to what’s in the envelope and its secret from everyone else. Later, the envelope can be opened and the value taken out, but it’s sealed. So commit to a value and reveal it later.

The commitment algorithm does two things:

1. Commit to a message: Returns two values — a commitment and a key. The commitment is the same as the envelope put on the table; the key is necessary to open it.

2. Later, we reveal to someone the original message and let them verify that it corresponds to the original, providing them with the commitment and the key.

3) Puzzle-Friendly

If someone wants to target a certain hash function, then gain some value of y. If part of the input is chosen randomly, it’s difficult to find another value to target the hash function value.

Given an output y of the hash function, if k is chosen from a random distribution, it is infeasible to find an x, such that the hash of k|x (k concatenated with x) is y: H(k|x) = y.

Popular Hash Functions

Message Digest (MD)

The MD family comprises hash functions MD2, MD4, MD5, and MD6. It was adopted as Internet Standard RFC 1321 and is a 128-bit hash function.

MD5 digests have been widely used in the software world to provide assurance about the integrity of transferred files. For example, file servers often provide a pre-computed MD5 checksum for the files so that a user can compare the checksum of the downloaded file to it.

Secure Hash Function (SHA)

The family of SHA consists of four SHA algorithms: SHA-0, SHA-1, SHA-2, and SHA-3. Though from the same family, they are structurally different.

SHA-0 was published by the US National Institute of Standards and Technology (NIST) in 1993. It had few weaknesses but did not become very popular.

Later, in 1995, SHA-1 was designed to correct the alleged weaknesses of SHA-0. Collisions against the full SHA-1 algorithm can be produced using the shattered attack, and the hash function should be considered broken.

The SHA-2 family has four further SHA variants: SHA-224, SHA-256, SHA-384, and SHA-512, depending on the number of bits in their hash value. SHA-256 and SHA-512 are commonly used. SHA-512 is more secure than SHA-256 and is often faster than SHA-256 on 64-bit machines.

In October 2012, the NIST chose the Keccak algorithm as the new SHA-3 standard. Keccak offers many benefits, such as efficient performance and good resistance to attacks.

RIPEMD

RIPEMD is a family of cryptographic hash functions that includes RIPEMD, RIPEMD-128, and RIPEMD-160. There also exist 256- and 320-bit versions of this algorithm. RIPEMD-160 is an improved version and the most widely used version in the family.

Final Words: Applying Cryptography in Practise

Cryptography has a surprisingly long history, but one with seemingly endless possibilities for future usage. The process is the base of current-day cryptocurrency and wallets.

For more info about the different kinds of crypto wallets, read What Is a Crypto Wallet? A Beginner’s Guide.

Due Diligence and Do Your Own Research

All examples listed in this article are for informational purposes only. You should not construe any such information or other material as legal, tax, investment, financial, cybersecurity, or other advice. Nothing contained herein shall constitute a solicitation, recommendation, endorsem*nt, or offer byCrypto.comto invest, buy, or sell any coins, tokens, or other crypto assets. Returns on the buying and selling of crypto assets may be subject to tax, including capital gains tax, in your jurisdiction. Any descriptions of Crypto.com products or features are merely for illustrative purposes and do not constitute an endorsem*nt, invitation, or solicitation.

Past performance is not a guarantee or predictor of future performance. The value of crypto assets can increase or decrease, and you could lose all or a substantial amount of your purchase price. When assessing a crypto asset, it’s essential for you to do your research and due diligence to make the best possible judgement, as any purchases shall be your sole responsibility.

Cryptography — Putting the Crypto Into Currency | Crypto.com (2024)

FAQs

How cryptography is used in crypto currency? ›

Cryptography is the mathematical and computational practice of encoding and decoding data. Cryptocurrency generally uses two different cryptographic methods—one dedicated to generating its public-private key pairs and another for the purpose of validating transactions.

Why is cryptography important for cryptocurrency answer? ›

Cryptocurrencies use cryptography to allow transactions to be anonymous, secure, and “trustless,” which means you don't need to know anything about a person to safely make transactions with them – and you don't need bank, credit-card company, government, or any other third party in the middle.

What is cryptocurrency answers? ›

Cryptocurrency, sometimes called crypto-currency or crypto, is any form of currency that exists digitally or virtually and uses cryptography to secure transactions. Cryptocurrencies don't have a central issuing or regulating authority, instead using a decentralized system to record transactions and issue new units.

Is crypto com real or fake? ›

Compared to other cryptocurrency exchanges, Crypto.com is decently secure and trustworthy. Crypto exchanges aren't registered or regulated by the same authorities that monitor online brokers and other trading platforms, which leaves them vulnerable to hackers, scams, and bankruptcy.

What is the main use of cryptography? ›

Cryptography provides for secure communication in the presence of malicious third-parties—known as adversaries. Encryption uses an algorithm and a key to transform an input (i.e., plaintext) into an encrypted output (i.e., ciphertext).

What is the difference between cryptography and cryptocurrency? ›

Cryptography is an essential mechanism for securing information in computer systems. Without cryptography, cryptocurrency is just a central hub for attackers and scammers. Cryptocurrency requires cryptography for mainly two purposes; to secure the transactions and to verify these transfers.

What is cryptography in simple words? ›

Cryptography is the process of hiding or coding information so that only the person a message was intended for can read it. The art of cryptography has been used to code messages for thousands of years and continues to be used in bank cards, computer passwords, and ecommerce.

What are the two main types of cryptography? ›

Symmetric Key Cryptography: This cryptography uses the same key for encryption and decryption. Examples include AES, DES, and Blowfish. Asymmetric Key Cryptography: This type of cryptography uses two keys for encryption and decryption.

How to encrypt currency? ›

Cryptocurrencies stay secure by relying on modern asymmetric encryption methods and the secure nature of transactions on a blockchain. Cryptocurrency holders use private keys to verify that they are owners of their cryptocurrency. Transactions are secured with hashing and blockchain encryption techniques.

How does crypto make you money? ›

How Does Crypto Make You Money? There are several ways cryptocurrency can make money for you. Decentralized finance applications let you loan your crypto with interest; you can stake a compatible one on a blockchain or at certain exchanges for rewards, or you can hold on to it and hope its market value increases.

Why crypto is money? ›

A cryptocurrency is a digital currency based on a network that is scattered across a huge number of computers. The decentralized system of cryptocurrency makes it faster and cheaper to transfer money.

Who controls the value of cryptocurrency? ›

The price of cryptocurrency is determined by supply and demand.

Is Crypto.com shutting down in the US? ›

Cryptocurrency exchange Crypto.com said Friday that it will wind down its institutional service for American clients on June 21. The Singapore-based digital asset platform added that it made the decision due to "limited demand from institutions in the U.S. in the current market landscape."

Is my money in crypto com safe? ›

Your virtual assets are stored 100% safely and perfectly.

We hold all customer assets deposited on our platform in institutional-grade reserve accounts on a 1:1 basis, meaning funds are responsibly backed by Crypto.com and accessible at customers' convenience.

Do you actually own crypto on Crypto com? ›

Unlike a centralized custodian on the Crypto.com App, you have complete ownership of your crypto when they are stored in the Crypto.com Wallet. You do not need a Crypto.com account to store, send and receive crypto in the Crypto.com Wallet.

How is public key cryptography used in cryptocurrency? ›

A public key allows you to receive cryptocurrency transactions. It's a cryptographic code that's paired to a private key. While anyone can send transactions to the public key, you need the private key to “unlock” them and prove that you are the owner of the cryptocurrency received in the transaction.

What cryptographic methods are used in Bitcoin? ›

Bitcoin implements a digital signature algorithm called ECDSA which is based on elliptic curve cryptography.

What is the application of cryptography in Bitcoin transaction? ›

While transactions are recorded in the public blockchain, the use of cryptographic key pairs allows users to maintain pseudonymity. By generating new addresses for each transaction, users can separate their transaction history, making it challenging to link transactions to a specific individual or entity.

Why cryptography is important in blockchain? ›

Cryptography makes sure that no one other than the intended individual has access to information on the blockchain network. It is not possible to alter the information during its storage or transmission to the recipient from the sender without being noticed.

Top Articles
Atmospheric Pressure
Connecting with Your Audience: 15 Tips for a Productive Q&A Session
Friskies Tender And Crunchy Recall
Global Foods Trading GmbH, Biebesheim a. Rhein
Knoxville Tennessee White Pages
Main Moon Ilion Menu
Www.politicser.com Pepperboy News
Readyset Ochsner.org
Puretalkusa.com/Amac
Top Golf 3000 Clubs
454 Cu In Liters
What to do if your rotary tiller won't start – Oleomac
Caliber Collision Burnsville
6813472639
Troy Bilt Mower Carburetor Diagram
Is Grande Internet Down In My Area
Shasta County Most Wanted 2022
Decosmo Industrial Auctions
Riherds Ky Scoreboard
Canvasdiscount Black Friday Deals
8005607994
Aliciabibs
Chicago Based Pizza Chain Familiarly
Acurafinancialservices Com Home Page
Sensual Massage Grand Rapids
Delta Township Bsa
manhattan cars & trucks - by owner - craigslist
Imagetrend Elite Delaware
Winterset Rants And Raves
Rays Salary Cap
Why Are The French So Google Feud Answers
The value of R in SI units is _____?
Wega Kit Filtros Fiat Cronos Argo 1.8 E-torq + Aceite 5w30 5l
Hotels Near New Life Plastic Surgery
Today's Gas Price At Buc-Ee's
Dmitri Wartranslated
Gun Mayhem Watchdocumentaries
Reese Witherspoon Wiki
How to Print Tables in R with Examples Using table()
Postgraduate | Student Recruitment
FREE - Divitarot.com - Tarot Denis Lapierre - Free divinatory tarot - Your divinatory tarot - Your future according to the cards! - Official website of Denis Lapierre - LIVE TAROT - Online Free Tarot cards reading - TAROT - Your free online latin tarot re
18006548818
Pike County Buy Sale And Trade
Unlock The Secrets Of "Skip The Game" Greensboro North Carolina
Gonzalo Lira Net Worth
Grand Park Baseball Tournaments
Mikayla Campinos Alive Or Dead
Coleman Funeral Home Olive Branch Ms Obituaries
Arre St Wv Srj
Worlds Hardest Game Tyrone
Latest Posts
Article information

Author: Kareem Mueller DO

Last Updated:

Views: 6312

Rating: 4.6 / 5 (46 voted)

Reviews: 93% of readers found this page helpful

Author information

Name: Kareem Mueller DO

Birthday: 1997-01-04

Address: Apt. 156 12935 Runolfsdottir Mission, Greenfort, MN 74384-6749

Phone: +16704982844747

Job: Corporate Administration Planner

Hobby: Mountain biking, Jewelry making, Stone skipping, Lacemaking, Knife making, Scrapbooking, Letterboxing

Introduction: My name is Kareem Mueller DO, I am a vivacious, super, thoughtful, excited, handsome, beautiful, combative person who loves writing and wants to share my knowledge and understanding with you.