So after some research, I have found a new and yet useless solution, is there a script which could divide a point by a set range?
Like dividing target public key by 1000, 999, 998, 997 etc, we select start and end range for division and it should divide the target as many times as we specify.
For educational purposes only.😉
I did it like this by only changing the divisor because a sequential division doesn't make sense because it would end in a long float.
import bitcoin
import secp256k1 as ice
print("Generating Div-Range...")
target= "03633cbe3ec02b9401c5effa144c5b4d22f87940259634858fc7e59b1c09937852"
print("Target:",target)
Start_Range= 1000
end_Range= 2000
for i in range(Start_Range, end_Range+1):
Div = bitcoin.divide(target, i)
data = open("Div-Range.txt","a")
data.write(str(Div) +"\n")
data.close()
I don't know what a long float is, but if I do the division the way I described, I might find new tricks. Anyways thanks for the code, I hope it works as intended, if it doesn't, there is an idiot AI which can help. 😉
Just to share something I found out, so if you for example divide a point by 35, and then add 1 G to your point and divide the +1 of your point by 35, what do you think will happen?
Well the results of both divisions will have a distance equal of n/35, so if you after dividing p/35, start adding n/35 to your result, for each addition you'd get the result of +1p/35, add n/35 twice, you'd get +2p/35.
Any point on the curve, no matter what the private key is acts like "1" in real numbers, for instance, if you add 9 to your p and then divide by 5, to get the correct result you'd need to add 9/5 to your result to have the correct key. ( of course if after adding 9 to p, your k ends with 5, then dividing by 5 adding 9/5 won't give you the right key, that's how you can determine what the last digit of your k is.
Ps, about the division method, dividing a key by 1000 and then dividing it by 999, what do you think will happen? In EC, both results of both divisions will have a distance equal to "1". Just to show what I mean :
500/260 = 1.9>>>2<<<30769230769230769230769230769230769230769230769230769230769230769230769231
500/259 = 1.9>>>3<<<05019305019305019305019305019305019305019305019305019305019305019305019305
Note 2 and 3 pointed out with >>><<<, in EC that 2 turning to 3 will only add 1 to your result.
take ecc as numbers, if in numbers 3/2 = 1.5 then on the curve it will be the same. Therefore I recommend doing your theory in numbers, and then you transfer that to ecc.
For example:
This script always gives you 3 results, one of which is always an integer.
target= 100
N = 3
A = target / N
B = (target + 1) / N
C = target - (A + B)
print("pk:",target)
print("A:",A)
print("B:",B)
print("C:",str(C)+"\n")
After you have the idea, you materialize it in ECC
import bitcoin
import secp256k1 as ice
print("creating div....")
# target pubkey Compressed
target ="02ed3bace23c5e17652e174c835fb72bf53ee306b3406a26890221b4cef7500f88"
N = 3
A_r = bitcoin.divide(target, N)# target / N
t_0 = ice.pub2upub(target)
T_1 = ice.point_sequential_increment(1, t_0).hex()
T_2 = ice.to_cpub(T_1)
B_r = bitcoin.divide(T_2, N)#(target + 1) / N
B_0 = ice.pub2upub(A_r)
B_1 = ice.pub2upub(B_r)
B_2 = ice.point_addition(B_0, B_1)
B_3 = B_2.hex()
C_0 = ice.point_subtraction(t_0 , B_2) #target - (A + B)
C_1 = C_0.hex()
C_r = ice.to_cpub(C_1)
A= str(A_r)
B= str(B_r)
C= str(C_r)
print("target:", target+"\n")
print("A:",A)
print("B:",B)
print("C:",C+"\n")