Updated client/client.py
This commit is contained in:
parent
2ffd0443ce
commit
776ca81577
|
|
@ -82,7 +82,6 @@ class Client:
|
|||
def _key_request(self) -> None:
|
||||
with open('private.pem', 'rb') as f:
|
||||
self.privkey = rsa.PrivateKey.load_pkcs1(f.read())
|
||||
|
||||
with open("public.pem", 'rb') as f:
|
||||
with requests.get(self.key_url, data={"pubkey": f.read(), "username": self.username}, stream=True) as r:
|
||||
message = r.raw.read(999)
|
||||
|
|
@ -103,6 +102,9 @@ class Client:
|
|||
|
||||
|
||||
def __call__(self):
|
||||
# Running two threads,
|
||||
# One for sending info
|
||||
# Second one for updating info
|
||||
self._validate_keys()
|
||||
threads = [
|
||||
threading.Thread(target=self.send_info),
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user