0% found this document useful (0 votes)
8 views3 pages

Message

Uploaded by

bdhhdrydhd
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)
8 views3 pages

Message

Uploaded by

bdhhdrydhd
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/ 3

import socket as s

import pickle
from time import sleep
import os

class ConnectionToServer:
def __init__(self, server_ip, port):
self.HEADER = 8
self.HOST = server_ip
self.PORT = port
self.Connection_complete = False
self.client = s.socket(s.AF_INET, s.SOCK_STREAM)

def connect(self):
try:
self.client.connect((self.HOST, self.PORT))
print("Connect complete")
self.Connection_complete = True
except:
print("Connection failed")
print("Connection...")

class SendData:
def send(self, client, data):
encoded_data = pickle.dumps(data)
client.sendall(encoded_data)

class RecvData:
def recv(self, client):
data = client.recv(4096)
decoded_data = pickle.loads(data)

return decoded_data

class UserMenu:
def __init__(self):
self.mode = None
self.uses = None

def hash_only_mode(self, client, send_data, recv_data):


print(f"Your use left {self.uses}")

if self.uses > 0:
input_hash = input("Enter hash to decode: ")
send_data.send(client, input_hash)
decode_hash = recv_data.recv(client)
if decode_hash == None:
print("can not decode this hash")
else:
print(decode_hash)

print("Press any key to next decode")


sleep(2)
input()
os.system('cls')

else:
print("You have 0 use")
print("Press any key to close")
input()
os.system('cls')

def full_access_mode(self, client, send_data, recv_data):


print(f"Your use left {self.uses}")

if self.uses > 0:
user_input = input("enter nick to find or hashes to decode: ")

if len(user_input) > 25:


user_action = "hash_decode"
else:
user_action = "find_account"

send_data.send(client, [user_action, user_input])

if user_action == "hash_decode":
decode_hash = recv_data.recv(client)

if decode_hash == None:
print("can not decode this hash")
sleep(0.5)
os.system('cls')
else:
os.system('cls')
print(decode_hash)

print()
print("Press any key to next decode")
sleep(2)
input()
os.system('cls')

elif user_action == "find_account":


decode_hash = recv_data.recv(client)

if decode_hash == None:
print("can not find this account")
sleep(0.5)
os.system('cls')
else:
os.system('cls')
print(decode_hash)

print()
if decode_hash != "Nieznaleziono takiego nicku" and "Premium
account: False" in decode_hash:
print("Press any key to next find")

input()
else:
sleep(0.5)
os.system('cls')

else:
print("You have 0 use")
print("Press any key to close")
input()
os.system('cls')
def main(server_ip="192.168.0.100", port=5050):
connection = ConnectionToServer(server_ip, port)
send_data = SendData()
recv_data = RecvData()
user_menu = UserMenu()

loggined = False

client = connection.client
connection.connect()

if connection.Connection_complete:
while not loggined:
#licnes = input("Enter your licnes: ")
licnes = "lic"
send_data.send(client, licnes)
print("Checking your licnes...")
response = recv_data.recv(client)
print(f"{response[0]} mode: {response[1]}")
sleep(1)
os.system('cls')

if response[1] != None:
loggined = True

if response[1] != None:
user_menu.mode = response[1]

while loggined:
user_menu.uses = recv_data.recv(client)

if user_menu.mode == "hash_only":
user_menu.hash_only_mode(client, send_data, recv_data)

elif user_menu.mode == "full_access":


user_menu.full_access_mode(client, send_data, recv_data)

else:
connection.connect()

if __name__ == '__main__':
main()

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy