Skip to content

Commit 8063077

Browse files
update
1 parent f81b5cf commit 8063077

File tree

1 file changed

+83
-0
lines changed

1 file changed

+83
-0
lines changed

main.cpp

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
#include <iostream>
2+
#include "generate.h"
3+
#include "checker.h"
4+
5+
6+
int main(int argc, char** argv)
7+
{
8+
HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
9+
std::string title = "[Seed phrase Generate & Check - BTC; ETH; LTC; DOGE] - By Cosmo11";
10+
SetConsoleTitleA(title.c_str());
11+
12+
DWORD webstatus = 0;
13+
if(!inet::webstatus_check("https://www.blockchain.com/explorer", &webstatus) || webstatus != 200)
14+
{
15+
std::cout << ("Failed to access the blockchain. Check your internet connection\n");
16+
Sleep(6000);
17+
exit(0);
18+
}
19+
20+
srand(static_cast<unsigned int>(time(0)));
21+
DWORD64 seed_count = 0;
22+
float total_balance = 0;
23+
24+
menu:
25+
std::cout << ("select an action:\n'1' - generate 1 seed phrase\n'2' - search for seed phrases with coins(BTC, ETH, LTC, DOGE)\n");
26+
while (true) {
27+
if (GetAsyncKeyState('1') & 1) {
28+
std::cout << "\n\n";
29+
std::string seed = generate_seed_phrase(12);
30+
std::cout << "seed: " << seed << "\n\n";
31+
goto menu;
32+
}
33+
else if (GetAsyncKeyState(('2')) & 1) {
34+
goto brute;
35+
}
36+
Sleep(1);
37+
}
38+
39+
brute:
40+
while (true) {
41+
std::string seed = generate_seed_phrase(12);
42+
std::cout << "seed: " << seed;
43+
44+
balance wallet_balance;
45+
if (check_wallet(seed, &wallet_balance) != 0)
46+
continue;
47+
48+
if (is_empty(wallet_balance)) {
49+
SetConsoleTextAttribute(hConsole, 4);
50+
std::cout << " (empty)";
51+
SetConsoleTextAttribute(hConsole, 7);
52+
}
53+
else {
54+
SetConsoleTextAttribute(hConsole, 2);
55+
std::cout << " (with balance)";
56+
SetConsoleTextAttribute(hConsole, 7);
57+
58+
total_balance += wallet_balance.btc * get_btc_price();
59+
total_balance += wallet_balance.eth * get_eth_price();
60+
total_balance += wallet_balance.doge * get_doge_price();
61+
total_balance += wallet_balance.ltc * get_ltc_price();
62+
63+
std::string found_info = "address: " + get_wallet_address_from_mnemonic(seed) + "\nmnemonic: " + seed + "\nprivate key: " +
64+
get_private_key_from_mnemonic(seed) + "\nbalance: " + std::to_string(wallet_balance.btc) + "BTC " + std::to_string(wallet_balance.eth)
65+
+ "ETH " + std::to_string(wallet_balance.doge) + "DOGE " + std::to_string(wallet_balance.ltc) + "LTC\n\n";
66+
67+
HANDLE hfile = CreateFileA("found_wallets.txt", FILE_ALL_ACCESS, NULL, nullptr, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
68+
WriteFile(hfile, found_info.c_str(), found_info.size(), nullptr, nullptr);
69+
CloseHandle(hfile);
70+
}
71+
72+
std::cout << std::endl;
73+
std::string new_title = title + (" | Checked seeds: ") + std::to_string(seed_count) + (" | Total balance: $") + std::to_string(total_balance);
74+
SetConsoleTitleA(title.c_str());
75+
++seed_count;
76+
77+
if ((seed_count % 10000000) == 0) {
78+
system("cls");
79+
}
80+
}
81+
82+
return 0;
83+
}

0 commit comments

Comments
 (0)