Homework on Hash Functions - Questions

  1. one way function . each input produces an output (digital fingerprint )
  2. used in mining for new transactions on blockchain. inputs for the has function are creating addresses, private and public keys. recorded as hashes on the ledger
  3. hard for two inputs to have same output
    cr
1 Like
  1. Bitcoin’s protection

  2. BitCoin uses the SHA-256 hash algorithm to generate verifiably “random” numbers in a way that requires a predictable amount of CPU effort

3.In cryptography, collision resistance is a property of cryptographic hash functions: a hash function H is collision-resistant if it is hard to find two inputs that hash to the same output; that is, two inputs a and b where a ≠ b but H(a) = H(b).

1 Like
  1. generator of unique code(output) based on unique input - the core of Bitcoin’s security

  2. BTC uses SHA-256 to run its consensus mechanism and to reward miners.

  3. the hash function is CR if its difficult to find same output to 2 different inputs

1 Like

1, hash function create a unique fingerprint (hash) of any size data (input) that cannot be reversed using an algorithm called SHA-256.

2,hash functions are used to create transaction blocks to add it to the block chain using mining to execute.

3, it means that two different input shouldn`t hash the same output. even if it does

1 Like

Homework on Hash Functions - Questions

  1. Hash functions collect input data and produce an output string of data. The output data cannot be used to replicate the initial input data.

  2. Hash functions are used in cryptocurrency to collect the input data of a transaction for example, and produce an output through mining. The output that is produced can be added to the blockchain.

  3. Functions need to be collision resistant to avoid the possibility of two different inputs resulting in the same output. This unlikely event is called a collision. It seems to me that the more complex the input and output hashes, the less likely a collision can occur.

1 Like
  1. Hash functions are 1 way functions with an input and an output. Each input has its own digital finger print. Each different input produces a completely different output. Even the slightest change will produce a completely different output. With hash functions you cannot find the input with the given output.

  2. From my understanding, bitcoin transactions are the inputs and then used in a hashing function which will then give you an output

  3. Collision resistant means that it is extremely difficult to find two different inputs with the same output, although it is not impossible.

1 Like
  1. A hash is a function that produces an output based upon an input provided.

  2. Hash functions are used in crypto currency by mining for new transactions through an input output method, to prevent the system from being corrupted.

3.Hash functions must be collision resistant, meaning that two inputs should not be eq.ual to one output.

1 Like
  1. Hash functions are one-way functions that when given an input, produce an output or digital fingerprint.

  2. Hash functions are the building blocks that hash algorithms use to write new transactions into the block chain.

  3. Collision resistance is the premise that two different hash function inputs should not produce the same output. Due to the very nature of hash functions, collisions will occur but it is computationally improbable.

1 Like
  1. Describe hash functions with your own words.
    Hash functions are one-way functions that have a unique output with a fixed length for every unique input.
  2. How are hash functions used in cryptocurrencies like bitcoin?
    In cryptocurrencies, hash functions secure the network. In cryptocurrencies the hast from a block is used in the creation of the next block. This creates a situation where if the data in one block changed, it changes the hash input for the next block and every block after. This is how immutability is obtained.
  3. What does it mean when we say that hash functions need to be collision resistant?
    A collision occurs when two different hash inputs result in the same output. It is important that hash functions are collision resistant a hacker could potentially swap out one transaction with another.
1 Like
  1. Hash function is a computation where any given input is calculated into a unique output. A slight change to the original input creates a totally new and unique output for the changed input.

  2. Hash functions are used to create a digital fingerprint on each transaction performed with bitcoin and other cryptocurrencies, which are then recorded onto the correlating blockchain. Hash functions are what makes up each block on the blockchain, thus making it the backbone said blockchains.

  3. Hash functions need to be collision resistant in that there are not more inputs than outputs and no 2 inputs can create the same output.

1 Like
  1. A hash function is a function that takes an input and returns a result, so that:
  • it’s easy to obtain the output, from the input
  • it’s very difficult (or impossible) to get the input, knowing the output
  • even the smallest modification in the input gets a completely different output
  1. Hash functions are used when new transactions are written, to confirm old transactions.

  2. A hash function should distribute input values as evenly as possible; this is the meaning of ‘collision resistant’.

1 Like

You missed the last question :stuck_out_tongue_winking_eye:

SHA256 is not used to derive public keys (or private keys), for that the elliptic curve function is used. :slight_smile:

  1. Describe hash functions with your own words
    They are functions that from every unique input produce a unique output, but with no means by which to reverse engineer 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 solving of blocks. The latest info with transactions, timestamps etc are run through hashing function with arbitrary info put in by the miner until the output results in a a hash number that begins with the correct number of zeroes.

  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 is very hard if not impossible to find two inputs that hash to the same output. IE no two inputs collide to produce the same output.

1 Like
  1. Hash functions give a unique digital fingerprint of an input. Outputs are irreversible.

  2. Hash functions are used to encrypt transactional data and are part of the decentralized security of Bitcoin.

  3. Collision resistant means that two different inputs should not compute the same output.

2 Likes
  1. Its like a fingerprint.You can go from input to output but you cannot go from output to input.
  2. From what I understand the are used as proof of work and allows for the identification of the owner of a cryptocurrency. You can go from input to output but you cannot go from output to input.
    3.“A hash function is called collision resistant if it is very hard to find two or more distinct pieces of data for which it yields the identical hash value. Or, to put it differently, if the chance to receive an identical hash value for distinct pieces of data is small, then the hash function is collision resistant”

Excerpt From: Daniel Drescher. “Blockchain Basics.” Apple Books.

1 Like

I love your definition of Hash functions

I posted the answers to the reading assignment in the wrong place :unamused:. I fixed it, thanks for the heads up.

  1. A hash function is a type of function where an output can be computed using the input, however the input cannot be computed using the output.

  2. In cryptocurrencies, Hash functions are used to build the blockchain. Transaction for example are the input to a hash function. The hash function is now part of a new block in the blockchain. The hash output is then added to the input of the function together with new transaction to create another block.

  3. When a hash function needs to be collision resistant means that two or more different inputs of the hash function will not result in the exact same output

1 Like
  1. Describe hash functions with your own words. Each unique input has unique output and created a digital fingerprint.
  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). The process creates a one way function that is virtually impossible to break . Bitcoin uses SHA 256
  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). Quite difficult to find two inputs and produce the same output.
1 Like