- hash function is a one way function, wen you have the result you can´t guess the input.
- hash functions are used in cryptocurrencies to prevent that same one change the balance of each account, change the blockchain.
- collision resistant means that is very difficult to get the same result from different inputs, if it was easy you can change the blockchain adding dumb data to meet the same hash result, in case of the blockchain probably will produce a fork
Public key is derived from a different function called elliptic curve and the private key is basically just a random number the public key is indeed hashed so we get the address
Haha sorry for my wrong answer bro, yes you are right, I’m now in the middle of public cryptography video of ivan and what you said links to what ivan said, it means I was wrong with my answer, Now I know haha thanks for the clarification bro. I really appreciate it.
-
Describe hash functions with your own words - An input converts to an fixed output and the output will always be the same. For example, a sentence will convert to 256 bit output when using SHA-256. The same output will occur if the sentence remains the same. If you change a word or punctuation for example, then that will create a new and different 256 bit output. Hash is a one way function from input to output and not output to input.
-
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 purchase/sell transaction of a bitcoin is the input and the output is the bitcoin received by the purchasing wallet. The hash function can also be used to create unique passwords.
-
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). - The computation draws from a high min-entropy distribution resulting in an extremely difficult system to get two matching outputs.
-
A hash function is a computation that takes an input and turns it into an output. It’s like turning a fingerprint into a series of numbers (represented as numbers and letters).
-
Hash functions are used to make sure inputs cannot be deciphered from their outputs. If that was possible, then bitcoin could be ‘broken’.
-
Collision resistance is a property of cryptographic hash functions. If it is difficult to find two inputs that hash to the same output, then the hash function is collision resistant. Hash functions that have more inputs than outputs will have collisions, but with bitcoin, every unique input gets a unique output, which means it is collision resistant.
- Describe hash functions with your own words
- How are hash functions used in cryptocurrencies like bitcoin?
- 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).
Answers:-
-
It converts any length of input data to a digital fingerprint output made up of letters and digits and it can only enable to convert input to output and not the other way around.
-
For cryptocurrencies like bitcoin, the transactions are taken as input and run through a hashing algorithm which gives an output of a fixed length by using SHA256.
-
It is extremely hard to find 2 inputs that hash to the same output. Hence collision resistant.
-
Hash functions are like regular functions you would find in math except they have some key differences that make them suitable for cryptocurrencies like bitcoin like the way you can’t reverse the process, you can turn an input into an output but you cannot get the output and find the input that was used to generate it.
-
You can use hash functions to hash your public key to make it more secure
-
Collision resistance in hash functions means the amount of unique hashes a function can make before they start repeating outputs, if two inputs have the same output it is called a collision. Thus it is important to have a very strong resistance to this. E.G SHA-256 will only start repeating outputs after 2^128 inputs.
Not really, the inputs and outputs are basically the locking and unlocking scripts on which you can learn more in Bitcoin programming 101 The hash of the transaction is the txid, but the main reason hash functions are used is to cryptographically link blocks in a chain
What do you mean? the inputs to a transactions are signatures to a script that was signed with the private key, and use a different function that generates public-private key pairs. Hash functions are used to hash transactions to get their id. But more importantly it links the blocks together in a chain.
It is impossible to have less possible inputs (it can literally be anything you imagine) that outputs (a number about the size of 2^256). The hash number that is generated is just so large it is infeasible that you will ever find an input that results in the same output. In a sense no hash function is collision resistant, but the probability to find an example in SHA256 is very, VERY low
That is correct, its how you get the txid, but its not as important as linking blocks together in a blockchain
Its true that we hash the public key, but it doesn’t make it more secure. The only reason we do it is to make the address a bit shorter (the public key is 65 bytes and the address is 20 bytes).
A more important for hash functions on a blockchain is to cryptographically link blocks in a chain
-
Describe hash functions with your own words
- Hash functions r algorithms that produce an output based on the input // For blockchain purposes the inputs usually seem to be values based on data sets.
-
How are hash functions used in cryptocurrencies like bitcoin?
- They r used to validate data blocks. Issa big part of mining
-
What does it mean when we say that hash functions need to be collision resistant?
- For the most part, ea input will have iss own unique hash (output)
- No hash function is totally collision-free, but it takes a long time to find collisions
-
A hash function is a way of securing any form of text data by generating a unique number or digital fingerprint that is assigned to the mentioned piece of data and is a certain amount of bits long depending on its hashing algorithm. This number is later expressed in hexadecimal.
-
In bitcoin, hash functions are primarily used in the process of adding new blocks to the blockchain, also called mining. Hash functions have a very important role for the entire blockchain ecosystem because hash functions are responsible for creating inmmutability between all the blocks. Whether is between block headers or merkle root transactions, hash functions are the backbone of blockchain because they are responsible in linking these blocks together in such a way that is infeasible to alter the information and thus creating the “block chain”. Hash functions are also used in the very last part of adding a new block which involves adding a nonce as an arbitrary string, hashing it to the block and comparing it to the current level of difficulty. All this is done in order to add some randomness in deciding who gets to mine a new block of transactions.
-
Collision resistance is one of the properties that make hash functions ideal for cryptography. When we say that hash functions need to be collision resistant, we simply mean that a hash of a certain input will most likely not be the same as the hash of other input. For example, if we have H(A) and H(B) then is unfeasible for H(A) to be equal to H(B). In theory is possible but it would take an unimaginable amount of transactions ( and time ) to find collision between two hashes therefore we say that it will most likely not occur.
Describe hash functions with your own words
Hash function is any method that you can input data of any length, and it outputs the data of a fixed length
Bitcoin uses SHA-256, which always gives the output of 256 bits.
MD5 produces a hash of 128 bits
How are hash functions used in cryptocurrencies like bitcoin?
Hash functions are used in Bitcoin with transactions being taken as input
and then placed in a hashing algorithm which is SHA-256 to created an output of a fixed length.
What does it mean when we say that hash functions need to be collision resistant?
Given that you have two different inputs,it is infeasible that both those two inputs will have the exact same hash output. Having the exact same outputs is known as a collision.
Describe hash functions with your own words A hash function receives a variably sized input (such as a String) and runs a function to produce a fixed sized output. That output is not reversible back to an input.
How are hash functions used in cryptocurrencies like bitcoin? Hash functions are used in the mining process, to record transactions onto the blockchain.
What does it mean when we say that hash functions need to be collision resistant? It is extremely difficult for two inputs to result in the same output.
1- Hash functions are one way functions where each input produces an output.
2-Hash functions are used in bitcoin to mining and perform chaining.
3-Collision resistance means that is very difficult to find 2 inputs that produce the same output in a hash function. When a collision happens it means that you suddenly have 2 different inputs with the same hashed output. This makes the algorithm unusable. If that happens, It would destroy Bitcoin.
1. Describe hash functions with your own words
A hash function is a one way function which gives a particular output of fixed length for a given input. It should not be possible to deduct the input from the out put.
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 by miners in bitcoin which need to find a hash less than the target number (remember hashes are hexadecimal numbers). The transaction data , and other data such as the time , the previous block or transaction are put through the hash function. Miners have to find a hash with a set number of leading zeros which is very difficult to do . They are rewarded for doing so.
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 collision is when two different items of data hash to the same number , we do not want this to happen in crypto so we need to use as near to a perfect hash function as possible .
- Describe hash functions with your own words
A hash function takes a unique input --> computes --> unique output. This unique output is like a digital fingerprint. Importantly, has functions are one-way functions meaning that you can only go input --> output and can never go output --> input.
- How are hash functions used in cryptocurrencies like bitcoin?
Hash functions are used by miners. The output of the hash function must be below a given difficulty level. This is how bitcoin is mined a blocks completed.
- What does it mean when we say that hash functions need to be collision resistant?
This means that it is really difficult for 2 unique inputs to generate a non unique hashed output.
-
hash functions are a type of function that take an input, changes it into an output of a certain length, which is then hard to reverse back into its original input
-
hash functions are used to write new transactions onto the bitcoin blockchain
-
collision resistance refers to the property that two different inputs should not have the same output
That is true, its how you get txid. But there is one more important use case for hash functions, can you figure out which one?