Tanagi (OP)
Newbie
Offline
Activity: 27
Merit: 16
|
|
September 10, 2021, 10:08:41 AM |
|
Hey guys, Looking to see if anyone can tell me how to modify the Vanitygen code so that it will start searching at the same point every time and not jump around to another random search position. Thanks in advance )
|
|
|
|
a.a
Member
Offline
Activity: 126
Merit: 36
|
|
September 10, 2021, 10:57:42 AM |
|
Link to the sourcecode plz
|
|
|
|
a.a
Member
Offline
Activity: 126
Merit: 36
|
|
September 10, 2021, 12:09:50 PM |
|
Is it not enough to set the seed with the -s command parameter?
|
|
|
|
WanderingPhilospher
Full Member
Offline
Activity: 1148
Merit: 237
Shooters Shoot...
|
|
September 11, 2021, 03:03:13 AM |
|
No I tried that.
What I want it to do is return the same results for the exact same search every time.
So it would need to start at the same point and search in a linear rather than random way.
What are you trying to accomplish via starting at same point every time? I ask because I may know of other code that would do what you are wanting.
|
|
|
|
ymgve2
|
|
September 11, 2021, 08:21:42 AM |
|
Linear search is MUCH faster than random since with linear search you just do a single ECC addition for each new address instead of computing a full ECC private-> public multiplication for random search.
|
|
|
|
pooya87
Legendary
Offline
Activity: 3584
Merit: 10878
|
|
September 11, 2021, 08:32:22 AM |
|
Linear search is MUCH faster than random since with linear search you just do a single ECC addition for each new address instead of computing a full ECC private-> public multiplication for random search.
I don't think any of them work like that. That would be a silly implementation. The starting point is always random, from that point the next try will increment the initially random private key (private key +=1 that is public key + G). There isn't much to be "researched" if the starting point is always the same since we are talking about a completely random and unpredictable result (ie. hash) and setting a fixed starting point creates bias in the result. For example the key you chose may already start with the character(s) you are looking for in the address without needing to increment so your test will give you 0 tries to get the address which is a false conclusion.
|
|
|
|
NotATether
Legendary
Offline
Activity: 1736
Merit: 7276
In memory of o_e_l_e_o
|
|
September 11, 2021, 12:11:37 PM |
|
Just remove the EC_KEY_generate_key function at line 129 and increment the private key, and then use something like BN_set_word to increment the private key int manually and then run EC_POINT_mul to multiply it by G. Disclaimer: The linear search will probably be faster, I suspect that the key generation method is slow.
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3444
Merit: 17397
Thick-Skinned Gang Leader and Golden Feather 2021
|
|
September 12, 2021, 08:25:22 AM |
|
I would like to know if it's possible for Vanitygen to show both the privkey AND the privkeypart for the found address when performing piecewise key generation. The system must know the privkey for the address to generate it, right? Vanitygen creates a PrivkeyPart if you use a Public Key with your search. That means you'll need the Private Key that belongs to the Public Key to convert the PrivkeyPart to the Private Key that beloings to the vanity address. Vanitygen doesn't know both parts (otherwise split key wouldn't be secure). Maybe this helps: Some people have a hard time figuring out the steps under Vanity Wallet on bitaddress.org. I'll give an example. If something goes wrong, try to reproduce these steps: From bitaddress.org, under Vanity Wallet:Step 1 Public Key (this is what you give to me)042B340ACEDBB68F0B556CEB98DD7AF5948433729EC67B6352FFF02B4786FAE6EDC2C55CBC7C2DD 75F121621205CCE54A8D75C876B45E5171BFB30969CE1FD96F6 [do not use this key!]Step 1 Private Key (this is what you keep a secret and store in a safe place)CD7A2E75421CD5759F06AC2F15434866B8A2EE757521A2E8C072259EB9B47FC8 [do not use this private key!]Now make a Vanity address (this is what I give to you):Address: 1testk68KLEEPXegwfBdfKeRga3egnuB3 [do not use this address!]PrivkeyPart: 5JjHAypWFAY4Nc4mLCuGrYKUdgLAM4jXgcXKZLFEiXQXUyAfi4T [do not use this key!]Back to bitaddress.org, Vanity Wallet Step 2:I enter CD7A2E75421CD5759F06AC2F15434866B8A2EE757521A2E8C072259EB9B47FC8 I enter 5JjHAypWFAY4Nc4mLCuGrYKUdgLAM4jXgcXKZLFEiXQXUyAfi4T It shows this:Vanity Bitcoin Address: 1testk68KLEEPXegwfBdfKeRga3egnuB3 [do not use this address!]Vanity Private Key (WIF): 5JM2dw6JaG768CcexgdqW4j2VkTYPpympNpoSBziaPcERJGLBd8 [do not use this private key!]
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3444
Merit: 17397
Thick-Skinned Gang Leader and Golden Feather 2021
|
|
September 12, 2021, 01:51:29 PM |
|
Vanitygen must know the privkey in order to calculate the address and the privkeypart, right? No, when using split key, vanitygen doesn't know the final private key. The exact details of how it's done are lost on me though.
|
|
|
|
n0nce
|
|
September 12, 2021, 10:04:54 PM |
|
Vanitygen must know the privkey in order to calculate the address and the privkeypart, right? No, when using split key, vanitygen doesn't know the final private key. The exact details of how it's done are lost on me though. It's called split-key vanity address, short answer in the first sentence: Everybody can use this public key to find the complementary public key leading to a vanity address. The user can than merge his private key with the complementary private key, leading to the private key of the vanity address. The security of such solution is guaranteed by the properties of the Elliptic Curve Cryptography
|
|
|
|
WanderingPhilospher
Full Member
Offline
Activity: 1148
Merit: 237
Shooters Shoot...
|
Just remove the EC_KEY_generate_key function at line 129 and increment the private key, and then use something like BN_set_word to increment the private key int manually and then run EC_POINT_mul to multiply it by G. Disclaimer: The linear search will probably be faster, I suspect that the key generation method is slow. The other thing to keep in mind, you can edit code to make it start at same point/key, each and every time, but when using a GPU, normally the code works like this: take GPU x and y grid size; let's say our is 10x10 then the program takes your range/keyspace, let's say we have a range of 1000000 now the program divides the range by the grid size, in our example: grid is 10x10 = 100 range size = 1000000 so the program spreads out each GPU thread every 10000 keys/points, and then works incrementally. Same is true for CPU threads as well. Now you can control this via only using 1 CPU thread and that 1 thread will count incrementally. But if you plan on using GPU, you will need to edit the code more or just know that while it will start from same point, it will be same point plus grid/range. Also, if you have nothing to tell the program that x amount of keys have been reached/searched, then your GPU threads will be redoing the keys already ran by other GPU threads. So you have to put in a "nextkey" function that basically says, take grid, take range, take speed, calculate those things, and jump all threads forward by the calculation, once the calculation has been met.
|
|
|
|
Meitzi
Newbie
Offline
Activity: 7
Merit: 9
|
|
November 15, 2021, 12:28:36 PM |
|
Hey guys, Looking to see if anyone can tell me how to modify the Vanitygen code so that it will start searching at the same point every time and not jump around to another random search position. Thanks in advance ) Are you trying to remove randomness or only like save / resume function? If you are removing randomness, then it means, I will get also your private key if I run same code with same starting pattern.
|
|
|
|
Tanagi (OP)
Newbie
Offline
Activity: 27
Merit: 16
|
|
September 12, 2022, 05:51:58 AM |
|
Just remove the EC_KEY_generate_key function at line 129 and increment the private key, and then use something like BN_set_word to increment the private key int manually and then run EC_POINT_mul to multiply it by G. Disclaimer: The linear search will probably be faster, I suspect that the key generation method is slow. The other thing to keep in mind, you can edit code to make it start at same point/key, each and every time, but when using a GPU, normally the code works like this: take GPU x and y grid size; let's say our is 10x10 then the program takes your range/keyspace, let's say we have a range of 1000000 now the program divides the range by the grid size, in our example: grid is 10x10 = 100 range size = 1000000 so the program spreads out each GPU thread every 10000 keys/points, and then works incrementally. Same is true for CPU threads as well. Now you can control this via only using 1 CPU thread and that 1 thread will count incrementally. But if you plan on using GPU, you will need to edit the code more or just know that while it will start from same point, it will be same point plus grid/range. Also, if you have nothing to tell the program that x amount of keys have been reached/searched, then your GPU threads will be redoing the keys already ran by other GPU threads. So you have to put in a "nextkey" function that basically says, take grid, take range, take speed, calculate those things, and jump all threads forward by the calculation, once the calculation has been met. Thanks so much for this... I am only using CPU, but would obviously like to use all threads to work on the search. Do you think you could provide the code I need to make it work incrementally? I would really appreciate it. Thanks in advance.
|
|
|
|
nc50lc
Legendary
Offline
Activity: 2548
Merit: 6137
Self-proclaimed Genius
|
|
September 12, 2022, 07:01:48 AM |
|
The other thing to keep in mind, you can edit code to make it start at same point/key, each and every time, but when using a GPU, normally the code works like this: -snip-
-snip-Do you think you could provide the code I need to make it work incrementally? I would really appreciate it. WanderingPhilospher already made a Vanitysearch/Bitcrack fork that can do exactly that: https://github.com/WanderingPhilosopher/VanBitCrakcenS/releasesThe source code is only available in the 'releases' page. It also has a command line argument --continue that'll save the position where you left off.
|
|
|
|
Tanagi (OP)
Newbie
Offline
Activity: 27
Merit: 16
|
|
September 13, 2022, 01:25:34 AM Last edit: September 13, 2022, 01:58:00 AM by Tanagi |
|
Thanks, but there is only an .exe and no source code to look at unfortunately, only the readme inside the zip.
|
|
|
|
NotATether
Legendary
Offline
Activity: 1736
Merit: 7276
In memory of o_e_l_e_o
|
|
September 14, 2022, 02:13:04 AM |
|
Thanks, but there is only an .exe and no source code to look at unfortunately, only the readme inside the zip.
It's closed-source I believe, so it only works for Windows. Were you looking to run it on Linux? If you're just running CPU search, WINE is going to be super slow but it should work under it correctly.
|
|
|
|
Tanagi (OP)
Newbie
Offline
Activity: 27
Merit: 16
|
|
September 14, 2022, 03:05:23 AM |
|
Thanks, but there is only an .exe and no source code to look at unfortunately, only the readme inside the zip.
It's closed-source I believe, so it only works for Windows. Were you looking to run it on Linux? If you're just running CPU search, WINE is going to be super slow but it should work under it correctly. Ok, thanks. Yeah, running on Ubuntu 20.04.
|
|
|
|
BHWallet
Newbie
Offline
Activity: 62
Merit: 0
|
|
September 14, 2022, 01:26:59 PM |
|
Thanks, but there is only an .exe and no source code to look at unfortunately, only the readme inside the zip.
It's closed-source I believe, so it only works for Windows. Were you looking to run it on Linux? If you're just running CPU search, WINE is going to be super slow but it should work under it correctly. Ok, thanks. Yeah, running on Ubuntu 20.04. Even without the --continue option you can use the last found key position as starting range on your next search. Just look for shorter pattern so the software will dump keys every 20-30min, that way you will always know "where you are".
|
|
|
|
Tanagi (OP)
Newbie
Offline
Activity: 27
Merit: 16
|
|
October 05, 2022, 11:16:53 PM |
|
If anyone is willing and has the skills to help me with this, I am more than happy to pay for the help.
Please dm me for the full details if interested.
Thanks.
|
|
|
|
PawGo
Legendary
Offline
Activity: 952
Merit: 1373
|
|
October 06, 2022, 06:56:31 AM |
|
If anyone is willing and has the skills to help me with this, I am more than happy to pay for the help.
Please dm me for the full details if interested.
Thanks.
If you talk about project https://github.com/JeanLucPons/VanitySearch/, then take a look at file https://github.com/JeanLucPons/VanitySearch/blob/master/Vanity.cppThere in line 306 the process of setting initial key starts. If you ignore the next like (sha256), and set your desired key, it should work. Ah, and of course do not use 'rekey' option.
|
|
|
|
|