MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
September 26, 2019, 05:51:18 PM |
|
So, what do you think about the key generation through the 256 coin flips? [my opinion - is is the most secure way nowadays] As long as you're certain the software you use actually creates a private key from your coin flips, this could be very secure. I'm saying this because of the paper wallet website that was compromised recently: it generated pre-defined private keys, even when used offline, and people are still losing funds because of it. If you're using coin flips, it doesn't hurt to create the private key with different software on independent systems, and ensure they're the same (and always on air-gapped hardware that won't ever go online again). Yes, yes and yes, I'm with you. And it was the initial idea to create the key from the coin flip outcomes. I was also concerned about offline paper wallets as their random algorythms could be pre-defined. The first keys I created in Excel: filled the cells 16x16 with 1 or 0, then combined bits by every line and concatenating all lines received the full 256 bin number, converted it to HEX and go to online tool to convert to addres or use phyton function locally. It was long and boring, so I decided to develop this tool. While developing I also added the random function and own key visualization - but yes, these both are only could be used for educational or fun purposes. The real key should be generated only from the cion flip outcomes.
|
|
|
|
pooya87
Legendary
Offline
Activity: 3542
Merit: 10778
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
September 26, 2019, 06:57:54 PM |
|
it is interesting to "visualize" a private key in binary and also if you use the first method (coin flip) to create r idea.
So, what do you think about the key generation through the 256 coin flips? [my opinion - is is the most secure way nowadays] that was one of the interesting parts about your project actually. it makes recording the flip results and eventual conversion to an integer (or hex) which you could then store or use as your private key, a lot easier than using bash or generally a command line option. coin flip or generally any source of entropy that doesn't depend on computers can be very secure but it is sometimes extremely hard and they require a lot of attention. you should always make sure there is no bias in the results. for example the coin should be symmetrical and your flips should always have a 50-50 chance of heads or tails. and you have to repeat this 256 times and each time do it in the same exact way, that is not easy!
|
|
|
|
MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
September 26, 2019, 07:32:28 PM Last edit: September 27, 2019, 12:19:34 PM by MrFreeDragon Merited by Welsh (4), ABCbits (2), pooya87 (1) |
|
the coin should be symmetrical and your flips should always have a 50-50 chance of heads or tails.
I do not beleive that it is possible to find exactly 50/50 symmetrical coin and the physical conditions to this. Morover for private key creating the small skewness could be the additional entropy (like ones use the coin 51/49, others use the floor conditions or toss habits 48/52, etc). Interesting fact, that a statistics professor has asked his students to flip a coin over the several months period. He devided his students into 2 groups - one group really used the coin and recorded the results, but another group was asked to imagine that they use the coin and record the results from their assumptions the coin outcome could be. After collecting the results the professor was able to identify each group: the "guessing" group's results were very close to 50/50, but the results of the group really fliped a coin were wider than 50/50. Another professor asked students to flip coins over a years, and he has formed a 95% confidence interval for the long-run population proportion of heads to be (0.497/0.513). Yes, the narrow results, but not yet 50/50 Thats why the ideal 50/50 coin is not very neccessary, some small deviation is allowed in real life.
|
|
|
|
hatshepsut93
Legendary
Offline
Activity: 3038
Merit: 2155
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
September 26, 2019, 11:02:55 PM Last edit: September 26, 2019, 11:14:31 PM by hatshepsut93 |
|
Use this instead of Math.random() - https://developer.mozilla.org/en-US/docs/Web/API/Crypto/getRandomValuesThere's no excuse to not use it when you are dealing with something that is even remotely required to be secure, just a few lines of code can potentially save someone from big trouble in the future. Also consider creating a repository on Github for this project, so that people can see the changes in the source files and download from a place other than the site. Also Github is a good place to discuss issues and suggestions, and you might even get other people to help you with your code.
|
|
|
|
MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
September 27, 2019, 01:00:14 AM |
|
Also consider creating a repository on Github for this project, so that people can see the changes in the source files and download from a place other than the site. Also Github is a good place to discuss issues and suggestions, and you might even get other people to help you with your code.
Yes, i will make the repository on Github later. This was already discussed here earlier see the qute below the reason why. Morover, I have the question to the coders to make the script faster for IE. In Interent Explorer and Edge the code works very slow - so it is possible there only tick one cell by cell. But on all other browsers it is possible to clickdown the mose and move filling several neighbor cells while moving the mouse. additionally i see a zip file link at the bottom. is your project open source? if it is, sharing it on GitHub and linking it there is a better idea.
Primarily I decided to post the project here to discuss the topic and idea with the the subject specialists. If it is interesting, of course I will share it on GitHub for subsequent code discussions. The is no need to discuss the code for thing of naught.
|
|
|
|
A-Bolt
Legendary
Offline
Activity: 2323
Merit: 2351
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 02, 2019, 11:15:04 AM |
|
But for better securitty it is recommended to download the whole site and generate the key offline.
Download ZIP is a broken link (Not found).
|
|
|
|
thirdprize
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 02, 2019, 12:55:33 PM |
|
Chances of twopeole drawing the same pattern? Relatively high.
|
|
|
|
MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 03, 2019, 10:18:57 AM |
|
But for better securitty it is recommended to download the whole site and generate the key offline.
Download ZIP is a broken link (Not found). Thank you. Recovered. ![Wink](https://bitcointalk.org/Smileys/default/wink.gif) The zip file was named VisualBTC.zip, but the link - visualBTC.zip (1st letter "V" instead of "v")
|
|
|
|
MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 03, 2019, 10:24:43 AM |
|
Chances of twopeole drawing the same pattern? Relatively high.
Nice question. And it has been already discussed in this topic earlier. Of course the pattern could be not secure. I will add the warning message not to create the real money bitcoin address based on visual pattern, and use these addresses only for educational purposes or just for funny small gifts to the friends, which could be unusual and cool in some cases. The most secured way to create the address is to flip the physical coin and fill each cell of the square based on the coin's outcome.
|
|
|
|
MrFreeDragon (OP)
|
I added the warning messages about drawing patterns and suggested to create the address only with the coin flip. Also added the messsage to the "Visualize Key" section to think twice before visualizing the key. "Drawing" pictures, logos, figures and use them for private keys could be made only for educational purposes, or/and some small bitcoin gifts to friends ![Cool](https://bitcointalk.org/Smileys/default/cool.gif) I also created the repository on GitHub and added the link to the initial message of this topic: https://github.com/MrFreeDragon/VisualBTC
|
|
|
|
AB de Royse777
Legendary
Offline
Activity: 2576
Merit: 4013
Hire Bitcointalk Camp. Manager @ r7promotions.com
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 08, 2019, 04:06:07 PM |
|
![](https://ip.bitcointalk.org/?u=https%3A%2F%2Fi.imgur.com%2FmCMJxrc.png&t=665&c=b8o_VIE4NaLoYg) Thank you and good to see the conversation is still alive.
|
..Stake.com.. | | | ▄████████████████████████████████████▄ ██ ▄▄▄▄▄▄▄▄▄▄ ▄▄▄▄▄▄▄▄▄▄ ██ ▄████▄ ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██ ██████ ██ ██████████ ██ ██ ██████████ ██ ▀██▀ ██ ██ ██ ██████ ██ ██ ██ ██ ██ ██ ██████ ██ █████ ███ ██████ ██ ████▄ ██ ██ █████ ███ ████ ████ █████ ███ ████████ ██ ████ ████ ██████████ ████ ████ ████▀ ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██ ██ ▀▀▀▀▀▀▀▀▀▀ ██ ▀█████████▀ ▄████████████▄ ▀█████████▀ ▄▄▄▄▄▄▄▄▄▄▄▄███ ██ ██ ███▄▄▄▄▄▄▄▄▄▄▄▄ ██████████████████████████████████████████ | | | | | | ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄ █ ▄▀▄ █▀▀█▀▄▄ █ █▀█ █ ▐ ▐▌ █ ▄██▄ █ ▌ █ █ ▄██████▄ █ ▌ ▐▌ █ ██████████ █ ▐ █ █ ▐██████████▌ █ ▐ ▐▌ █ ▀▀██████▀▀ █ ▌ █ █ ▄▄▄██▄▄▄ █ ▌▐▌ █ █▐ █ █ █▐▐▌ █ █▐█ ▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█ | | | | | | ▄▄█████████▄▄ ▄██▀▀▀▀█████▀▀▀▀██▄ ▄█▀ ▐█▌ ▀█▄ ██ ▐█▌ ██ ████▄ ▄█████▄ ▄████ ████████▄███████████▄████████ ███▀ █████████████ ▀███ ██ ███████████ ██ ▀█▄ █████████ ▄█▀ ▀█▄ ▄██▀▀▀▀▀▀▀██▄ ▄▄▄█▀ ▀███████ ███████▀ ▀█████▄ ▄█████▀ ▀▀▀███▄▄▄███▀▀▀ | | | ..PLAY NOW.. |
|
|
|
MrFreeDragon (OP)
|
I also made a video instruction how to create a bitcoin private key by flipping a coing 256 times: https://youtu.be/WyBdYhwweaEThe video is fast moving, but in reality the total my time to flip the coin 256 times was 16 minutes. I tried to do it very fast. Considering the time for filling the cells and printing the key, the total time for private key generation will be approximately 20 minutes.
|
|
|
|
AB de Royse777
Legendary
Offline
Activity: 2576
Merit: 4013
Hire Bitcointalk Camp. Manager @ r7promotions.com
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 12, 2019, 09:10:23 PM |
|
I also made a video instruction how to create a bitcoin private key by flipping a coing 256 times: https://youtu.be/WyBdYhwweaEThe video is fast moving, but in reality the total my time to flip the coin 256 times was 16 minutes. I tried to do it very fast. Considering the time for filling the cells and printing the key, the total time for private key generation will be approximately 20 minutes. Okay this is fun :-D Have you considered to add it in the website. Visitors will have real interest in that case to give it a try.
|
..Stake.com.. | | | ▄████████████████████████████████████▄ ██ ▄▄▄▄▄▄▄▄▄▄ ▄▄▄▄▄▄▄▄▄▄ ██ ▄████▄ ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██ ██████ ██ ██████████ ██ ██ ██████████ ██ ▀██▀ ██ ██ ██ ██████ ██ ██ ██ ██ ██ ██ ██████ ██ █████ ███ ██████ ██ ████▄ ██ ██ █████ ███ ████ ████ █████ ███ ████████ ██ ████ ████ ██████████ ████ ████ ████▀ ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██ ██ ▀▀▀▀▀▀▀▀▀▀ ██ ▀█████████▀ ▄████████████▄ ▀█████████▀ ▄▄▄▄▄▄▄▄▄▄▄▄███ ██ ██ ███▄▄▄▄▄▄▄▄▄▄▄▄ ██████████████████████████████████████████ | | | | | | ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄ █ ▄▀▄ █▀▀█▀▄▄ █ █▀█ █ ▐ ▐▌ █ ▄██▄ █ ▌ █ █ ▄██████▄ █ ▌ ▐▌ █ ██████████ █ ▐ █ █ ▐██████████▌ █ ▐ ▐▌ █ ▀▀██████▀▀ █ ▌ █ █ ▄▄▄██▄▄▄ █ ▌▐▌ █ █▐ █ █ █▐▐▌ █ █▐█ ▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█ | | | | | | ▄▄█████████▄▄ ▄██▀▀▀▀█████▀▀▀▀██▄ ▄█▀ ▐█▌ ▀█▄ ██ ▐█▌ ██ ████▄ ▄█████▄ ▄████ ████████▄███████████▄████████ ███▀ █████████████ ▀███ ██ ███████████ ██ ▀█▄ █████████ ▄█▀ ▀█▄ ▄██▀▀▀▀▀▀▀██▄ ▄▄▄█▀ ▀███████ ███████▀ ▀█████▄ ▄█████▀ ▀▀▀███▄▄▄███▀▀▀ | | | ..PLAY NOW.. |
|
|
|
naska21
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 14, 2019, 12:06:40 PM |
|
snip
Funny tool but I wonder if there is any algorithm capable to randomly choose the cells in that 16x16 square. In fact I have found how to randomly select Excel's cells that can be applied for such task but I'm not quite sure if the method they offer is truly random.
|
|
|
|
bitmover
Legendary
Online
Activity: 2394
Merit: 6182
Crypto Swap Exchange🈺
|
I also made a video instruction how to create a bitcoin private key by flipping a coing 256 times: https://youtu.be/WyBdYhwweaEThe video is fast moving, but in reality the total my time to flip the coin 256 times was 16 minutes. I tried to do it very fast. Considering the time for filling the cells and printing the key, the total time for private key generation will be approximately 20 minutes. Good job. This method is very cool, as you can generate a private key without a computer. however, to get the public address we need a computer.
|
|
|
|
pooya87
Legendary
Offline
Activity: 3542
Merit: 10778
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 15, 2019, 04:09:00 AM |
|
snip
Funny tool but I wonder if there is any algorithm capable to randomly choose the cells in that 16x16 square. In fact I have found how to randomly select Excel's cells that can be applied for such task but I'm not quite sure if the method they offer is truly random. if you don't think of it as "selecting cells" then the solution would become clear. (same with your link about excel). basically it is two steps: 1) assigning a number to each cell. 2) selecting a random number! in this case each cell is the binary representation so it has only two modes: on and off or 1 and 0. so all you have to do is generate a random number, convert it to binary and set cells state using the bits. by the way that is what the random button at the bottom of the square is supposed to do.
|
|
|
|
Saint-loup
Legendary
Offline
Activity: 2702
Merit: 2408
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 22, 2019, 06:03:12 PM |
|
Nobody could crack 256 independent outcomes generated by a physical coin fliped offline. It is 2^256 possible combinations - you can not imagine how much is it! It is the most secure way for paper wallet creation, as it does not use any computer random algorithms.
2^256 is the security of the bitcoin network, all keys are generated within that range. -snip- No in fact the security of the bitcoin network can't be 2^256 because there are only 2^160 addresses existing thanks to the RIPEMD160 hashing. RIPEMD160 provides hashes on only 160bits, so addresses have several different private keys. To crack one address in brute-force you don't need to try each 2^256 keys but only 2^160 at most. Furthermore, it's known ECDSA can be cracked by O(n 1/2) algorithms. So the security of bitcoin is actually 2^128 You undo exponentiation by taking logarithms, so the process of solving for k is called the discrete logarithm problem. The security of elliptic curve cryptography depends on the difficulty of computing discrete logarithms.
Counting bits of security The best algorithms for solving discrete logarithm problem in a group of size n currently require O(√n) operations. How big is n in our case?
The base point g was chosen to have a large order, and in fact its order is approximately 2256. Specifically, the order of g written in hexadecimal is
n = FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141.
This means that we get approximately 256/2 = 128 bits of security because √(2256) = 2128. https://www.johndcook.com/blog/2018/08/14/bitcoin-elliptic-curves/ https://bitcointalk.org/index.php?topic=2859033.0https://bitcointalk.org/index.php?topic=1007619.0
|
|
|
|
MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 22, 2019, 07:20:36 PM |
|
Nobody could crack 256 independent outcomes generated by a physical coin fliped offline. It is 2^256 possible combinations - you can not imagine how much is it! It is the most secure way for paper wallet creation, as it does not use any computer random algorithms.
2^256 is the security of the bitcoin network, all keys are generated within that range. -snip- No in fact the security of the bitcoin network can't be 2^256 because there are only 2^160 addresses existing thanks to the RIPEMD160 hashing. RIPEMD160 provides hashes on only 160bits, so addresses have several different private keys. To crack one address in brute-force you don't need to try each 2^256 keys but only 2^160 at most. -snip- [/quote] Yes, you are talking about the colission here. And here it is offtopic. You are welcome to discuss this in my separate topic: https://bitcointalk.org/index.php?topic=5185726From the point of the exact private key the security is 2^256. But of course due to RipeMD160 there is actually no need in exact private key, and on average 2^96 keys could be suitable. Furthermore, it's known ECDSA can be cracked by O(n1/2) algorithms. So the security of bitcoin is actually 2^128 -snip-
This square root could be applied if you know the pulic key. But the public key is unknown for addresses without outgoing transactions. And modern wallets also designed in the way to generate new addess after every spending, so knowing the public key actually useless.
|
|
|
|
DiamondCardz
Legendary
Offline
Activity: 1134
Merit: 1113
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 22, 2019, 08:44:43 PM |
|
Very nice project, it's almost deceiving in how simple it makes private keys look - people have already asked if it's easy to brute force keys because of it, I feel that they don't understand how many combinations of 256 bits you can get!
I would appreciate it if you put a warning in telling people explicitly to use it offline, especially as you encourage people to put in their own private keys to 'visualize' it in your application. Obviously anyone doing that would be crazy to do it online, but there are a lot of newbies in this community nowadays...
|
BA Computer Science, University of Oxford Dissertation was about threat modelling on distributed ledgers.
|
|
|
MrFreeDragon (OP)
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
October 22, 2019, 09:01:26 PM |
|
Very nice project, it's almost deceiving in how simple it makes private keys look - people have already asked if it's easy to brute force keys because of it, I feel that they don't understand how many combinations of 256 bits you can get!
I would appreciate it if you put a warning in telling people explicitly to use it offline, especially as you encourage people to put in their own private keys to 'visualize' it in your application. Obviously anyone doing that would be crazy to do it online, but there are a lot of newbies in this community nowadays...
Thank you for your feedback. As for the recomendation to use it offline I made it in "Information" block (link at the bottom): "[9] Security. The code is open source. All the private keys are generated on client side, in your browser. This site does not copy or store the information generated by you. Even so we recommend downloading this site (it is available in zip) on your computer, disconnect from the internet and generate the key offline."zip is available for download form the site directly, and the code is also pubslihed on github, so everybody can have a look at the code and confirm that there are no any back doors or other things to store alien private keys. I personally like the idea to download the project and generate the key offline - so it makes the process completely secure. Moreover, while you use the physical coin, nobody can assume what outcomes did you have. Other projects (even offline) could generate the key pseudo-random - you will see different points on the screen during your text typing or mouse moving, but you can not be sure that the the final key is random :-) With physical coin you can be sure! PS. I ordered 16-side dice, and some later will make video how to generate a key with that dice (HEX symbols could be typed directly to the input field of Visualize section). Only 64 tosses are requred (instead of 256 coin flips) - one 16dice toss contains 4bits (from 0000 to 1111). So, the key could be generated within 4-5 minutes instead of 15-20min.
|
|
|
|
|