This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3.7 | |
import asyncio | |
import ipaddress | |
import re | |
import sys | |
MAX_NUMBER_WORKERS = 200 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from Crypto.Cipher import AES | |
from sys import argv | |
import os | |
AES_KEY_LEN = 32 # AES-256 GCM | |
AES_NONCE_LEN = 12 # NIST SP800-38D recommends 96 bits | |
AES_HMAC_LEN = 16 # for later | |
FOUR_KiB = 2**10*4 # standard OS block size | |
EXT = '.happyencryption' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hashlib | |
from tkinter import * | |
from tkinter.ttk import * | |
from tkinter.filedialog import askopenfilename | |
# how to use checkbutton: https://stackoverflow.com/questions/4236910/getting-tkinter-check-box-state | |
FOUR_KIBIBYTES = 2**10*4 | |
def compute_hashes(file_path, *hashes): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import queue | |
import asyncio | |
import threading | |
from tkinter import * | |
from tkinter.ttk import * | |
async def receiver(r): | |
while True: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import base64 | |
import hashlib | |
class Scrypt(): | |
@staticmethod | |
def _make_bytes(pw, encoding): | |
if isinstance(pw, str): | |
try: | |
pw = pw.encode(encoding) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sqlite3 | |
import hashlib | |
import base64 | |
from tkinter import * | |
from cryptography.fernet import Fernet | |
DB_FILE_NAME = 'my.db' | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ItemToPurchase: | |
def __init__(self, item_name, item_description, item_price, item_quantity): | |
self.item_name = item_name | |
self.item_description = item_description | |
self.item_price = float(item_price) | |
self.item_quantity = float(item_quantity) | |
def print_item_cost(self): | |
totalCost = self.item_quantity * self.item_price | |
print('%s %d @ $%d = $%d' % (self.item_name, self.item_quantity, self.item_price, totalCost)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!python3 | |
# coding: utf-8 | |
import hashlib | |
import threading | |
from tkinter import * | |
from tkinter.ttk import * | |
from tkinter import messagebox | |
from tkinter.scrolledtext import ScrolledText |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# coding: ascii | |
import os | |
import sys | |
import gzip | |
import base64 | |
import getpass | |
import threading |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urllib | |
from dataclasses import dataclass | |
from tkinter import * | |
from tkinter.ttk import * | |
import requests |
OlderNewer