Homework on Hash Functions - Questions

  1. Describe hash functions with your own words
    Each input has its unique output or finger print. Data integrity because if you change input and you hash it delivers a different 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).

Blocks in bitcoin are linkend to each other by using the hash256. Input are the public adres of the previous block and a merkle tree were transactions are hashed to 1 fingerprint.

  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 in means that it is highly unlikely (but not mathematically imposable) to get the same output from a hash function.

  1. Hash functions are a function that take an input and produce a unique, deterministic, non reversible (pre-image resistant) output.

  2. Wrt/ crypto, hash functions are used to encrypt the data in any given block, as well as reference the previous blocks hash (pointers) producing what is essentially a linked list. In this way, a crypto gains much of its security and anonymity properties.

  3. Collision resistance is a property of hash functions where it is infeasible that two unique inputs produce the same output.

  1. A Hash Function is like a finger print of all data used (input). Its a function that works one way and reversing is impossible.

  2. Hash Functions used in cryptocurrencies like Bitcoin are used to record Txs. The Hash will contain data from the new block and the old block, therefore making it difficult to go in a make changes.

  3. Collision resistant means that there cant be two inputs with the same output.

  1. Hash function is a one-way function, meaning you cannot determine input based on the fixed-size output. Used the generate digital fingerprints.

  2. They are an important part of information security in general, but in Bitcoin they are used to write new transactions to the block.

  3. It means that we need to know that each output can be the result of only one input. If multiple inputs were able to create the same output, the output as a signature of data becomes meaningless.

  1. A hash function is a mathematical formula that take an input from the user and outputs a string of characters that are unique to the input. Therefore just changing a single character in the input will result in a completely different output. Also knows as one way functions meaning you cant produce the input from knowing the output.

  2. Hash functions are instrumental to the foundation of bitcoin. Sha256 is used to cryptographically secure the network. Each block that is created is linked by the previous hash therefore changing anything within the ledger would require the nodes to change each block afterwards and ā€œforkā€ the network. (this would require 51% of the network to agree {consensus} approval the faulty changes)

  3. Collision resistant is a term used for hash functions that DO NOT produce the same output with two different inputs. each output much be completely different with even the slightest of changes to the input if you are to have a secure system.

  1. Describe hash functions with your own words

A hash function is a function that can be used to map data of arbitrary size to fixed-size values. Each unique input gives a unique output and you can’t take the the output to find the input.

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

That’s because it is part of the mining process and miners responsibility: the miners pick some transactions up and using them as part of the input, they try to calculate a hash function to provide a new block to the chain

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

If a hash function was not collision resistant, we could find multiple messages which produce the same hash and sign this resulting digest. It would bring problems to the verification of the transactions

  1. Hash functions are mathematical functions used for taking an input of any length to produce a fixed size output. There are one way factions therefor almost impossible to reverse.
  2. The main factor is to ensure Security. And they have to have certain properties (Collision resistance, Hiding and Puzzle Friendliness) to be cryptographically secure. Not all properties are needed to define a general hash function. A property like puzzle friendliness is not required in cryptographic hash functions but it is very useful for cryptocurrencies.
  3. A collision happens when two different inputs produce the same output. Even when a collision detection method can exist, if we use a hash function with a 256-bit output it would take for ever to compute. That is why we say it’s collision resistant. It is one of the properties for a hash function to be secure.

[quote=ā€œivan, post:1, topic:8430ā€]

1. Describe hash functions with your own words.
Answer: A has function designates a unique input to a unique output or ā€œfingerprintā€. Any inout change will result in a different output and therefore an orginial input can be verified by its hash or an alphanumeric string of data which could be any length.

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).
Answer: Hash functions are part of the Block hashing algorithms in the Bitcoin protocol and are used in writing new transactions on the blockchain through the mining process. The hash functions oneway fingerprint is critical to the ā€œproof of workā€ algorithm to complete a block by verifying inputs. (Corin Faife - https://www.coindesk.com/bitcoin-hash-functions-explained)

3. What does it mean when we say that hash functions need to be collision resistant?
[/quote] Answer: Collision resistance says that ā€œgiven two 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 for the most part, each input will have its own unique has it’s own unique hash. The exception is " The Birthday Paradoxā€. A collision resistant hash function is based on the Merkle-Damgard paradigm.
(BlockGeeks.com)

  1. Describe hash functions with your own words.

Hash functions have two main characteristics. The first is that each individual input produces its very own individual output – a digital fingerprint, if you like. The digital fingerprint (called a digest) created by the input (called a string) is a collection of digits and letters that is always the same length, irrespective of the amount of data. The second characteristic is that any inputs can only lead to an output, and not vice versa (output to an input).

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

Hash functions are used in Bitcoin to create completely individual new blocks. The hash functions are currently so difficult that it takes the world’s network of computers approximately 10 minutes to solve each one of these computations. Each new block contains the input of the previous block, a block number and also a time/date stamp to make it as unique as possible.

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

Hash functions need to be ā€˜collision resistant’ to avoid the scenario of two completely different inputs (strings) producing exactly the same output (digest). In reality, this is not impossible but pretty much infeasible.

1.Hash functions are made from a certain input string of any length which in turn produces an output of fixed lengh changes in the input will change the output but you can not change the output in order to change the input,so in essence it’s a one way street.

2.Hash functions used in Bitcoin are essentially transactions used as an input and then they are going through a hashing function which gives an output of a fixed length.

3.It basically means that it will be (almost) impossible to have the same output result from two different input strings.

1. Describe hash functions with your own words
Its a computational algorithm which receive an input and create an unique hash fingerprint output.
Since its produce an unique fingerprint, its practically impossible to have 2 equals fingerprint of an input.

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).
Bitcoin create an unique hash for every transaction, so every miner have to calculate the hash from an input, if the hash is unique and approve to be valid on the blockchain network, this will be added on the next block which miners calculate.
The blockchain allow us to keep a trust less record of every transaction since we can verify the unique hash of those. Thanks to the immutability, those hashes are 100% the same forever.

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 means that its very hard to find two inputs that produce the same output.
Meaning, every function reduce the probability to have collision, sha256 could have collision but probabilities to find the outputs are very low since its very hard to.

  1. A hash function takes an input and produces an output. From a hashed output you can’t find the input.
    Any small change in the input will give you a different output.
  2. In bitcoin every block based on inputs is hashed plus every block hash is dependent on previous block hash, so the blocks are linked.
  3. We take two different inputs A and B and after hashing them H(A) can’t be equal to H(B).
  1. Hash functions are a way to make any size of an input to give an exact amount of output and with no way to find the input by the output.
  2. In bitcoin the blockchain is using hash functuons to record the transactions and connect them to each other in blocks.
  3. To prevent a function to give the same output for two different inputs.
**1. Describe hash functions with your own words**

Hash functions are special functions that when they get a unique input they give you a unique output.
Each unique input gets its own unique output. With most hash functions like the BITCOIN blockchain uses ( SHA - 256 ) its almost impossible to go back from an output to an input.

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

BITCOIN uses the hash function called SHA - 256 and that gives it the ability to generate a unique output for each and every input of a transaction that has been made and will be made. Also this hash function is being used from the BITCOIN miners to try and find the mathematical solution of a 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).**

That means their mathematical algorithm when executed must not be able to produce the same output for two different inputs and only give a unique output for every input. With the SHA - 256 that almost impossible.

Describe hash functions with your own words

In a hash function you can create output from inputt but you cant get to input from output…

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 algoritm which is used to write new transactions into the blockchain through the mining process.

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

For every input of the hash function we neet to have different outputs. I for two inputs we have same output than we have a collusion.

  1. Hash functions are the functions that returns a hash value as an output to input. Hash functions are uni-directional ie you can only convert an input to output using hash function whereas you cannot convert an output to input.

  2. Hash functions are used in cryptocurrencies using Secured Hash Algorithm

  3. Even when a small change is made to input, it drastically changes the output. This feature is called collision resistant.

  1. hash functions is a secure way to ā€œhideā€ any Information you want, cause there is littarly no way to ā€œtrackā€ it backwards. So to say: you can Always no the Output, but never be able to know what the Input was.

  2. It’s the need for this large amount of processing power that means new bitcoins get mined over a long period of time, not all at once (source: https://www.coindesk.com/bitcoin-hash-functions-explained). Means, with hash funcitions in the Bitcoin Blockchain we can ensure, that every Transaction is trustlessnes…

  3. It means, that there can not be two same ā€œOutputsā€ created by two different ā€œInputsā€

  1. Hash functions take data as input and then output unique code for it.

  2. In mining and transactions. Every transaction needs to have a unique hash.

  3. It means that two different inputs cant have the same output.

Homework on Hash Functions - Questions

  1. Describe hash functions with your own words
    Hashing is generating a value or values from a string of text using a mathematical function

  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).
    Hashes are used to link and encrypt data in cryptocurrencies. Like in blockgeneration you take hash to form the header of the next 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).
    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)

Hash functions are unique identifiers that are outputted based upon a specific input criteria. If the input changes, so does the hash function.

Hash functions are used in Bitcoin by being stored in each Block of the previous Block. Once a Block is finalized it is stored in the next Block and so on. If any previous Block is changed the hash/Block chain becomes inconsistent.

Hash functions need to be collision resistant in that, eg, if two miners discover the same hash tag to mine a certain block at the same time, then these two hashes become orphans and not added to the Blockchain. This happens when two different inputs creates the same output. This is possible when there are more inputs than outputs. In SHA256 this is unlikely, due to output hash length, but not impossible.