Homework on Hash Functions - Questions

  1. Hash Functions is a one-way function that each unique input produces a unique output.
  2. SHA 256 has used for Bitcoin. The input data can not be reversed, changed, or altered which gives a safe and secure way to transact.
  3. Collision resistance means it is rare and difficult to get the same output from different inputs.
1 Like
  1. A special type of function that converts your input into a digital code that is completely unique.

  2. It is used to mine BTC by tracing inputs and trying to match the outputs.

  3. Collision resistance makes the inputs harder to line up with the outputs, increasing security.

1 Like
  1. Describe hash functions with your own words
    Hash functions are very complex and one-way functions which means you cannot get the input data based on the output data. Hash functions gives you a unique digital fingerprint as an output which gives miners and easier way to validate blocks which were produced in the chain before. Bitcoin blockchain uses SHA256 which converts the input data into a 256 bits output.

  2. How are hash functions used in cryptocurrencies like bitcoin?
    Hash functions are a part of the blockchain hashing algorithm which is used to write new transactions into the blockchain through the mining process. Into the hash function miners are putting in recent and not yet confirmed transactions together with some additional inputs of previous block and hope that hashing function will give them the correct output (a hash which start with certain amount of zeroes). If a miner get`s the correct output a new block is crated which includes all the recent transactions and block is added to the previous block which represents blockchain. For every block crated miners are getting paid in BTC.

  3. What does it mean when we say that hash functions need to be collision resistant?
    If we have two different inputs than hashing functions need to give us two different outputs. In case a hashing function would give us the same output for two different inputs than we would have a problem (collision). So hashing function needs to be designed in a way that is impossible to get the same output for two different inputs.

1 Like
  1. Hash functions are complex one way functions with a fixed length output that provides as a digital fingerprint. If only one thing will be changed in the input you will have a completely diffrent output.

  2. In bitcoin, hash functions are used to write transactions into the blockchain through the mining process (PoW).

  3. Collision resistant means that it must be hard to find two inputs that hash the same output.

1 Like

1.Describe hash functions with your own words

Hash functions are one way by that there is a unique input that produces a unique output.

  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).

-They are used for security purposes by that there are never the same unique finger print. It is not easy to reverse the output to input and thus counterfeiting(fraud) is not possible.

  • Transactions which are inputs run via hashing algorithm,SHA-256 and gives an output of fixed length.

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).

It should be difficult to find an output of the same value

1 Like

1. Describe hash functions in your own words
Hash functions are any size data that when processed through mathematical algorithms, creates a unique fixed size output. This is a one-way calculation, meaning it can not be reverse engineered to get the original input data.
With hash functions one can produce digital fingerprints.

2. How are hash functions used in cyrptocurrencies like bitcoin
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.
In bitcoins proof-of-work algorythm, to successfully ā€˜solve’ a block, miners try to combine all of the inputs with their own arbitrary piece of input data (Nonce) in such a way that the resulting hash starts with a certain number of zeroes.

3. What does it mean when we say that hash functions need to be collision resistant?
A collision of a hash function is a pair of different inputs which give the same output. That’s very bad.
So it is important that hash functions are carefully designed so to make the computation of collisions infeasible. As for cryptography, however, the attacker can try to break a function by brute force.

1 Like
  1. Hash Function takes input values to give an output value that uses SHA256 algorithm. Same input value gives same output value but a small changes gives an entirely different output. Output value is irreversible/decodable i.e cannot go from Output values to Input value.
    2.Hash Function = All new transactions not yet committed + Some variable input string + Previous block’s Hash value. These inputs are run through Hash function to get hash that has leading Zeroes and lower than the target hash.
  2. Hash function is collision resistant when 2 different inputs doesn’t give the same output.
2 Likes
  1. Hash functions are cryptographic input/output algorithms that permit data to be converted to binary code and then hexadecimal. Each input generates a completely random output.

  2. Hash functions are used in Bitcoin as a way for miners to ā€œobtainā€ a bitcoin. Hash functions are encoded in each bitcoin and require computers to compute algorithms very quickly in hopes of finding the correct hash or coming in ā€œunderā€ the hash.

  3. That it should be difficult to find two inputs that hash to meet the same output.

2 Likes

1- A random generated unique bit code.
2- Every block in the chain is giving a hash, in each block the is the current has and the previous hash. This is where alot of the security comes form with bitcoin. In order to change the hash on one block you have to the change the hash on the past and previous blocks aswell.
3- This is the resistance of two different nodes creating the same hash

2 Likes

1: Hash functions take input and produce a unique hexidecimal value that has a fixed length.

2: In Bitcoin mining, hash functions are part of the block hashing algorithm. The function takes input, which is a collection of all the most recent non-confirmed transactions along with timestamp data and a reference to the previous block. Miners then try to solve the hash with said data so that the resulting hash reflects a certain pattern.

3: The function must be intricate enough so that two seperate inputs will never reach the same output.

2 Likes
  1. Hash functions are irreversible algorithms used to provide a digital signature/fingerprint of a given input.

  2. Hash functions are used for wallet addresses (Pay-to-Pubkey Hash aka P2PKH), verifying transactions and creating new blocks in the chain (Proof of Work).

  3. Collision resistance refers to the difficulty of finding 2 inputs that result in the same output hash.

1 Like

A hash is a number generated from some input to a hash function. Its just seemingly random. :slight_smile:

1 Like

Homework on Hash Functions - Questions

  1. A hash is a one-way function. It takes a piece of data as input and shrinks it down into a smaller hash value to provide the output or the signature which is a fingerprint to prove the process is correct. With a cryptographic hash, there’s no way to get a hash value you want without trying a whole lot of inputs.

  2. All blocks contain hashes of previous blocks in the chain, hash functions are part of the block hashing algorithm which is used to write new transactions into the blockchain through the mining process. This takes a lot of computer power and random guessing that means new bitcoins get mined over a long period of time, not all at once.

  3. Collision resistance means that is very difficult to find 2 inputs that produce the same output in the same output hash function.

2 Likes

1,A hash function is a file thats transelated in a unique code.
2. It is used in crypto to translate wallet adressses,transactions and in ther mining field
3.Becouse its almost impossible to hash 2 the same codes

1 Like

1.Hash function is like a digital fingerprint. Hash function converts input to a unique output which can never be reversed.
2. example) Bitcoin Deposit Address
3 Input should not be identified from output

1 Like

1. Describe hash functions with your own words Hash function is a function that will produce a unique output for every different input, its a one-way function, thus, theres no way to go from output to input.

2. How are hash functions used in cryptocurrencies like bitcoin? hash function is used in bitcoin to hash transactions, and in addition, every block that is produced will get its own ā€œfingerprintā€ (hash), and the previous block hash, therefore, every small change will change the whole output.

3. What does it mean when we say that hash functions need to be collision resistant? when we say that hash functions need to be collision resistant that means that it is important when you’re relying on hash functions to always map two inputs to two different outputs.

1 Like
  1. Hash functions are a 1 way function, where each unique input will produce a unique output, aka a digital fingerprint.

  2. Hash functions are used to write new transactions into the blockchain through the mining process.

  3. When we say that hash functions need to be collision resistant, this means that two separate hash inputs cannot result in the same hash output.

1 Like
  1. Describe hash functions with your own words.
    Hash functions are a mathmatical process that takes input data and turns into output data. It is comprised of a string of fixed length of numbers and letters. Hash functions are essential part of security on the blockchain. The hash output can never be reversed to reveil the origional input.

  2. How are hash functions used in cryptocurrencies like bitcoin?
    Hash functions are part of the block hashing algorithm which is used to write new transactions into the blockchain through mining. To successfully solve a block, miners try to combine all of the inputs with their own input data. To solve the hash for a bitcoin block it requires an extreme amount of computation and processing power. Miners will need to put a huge amount of work into solving a block to earn a reward and by doing so they will lock new transactions into the blockchain.

  3. What does it mean when we say that hash functions need to be collision resistant?
    It means that any hash function with more inputs then outputs will necessarily have collisions. The harder they are to find, the more secure the hash function is. It should be difficult to find any two messages that hash to the same value.

2 Likes
  1. hash function = input ==> unique output that can’t be reversed/hacked
  2. used for transaction in the blockchain through mining process
  3. So it is impossible to find different inputs wich calculates the same outputs
1 Like
  1. Describe hash functions with your own words
    An hash function is an mathematical expression containing variables able to translate data of any size to fixed size values

  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).
    Every block is hash“d and linked to the another block + miners have to find a nonce through hashing the previous block + new data from the new block

  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).
    a hash function is said collision resistant when it is difficult to find 2 input that provides the same output.
    collision free does not exist

2 Likes