Advertisement
TheRockettek

Untitled

Feb 26th, 2017
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.23 KB | None | 0 0
  1. local chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
  2. characters = {}
  3. for i=1,#chars,1 do
  4. table.insert(characters,string.sub(chars,i,i))
  5. end
  6. crypto = peripheral.find("cryptographic accelerator")
  7. function sha256(data)
  8. hashes = hashes + 1
  9. return crypto.hash("sha-256",data)
  10. end
  11. local function makeaddressbyte(j)
  12. if j <= 6 then return "0"
  13. elseif j <= 13 then return "1"
  14. elseif j <= 20 then return "2"
  15. elseif j <= 27 then return "3"
  16. elseif j <= 34 then return "4"
  17. elseif j <= 41 then return "5"
  18. elseif j <= 48 then return "6"
  19. elseif j <= 55 then return "7"
  20. elseif j <= 62 then return "8"
  21. elseif j <= 69 then return "9"
  22. elseif j <= 76 then return "a"
  23. elseif j <= 83 then return "b"
  24. elseif j <= 90 then return "c"
  25. elseif j <= 97 then return "d"
  26. elseif j <= 104 then return "e"
  27. elseif j <= 111 then return "f"
  28. elseif j <= 118 then return "g"
  29. elseif j <= 125 then return "h"
  30. elseif j <= 132 then return "i"
  31. elseif j <= 139 then return "j"
  32. elseif j <= 146 then return "k"
  33. elseif j <= 153 then return "l"
  34. elseif j <= 160 then return "m"
  35. elseif j <= 167 then return "n"
  36. elseif j <= 174 then return "o"
  37. elseif j <= 181 then return "p"
  38. elseif j <= 188 then return "q"
  39. elseif j <= 195 then return "r"
  40. elseif j <= 202 then return "s"
  41. elseif j <= 209 then return "t"
  42. elseif j <= 216 then return "u"
  43. elseif j <= 223 then return "v"
  44. elseif j <= 230 then return "w"
  45. elseif j <= 237 then return "x"
  46. elseif j <= 244 then return "y"
  47. elseif j <= 251 then return "z"
  48. else return "e"
  49. end
  50. end
  51. function makev2address(password)
  52. local key = sha256("KRISTWALLET" .. password) .. "-000"
  53. local protein = {}
  54. local stick = sha256(sha256(key))
  55. local n = 0
  56. local link = 0
  57. local v2 = "k"
  58. repeat
  59. if n < 9 then protein[n] = string.sub(stick,0,2)
  60. stick = sha256(sha256(stick)) end
  61. n = n + 1
  62. until n == 9
  63. n = 0
  64. repeat
  65. link = tonumber(string.sub(stick,1+(2*n),2+(2*n)),16) % 9
  66. if string.len(protein[link]) ~= 0 then
  67. v2 = v2 .. makeaddressbyte(tonumber(protein[link],16))
  68. protein[link] = ''
  69. n = n + 1
  70. else
  71. stick = sha256(stick)
  72. end
  73. until n == 9
  74. return v2
  75. end
  76. function cycle(t)
  77. for i=1,#characters,1 do
  78. if t == characters[i] then
  79. if i+1>#characters then
  80. return "!"
  81. else
  82. return characters[i+1]
  83. end
  84. end
  85. end
  86. end
  87. function cycletbl(tbl)
  88. tbl[1] = cycle(tbl[1])
  89. for i=1,#tbl,1 do
  90. if tbl[i] == "!" then
  91. tbl[i] = characters[1]
  92. if tbl[i+1] then
  93. tbl[i+1] = cycle(tbl[i+1])
  94. else
  95. tbl[i+1] = characters[1]
  96. end
  97. end
  98. end
  99. return tbl
  100. end
  101.  
  102. chartbl = {"a"}
  103. print("ENTER WANTED ADDRESS:")
  104. addr = io.read()
  105. address = ""
  106. done=0
  107. ttw = os.time()+0.020
  108. hashes = 0
  109. while true do
  110. if os.time() >= ttw then
  111. print(done .. " Addresses/s | " .. hashes .."h/s | " .. table.concat(chartbl,""))
  112. done = 0
  113. hashes = 0
  114. ttw = os.time() + 0.020
  115. sleep(0)
  116. end
  117. chartbl = cycletbl(chartbl)
  118. address = makev2address(table.unpack(chartbl))
  119. done=done+1
  120. if address == addr then
  121. file = fs.open(addr,"a")
  122. file.write(address .. " : " .. table.unpack(chartbl))
  123. end
  124. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement