Homework on Hash Functions - Questions

  1. Describe hash functions with your own words

Hash functions are one way functions that take an input and give a unique output. The same input always gives the same output, so while hash functions are irreversible in that you can’t derive the input from the output, they can be used in digital signatures.

  1. How are hash functions used in cryptocurrencies like bitcoin?

Hash functions are what help secure the BTC blockchain and give it its integrity because each block is hashed with the hash of the previous block in the chain.

  1. What does it mean when we say that hash functions need to be collision resistant?

Simply put, it means that it shouldn’t be likely that two different inputs gave an identical output. If this were common with something like SHA-256, BTC wouldn’t be secure.

1 Like

Homework on Hash Functions - Questions

  1. Describe hash functions with your own words

is a function that when it receives and input it will create a unique output depending on the format that will be used it will only go one way (input =output where output = input wont be a possibility)

  1. How are hash functions used in cryptocurrencies like bitcoin? (Try to research this on your own, we will cover this later in the course but challenge yourself and see if you can find information on this already now).

Hash Functions in Bitcoin is used to make new transactions on the blockchain so that they are encryptet and safe via a public ledger.

  1. What does it mean when we say that hash functions need to be collision resistant? (We didn’t use the term “collision resistant” in the lecture, but you will easily find this on Google, we add this question intentionally to make you research information on your own, that’s how you learn best).

Collision resistant is an important factor in a hash function lets take SHA 256 where it is near impossible to have a collision of 2 of the same inputs making the same unique output.
now that input. time, place, location, network, has a saying in the output.

1 Like
  1. Describe hash functions with your own words
    Hash functions are a computation made to create a unique fingerprint (output) through any input that cannot be reverse-engineered. You can only receive the same output using exactly the same input and you cannot guess the input from the output.

  2. How are hash functions used in cryptocurrencies like bitcoin? (Try to research this on your own, we will cover this later in the course but challenge yourself and see if you can find information on this already now).

Hash functions are used in the proof of work consensus system. In order to solve a block, which carries transactions, the miners need to comput a certain output depending on the current difficulty set out by the protocol. For example, if the difficult is high, miners may have to compute hash functions until they reach an output starting with 18 zeros. This is why confirming blocks takes a long time.

  1. What does it mean when we say that hash functions need to be collision resistant? (We didn’t use the term “collision resistant” in the lecture, but you will easily find this on Google, we add this question intentionally to make you research information on your own, that’s how you learn best).

A collision restant hash function makes it impossible to receive the same output with multiple inputs. If a hash function only allows 1 input per 1 output it is collision resistant.

1 Like
  1. Describe hash functions with your own words?

a unique input with a unique output that allows the input to be unretrievable

  1. How are hash functions used in cryptocurrencies like bitcoin? (Try to research this on your own, we will cover this later in the course but challenge yourself and see if you can find information on this already now).

Hash functions are used by miners to solve cryptography puzzles based on the previous block to add a new block on the blockchain. It is also used to generate bitcoin addresses to send and receive Bitcoin.

  1. What does it mean when we say that hash functions need to be collision resistant? (We didn’t use the term “collision resistant” in the lecture, but you will easily find this on Google, we add this question intentionally to make you research information on your own, that’s how you learn best).

Collision resistance is the property of a hash function that makes it computationally infeasible to find two colliding inputs. This means that no two input hashes should map to the same output hash.

1 Like
  1. Hash functions are a one way function where an input gives a unique output or fingerprint. Any changes to the input gives an entirely different output.
  2. Hash functions are used in bitcoin mining and transactions. It provides security for the entire network. One can not take the hash output and then change or reproduce the transaction or mining.
  3. Collision resistant means that it is almost impossible for 2 different inputs to generate the same hash output
1 Like
  1. Hash function is one specific output or an input, changing any small detail in any input changes the whole output meaning the whole hash

  2. Every block has a specific hash function based on the data and the nonce of this block, each block is chained to the next block by the hash of the previous block, making it impossible to tamper with any of the data.

  3. Collision resistant means you cannot find 2 inputs that gives the same output

1 Like
  1. Hash functions is a function that produce a unique figure print of the input to give a unique figure print of the output. It is a one way function, can only go from an input to an output.
  2. In cryptocurrencies such as bitcoin hash functions use a a building block for new transactions to use by miners during the mining process.
  3. Hash functions need to be collision resistant because it can not be fixed length in the input and the output, otherwise it can be break easily, not much security.
1 Like
  1. Hash functions are special type of functions in which an input results in a unique output. Hence, any slight change to the input will result in a different output. A hash function is also a function whose output can never be worked back in time to get it’s input . S o essentially, it is a one-directional function and that is where it owes it’s security.

  2. Hash functions constitute the backbone of the Proof of Work process. Without confirmation and production of hash transactions, the blockchain would not be tamper-proof and inalterable and it would not be possible to prove who owned which amount of Bitcoin at what time.

  3. It means that the hash function must never give the same output for two different inputs.

1 Like
  1. Describe hash functions with your own words Hash functions uses SHA 256 to convert stings of data to a digital signature this process is irreversible.
  2. How are hash functions used in cryptocurrencies like bitcoin? (Try to research this on your own, we will cover this later in the course but challenge yourself and see if you can find information on this already now). Two keys are created for each account a private key and a public key. the private key is for securing users account and a public key is for sharing input to and from accounts. every transaction creates a hash for miners to verify and once verified it is processed and recorded in the ledger.
  3. What does it mean when we say that hash functions need to be collision resistant? (We didn’t use the term “collision resistant” in the lecture, but you will easily find this on Google, we add this question intentionally to make you research information on your own, that’s how you learn best). No two inputs will produce the same out put making it collision resistant.
1 Like
  1. Taking an input string of any length and producing an out put of a fixed length (256 bit)

  2. input is entered into the algorithm which produces an output thats almost impossible to deconstruct.

  3. This property means that an attacker cannot produce 2 distinct documents from the same hash

1 Like

Describe hash functions with your own words

Hash functions are functions where each unique input gives a unique output. You can go from input to output but never output to input. So it is a one was function.

How are hash functions used in cryptocurrencies like bitcoin?

In cryptocurrencies like bitcoin, transactions are taken as input and run through a hashing algorithm which gives an output of a fixed length.

What does it mean when we say that hash functions need to be collision resistant?

If a hash function is not collision-resistant then an adversary can break the function with little effort. So it means that and hash function with more inputs than outputs will necessarily have such collisions. The harder they are to find, the more cryptographically secure the hash function is.

1 Like
  1. Hash functions are math computations that can only be solved in one direction. You cannot determine the input from the output. Also, according to Investopedia, the input of a hash function can be any size, but the output is always the same size.
  2. Hash functions are used in cryptocurrencies for security. If anything is changed in the original transaction, the hash will change. So if a hacker changes a transaction, the hash will change and it will be known to all the other copies of the blockchain, and the change will be rejected.
  3. Collision resistance hash function means that two distinct inputs will not produce the same hash value. This is like two individuals will not have the same fingerprints.
1 Like
  1. Hash functions create and output code made of bits to store securely the input data.
  2. Hash functions used to create security and privacy in the generated cryptocurrencies.
  3. Collision resistant means that the hash functions are nearly impossible to decode.
1 Like
  1. Hash function are one way functions that takes any input and turns it into an unique output.

  2. Hash functions are used in mining for solving hash functions to validate and verify transactions. Thereafter new blocks are added to the blockchain and the miner who solved this is rewarded.

  3. No 2 different inputs will produce the same output

1 Like
  • Describe hash functions with your own words

A hash function converts an input into another value. The output is always of fixed length.

  • How are hash functions used in cryptocurrencies like bitcoin?

The output is of the same length no matter the size of the input. This means that we can keep track of any data regardless of its size, using its hash value. In the context of cryptocurrencies like bitcoin, the transactions are taken as input and run through a hashing algorithm (bitcoin uses SHA-256) which gives an output of a fixed length.

  • What does it mean when we say that hash functions need to be collision resistant?

Given two different inputs A and B where H(A) and H(B) are their respective hashes, it is infeasible for H(A) to be equal to H(B). What that means is that for the most part, each input will have its own unique hash.

1 Like
  1. hash functions have unique characteristics. for each function there is an input that will give a unique output. for the same function it will always come out the same but any changes will create a new output.
    2.they are used to transfer crypto from one address to another thats about what i know right now. and used for security.
  2. collision resistent is when its hard to find two inputs that lead to the same output
1 Like
  1. Describe hash functions with your own words.

    Hash functions convert input values via encryption to a fixed size output which cannot be reverse engineered.

  2. How are hash functions used in cryptocurrencies like bitcoin? (Try to research this on your own, we will cover this later in the course but challenge yourself and see if you can find information on this already now).
    In the bitcoin protocol hash functions are part of the block hashing algorithm which is used to write new transactions into the blockchain through the mining process.

  3. What does it mean when we say that hash functions need to be collision resistant? (We didn’t use the term “collision resistant” in the lecture, but you will easily find this on Google, we add this question intentionally to make you research information on your own, that’s how you learn best).

    No two input hashes should map to the same output hash.

1 Like
  1. Describe hash functions with your own words

Hash functions are very powerful for two reasons. Firstly, each hash function has a unique input which will produce a unique output. Secondly you can only go from input to output and can never go from output to input. A hash is always a one-way function. For data integrity purposes If you give a hash function a number you get a unique digital fingerprint, therefor hash your data/file for data protection and you’ll receive a unique hash function and if the data has been changed or tampered with, this would result in a new hash function being produced when you compare the hash function values, therefore adding integrity to your data.

  1. How are hash functions used in cryptocurrencies like bitcoin?

Hash functions are one of the most extensively-used cryptographic algorithms in blockchain technology. They are cryptographic (but not encryption) algorithms that are designed to protect data integrity.

Hash functions are widely used in the bitcoin blockchain to protect the integrity and immutability of data stored on the distributed ledger . Since the ledger is stored in a decentralized fashion, with each node maintaining its own copy, ledger immutability is critical. Otherwise, nodes could change their versions of the ledger to their own benefit, breaking the network’s consensus.

This makes hash function security vital to bitcoins security. If bitcoins hash function becomes vulnerable to attack, then the security of the entire system is broken

In the bitcoin protocol, hash functions are part of the block hashing algorithm which is used to write new transactions into the blockchain through the mining process.

In bitcoin mining, the inputs for the function are all of the most recent, not-yet-confirmed transactions (along with some additional inputs relating to the timestamp and a reference to the previous block).

Hash functions are commonly used to protect the integrity of data. Given a trusted hash of the data, it is possible to calculate the hash of the data and compare the two values. If they match, then the data has likely not been modified since the original hash was created.

Bitcoins digital ledger is designed to store valuable information that can benefit an attacker if modified in their favor. Additionally, this ledger is stored and transmitted by a network of mutually distrusting nodes.

As a result, the bitcoin blockchain has a number of different uses for hash functions and the integrity protection that they provide. Some of the most common uses of hash function in the bitcoin blockchain include:

Digital signatures: Hash functions are a vital part of digital signature algorithms, summarizing the data to a compact value while preserving its integrity. Digital signatures are used for preserving data integrity and authentication for bitcoins blockchain transactions and blocks

Merkle trees: Merkle tree summarizes a list of transactions contained within a block into a single value within a block header. They use hash functions to ensure that it is infeasible to find two Merkle trees with the same root hash. This way, by storing the root hash within a block header and protecting the integrity of the block header, the integrity of the transactions contained within the block’s body is protected as well

Proof of Work consensus: The Proof of Work consensus algorithm defines a valid block as one whose header has a hash value less than a given threshold. Hash function collision resistance is essential here since it ensures that finding a valid block is difficult

The blockchain’s “chains”: Each block in the bitcoin blockchain contains the hash of the previous block header within its header. This ensures that changing a single block in the bitcoin blockchain without detection is impossible. Modifying one block in the chain requires generating new versions of every following block as well, increasing the difficulty and helping to preserve the integrity of bitcoins digital ledger

  1. What does it mean when we say that hash functions need to be collision resistant?

In a nutshell, a hash algorithm is a mathematical function that transforms any input into a fixed size output. To be cryptographically secure and usable in blockchain technology the hash function needs to be collision resistant, which means that it is difficult to find two inputs that produce the same output.

A hash function needs to have the following properties:

One-way: It is possible to go from input to output in a hash function but not vice versa. This makes it impossible to reverse engineer a collision from the desired hash output

Large output space: The only way to find a hash collision is via a brute-force search. According to the Pigeonhole Principle, this requires checking as many inputs as the hash function has possible outputs. This number should be large enough to make a brute force search infeasible

Non-locality: In a non-local hash function, similar inputs produce very dissimilar outputs. This is important to protect against hill-climbing attacks

A hash algorithm is considered secure until it is possible to find a collision for it.

Once this has occurred, it is officially deprecated, like MD5 and SHA-1.

Hash functions are vital to protecting the immutability of the digital ledger. If the hash function used by a blockchain is broken, then an attacker could find collisions for crucial hash values (such as the block’s chains or a Merkle tree’s values). This would enable malicious nodes to more easily rewrite the history of the blockchain network and cause a blockchain system to fall apart.

For this reason, the security of hash functions is essential to the security of the blockchain. The security of a hash function can be threatened in a few different ways:

Algorithm strength: Hash functions are designed to be collision-resistant, but cryptographic algorithms are occasionally broken. If a flaw is discovered in a hash function, it may make it possible to effectively find hash collisions

Hash output length: Hash functions are designed to make the best way to find a collision a brute-force search, with the search space equal in size to the space of possible outputs of the hash function. If such a space becomes effectively searchable — due to the use of a hash function with too short of an output length — then the hash function is no longer collision resistant and is vulnerable to attack

Quantum computing: Grover’s Algorithm is an algorithm designed for quantum computers that reduces the space that an attacker needs to search to find a hash collision. Once quantum computers become a reality, this may enable collisions to be found for hash functions that were still secure against attacks by classical computers

SOURCES: https://www.coindesk.com/bitcoin-hash-functions-explained
: https://resources.infosecinstitute.com/topic/hash-functions-in-blockchain/

2 Likes
  1. Describe hash functions with your own words
    Hash functions are one way functions where each input produces an output.This process is impossible to reverse and provides a unique identifier for your data.

  2. How are hash functions used in cryptocurrencies like bitcoin? (Try to research this on your own, we will cover this later in the course but challenge yourself and see if you can find information on this already now).
    Hash functions used in mining blocks and eventually verify new transactions in bitcoin.

  3. What does it mean when we say that hash functions need to be collision resistant? (We didn’t use the term “collision resistant” in the lecture, but you will easily find this on Google, we add this question intentionally to make you research information on your own, that’s how you learn best).
    Collision resistant property of a hash function means that there is no two inputs that result in the same output in a hash function.

1 Like
  1. Describe hash functions with your own words
    Hash functions are one-way functions that are used to generate a fixed-size unique digital output from an input.
  2. How are hash functions used in cryptocurrencies like bitcoin?
    Hash functions can be used to generated digital fingerprints of transactions. In Bitcoin, the information from transactions are hashed, with the resultant hash being store in the blockchain. Also, techniques such as proof of work use hash functions to validate that the required work was done.
  3. What does it mean when we say that hash functions need to be collision resistant?
    A hash function is collision resistant, when two inputs will not result in the same hash output. If the outputs were not unique (or not collision resistant), it means the hash function is not secure.
2 Likes