SYMBOL INDEX (656 symbols across 129 files) FILE: 2019/Affinity/GolanG_Heights/golang_heights.go type privateKeys (line 8) | type privateKeys struct function isPrime (line 13) | func isPrime(num *big.Int) bool { function getKeys (line 24) | func getKeys() (privateKeys, *big.Int, error) { function encrypt (line 45) | func encrypt(message *big.Int, publicKey *big.Int) *big.Int { function main (line 51) | func main() { FILE: 2019/Affinity/GolanG_Heights/modular_sqrt.py function modular_sqrt (line 1) | def modular_sqrt(a, p): function legendre_symbol (line 80) | def legendre_symbol(a, p): FILE: 2019/CSAW/Fault_Box/local.py function wline (line 11) | def wline(msg=''): function rline (line 16) | def rline(msg=None): function s2n (line 22) | def s2n(s): function n2s (line 26) | def n2s(n): function gen_prime (line 30) | def gen_prime(): class RSA (line 42) | class RSA(object): method __init__ (line 43) | def __init__(self): method generate (line 46) | def generate(self, p, q, e=0x10001): method encrypt (line 54) | def encrypt(self, p): method decrypt (line 57) | def decrypt(self, c): method TEST_CRT_encrypt (line 61) | def TEST_CRT_encrypt(self, p, fun=0): method TEST_CRT_decrypt (line 71) | def TEST_CRT_decrypt(self, c, fun=0): function go (line 82) | def go(): class incoming (line 135) | class incoming(): method handle (line 136) | def handle(self): FILE: 2019/CSAW/Fault_Box/server.py function s2n (line 11) | def s2n(s): function n2s (line 15) | def n2s(n): function gen_prime (line 19) | def gen_prime(): class RSA (line 31) | class RSA(object): method __init__ (line 32) | def __init__(self): method generate (line 35) | def generate(self, p, q, e=0x10001): method encrypt (line 43) | def encrypt(self, p): method decrypt (line 46) | def decrypt(self, c): method TEST_CRT_encrypt (line 50) | def TEST_CRT_encrypt(self, p, fun=0): method TEST_CRT_decrypt (line 60) | def TEST_CRT_decrypt(self, c, fun=0): function go (line 71) | def go(req): class incoming (line 124) | class incoming(socketserver.BaseRequestHandler): method handle (line 125) | def handle(self): class ReusableTCPServer (line 134) | class ReusableTCPServer(socketserver.ForkingMixIn, socketserver.TCPServer): FILE: 2019/CSAW/Fault_Box/solve.py function s2n (line 22) | def s2n(s): function n2s (line 26) | def n2s(n): function recvmenu (line 30) | def recvmenu(): function enc_msg (line 34) | def enc_msg(msg): function enc_flag (line 43) | def enc_flag(): function enc_fake_flag (line 50) | def enc_fake_flag(): function enc_fake_flag_TEST (line 57) | def enc_fake_flag_TEST(): FILE: 2019/CSAW/SuperCurve/server.py function main (line 6) | def main(): FILE: 2019/CSAW/SuperCurve/supercurve.py class SuperCurve (line 10) | class SuperCurve: method __init__ (line 12) | def __init__(self, field, order, a, b, g): method __str__ (line 27) | def __str__(self): method is_on_curve (line 30) | def is_on_curve(self, point): method add (line 37) | def add(self, p1, p2): method double (line 63) | def double(self, p): method neg (line 66) | def neg(self, p): method mult (line 75) | def mult(self, scal, point): method inv_mod (line 93) | def inv_mod(n, p): FILE: 2019/CSAW/count_on_me/chal.py function xor (line 9) | def xor(x, y): function random_bytes (line 13) | def random_bytes(): function encrypt (line 17) | def encrypt(aes, msg): function send_enc (line 26) | def send_enc(req, aes, msg): function recv_exact (line 30) | def recv_exact(req, length): function recv_msg (line 41) | def recv_msg(req): function recv_seed (line 45) | def recv_seed(req): function main (line 54) | def main(req): class TaskHandler (line 71) | class TaskHandler(socketserver.BaseRequestHandler): method handle (line 72) | def handle(self): FILE: 2019/CSAW/count_on_me/local.py function wline (line 12) | def wline(msg=''): function rline (line 17) | def rline(msg=None): function xor (line 23) | def xor(x, y): function random_bytes (line 27) | def random_bytes(): function encrypt (line 31) | def encrypt(aes, msg): function send_enc (line 40) | def send_enc(aes, msg): function recv_exact (line 44) | def recv_exact(length): function recv_msg (line 50) | def recv_msg(): function recv_seed (line 54) | def recv_seed(): function main (line 63) | def main(): FILE: 2019/CSAW/count_on_me/solve.py function random_bytes (line 10) | def random_bytes(): function findseed (line 14) | def findseed(seed): function getflag (line 34) | def getflag(seed): FILE: 2019/CryptoCTF/Clever_Girl/modular_sqrt.py function modular_sqrt (line 1) | def modular_sqrt(a, p): function legendre_symbol (line 80) | def legendre_symbol(a, p): FILE: 2019/CryptoCTF/Fast_Speedy!/long_fast_speedy.py function drift (line 6) | def drift(R, B): FILE: 2019/CryptoCTF/Fast_Speedy!/solve.py function drift (line 17) | def drift(R, s): function findstate (line 25) | def findstate(out): FILE: 2019/CryptoCTF/Time_Capsule/time_capsule.py function encrypt_time_capsule (line 8) | def encrypt_time_capsule(msg, n, t, z): FILE: 2019/CryptoCTF/roXen/roXen.py function adlit (line 8) | def adlit(x): function genadlit (line 12) | def genadlit(nbit): FILE: 2019/DEFCON/tania/solve.py function sign (line 22) | def sign(cmd): function execute (line 35) | def execute(key, cmd): class myrand (line 54) | class myrand(object): method __init__ (line 55) | def __init__(self): method rand (line 61) | def rand(self): method set_value (line 67) | def set_value(self, k): function gen_sign (line 71) | def gen_sign(m, x, k): function main (line 81) | def main(): FILE: 2019/Facebook/netscream/crypt.py function ige_encrypt (line 7) | def ige_encrypt(message, key, iv): function ige_decrypt (line 11) | def ige_decrypt(message, key, iv): function _ige (line 15) | def _ige(message, key, iv, operation="decrypt"): FILE: 2019/Facebook/postquantumsig/solve.py function forge (line 15) | def forge(msg, weird_addr): function main (line 34) | def main(): FILE: 2019/Facebook/postquantumsig/verifier.py function s256 (line 6) | def s256(msg): function kth_bit (line 14) | def kth_bit(n, k): function group_by_n (line 20) | def group_by_n(s, n=2): function bit_stream_from_msg (line 26) | def bit_stream_from_msg(msg): function make_top_hash_from_leaves (line 34) | def make_top_hash_from_leaves(tree): function make_top_hash_from_others (line 44) | def make_top_hash_from_others(initial, others): function msg_to_hashes (line 55) | def msg_to_hashes(msg, signature): function parse_signed_message (line 70) | def parse_signed_message(msg_w_signature): function msg_internal_validity (line 80) | def msg_internal_validity(msg, identity): function verify_signed_message (line 92) | def verify_signed_message(msg_w_signature): function read_records (line 100) | def read_records(filename): function main (line 112) | def main(): FILE: 2019/Facebook/storagespace/solve.py function genjson (line 13) | def genjson(command, args=None, sig=None): function request (line 27) | def request(req): function getsign (line 34) | def getsign(out): function main (line 40) | def main(): FILE: 2019/HITCON/Lost_Modulus_Again/prob.py class Key (line 4) | class Key: method __init__ (line 5) | def __init__(self, bits): method encrypt (line 17) | def encrypt(self, data): method decrypt (line 22) | def decrypt(self, data): method __str__ (line 29) | def __str__(self): function main (line 32) | def main(): FILE: 2019/HITCON/Lost_Modulus_Again/prob/prob.py class Key (line 4) | class Key: method __init__ (line 5) | def __init__(self, bits): method encrypt (line 17) | def encrypt(self, data): method decrypt (line 22) | def decrypt(self, data): method __str__ (line 29) | def __str__(self): function main (line 32) | def main(): FILE: 2019/HITCON/Lost_Modulus_Again/solve.py function solve (line 9) | def solve(a, b, c): FILE: 2019/HITCON/Very_Simple_Haskell/solve.py function encode (line 9) | def encode(m): function form (line 32) | def form(flag): function calc (line 36) | def calc(num, arr): function calc2 (line 50) | def calc2(num, arr): function encrypt (line 61) | def encrypt(finalBits): function decrypt (line 66) | def decrypt(cipher): FILE: 2019/HackCon/AgainAndAgainAndAgain/modular_sqrt.py function modular_sqrt (line 1) | def modular_sqrt(a, p): function legendre_symbol (line 83) | def legendre_symbol(a, p): FILE: 2019/HackCon/AgainAndAgainAndAgain/q1.py function encrypt (line 1) | def encrypt(m): FILE: 2019/HackCon/AgainAndAgainAndAgain/solve.py function egcd (line 12) | def egcd(a, b): function check (line 20) | def check(m): function dec (line 24) | def dec(t): FILE: 2019/Harekaze/Now_We_Can_Play/problem.py function genKey (line 6) | def genKey(k): function encrypt (line 14) | def encrypt(m, pk): function decrypt (line 22) | def decrypt(c1, c2, pk, sk): function challenge (line 28) | def challenge(): FILE: 2019/Harekaze/Now_We_Can_Play/solve.py function decrypt (line 7) | def decrypt(conn, c1, c2): FILE: 2019/Harekaze/ONCE_UPON_A_TIME/problem.py function pad25 (line 11) | def pad25(s): function kinoko (line 16) | def kinoko(text): function takenoko (line 31) | def takenoko(X, Y): function encrypt (line 42) | def encrypt(m1, m2): FILE: 2019/ISITDTU/Chaos/solve.py function encrypt (line 8) | def encrypt(msg): function main (line 18) | def main(): FILE: 2019/ISITDTU/Easy_RSA_2/solve.py function fermat_factorization (line 6) | def fermat_factorization(n): function main (line 30) | def main(): FILE: 2019/ISITDTU/balls/solve.py function decide (line 8) | def decide(): function trial (line 18) | def trial(): FILE: 2019/ISITDTU/decrypt_to_me/solve.py function generate_prg_bit (line 6) | def generate_prg_bit(n): FILE: 2019/ISITDTU/decrypt_to_me/task.py function generate_prg_bit (line 2) | def generate_prg_bit(n): FILE: 2019/KAPO/Weak-Strong/weak_strong.py function get_weak_prime (line 8) | def get_weak_prime(): function get_strong_prime (line 17) | def get_strong_prime(): function generate_weak (line 26) | def generate_weak(): function generate_strong (line 32) | def generate_strong(): FILE: 2019/Rooters/Digene/solve.py function get_key (line 15) | def get_key(password): FILE: 2019/X-MAS/christmas_pockets/prob.py class pockets (line 6) | class pockets: method __init__ (line 7) | def __init__(self): method gen_key (line 9) | def gen_key(self): method encrypt (line 25) | def encrypt(self,msg): method decrypt (line 39) | def decrypt(self,enc): FILE: 2019/X-MAS/hide_and_seek/hide_and_seek.py class chall (line 9) | class chall: method __init__ (line 10) | def __init__(self, p, guess): method msb (line 16) | def msb(self,query): method next (line 22) | def next(self): FILE: 2020/CCE/we_can_meet_in_the_park/prob.py function Check (line 8) | def Check(buf, ml, cl): function main (line 28) | def main(): FILE: 2020/CryptoCTF/Amsterdam/amsterdam.py function comb (line 8) | def comb(n, k): function encrypt (line 16) | def encrypt(msg, n, k): FILE: 2020/CryptoCTF/Complex_to_Hell/complex_to_hell.py function multiply (line 10) | def multiply(A ,B): function comple_congruent (line 27) | def comple_congruent (z): function plain_to_matrix (line 32) | def plain_to_matrix(msg ,n): function encrypt (line 54) | def encrypt(flag ,key): FILE: 2020/CryptoCTF/Complex_to_Hell/solve.py function plain_to_matrix (line 14) | def plain_to_matrix(msg, n): function multiply (line 36) | def multiply(A, B): function matrix_to_plain (line 53) | def matrix_to_plain(mat, n): function comple_congruent (line 64) | def comple_congruent(z): FILE: 2020/CryptoCTF/Fatima/fatima.py function multiply (line 10) | def multiply(A, B): function pow_matrix (line 26) | def pow_matrix(A, n): function circulant (line 32) | def circulant(v): function spiral (line 42) | def spiral(A): function revspiral (line 73) | def revspiral(A): function sinwaveform (line 84) | def sinwaveform(A): function helical (line 103) | def helical(A): function revhelical (line 142) | def revhelical(A): function c2p (line 161) | def c2p(c, G): function aux (line 165) | def aux(msg, G): function enmat (line 171) | def enmat(c, l): function encrypt (line 175) | def encrypt(msg): FILE: 2020/CryptoCTF/Fatima/solve.py function c2p (line 16) | def c2p(c): function p2c (line 21) | def p2c(C): function multiply (line 35) | def multiply(A, B): function circulant (line 52) | def circulant(v): function spiral (line 63) | def spiral(A): function spiral_rev (line 95) | def spiral_rev(A): function revspiral (line 128) | def revspiral(A): function revspiral_rev (line 140) | def revspiral_rev(A): function helical (line 150) | def helical(A): function helical_rev (line 190) | def helical_rev(A): function revhelical (line 234) | def revhelical(A): function revhelical_rev (line 246) | def revhelical_rev(A): function sinwaveform (line 257) | def sinwaveform(A): function sinwaveform_rev (line 277) | def sinwaveform_rev(A): function aux (line 296) | def aux(msg): function aux_rev (line 304) | def aux_rev(enc): function pprint (line 311) | def pprint(A): function enmat (line 325) | def enmat(c, l=3): function decmat (line 330) | def decmat(enc): function rot (line 338) | def rot(n, i): FILE: 2020/CryptoCTF/Gambler/solve.py function PoW (line 9) | def PoW(): function recvmenu (line 24) | def recvmenu(): function encrypt (line 28) | def encrypt(m): function getflag (line 38) | def getflag(): function enclogic (line 45) | def enclogic(): FILE: 2020/CryptoCTF/Three_Ravens/three_ravens.py function keygen (line 6) | def keygen(nbit): function encrypt (line 14) | def encrypt(msg, pubkey): FILE: 2020/DEFCON/coooppersmith/genPrime.py function genPrime (line 6) | def genPrime(seed): FILE: 2020/DEFCON/coooppersmith/solve.py class RandomWrapper (line 10) | class RandomWrapper(): method __init__ (line 12) | def __init__(self, delta, seed=None): method Random (line 22) | def Random(self): FILE: 2020/DEFCON/ooobash/solve.py function shell (line 9) | def shell(cmd): function check (line 13) | def check(num): function checklock (line 21) | def checklock(): function lock0 (line 33) | def lock0(): function lock1 (line 38) | def lock1(): function lock2 (line 44) | def lock2(): function lock3 (line 49) | def lock3(): function lock4 (line 54) | def lock4(): function lock5 (line 60) | def lock5(): function lock6 (line 67) | def lock6(): function lock7 (line 72) | def lock7(): function lock8 (line 77) | def lock8(): function lock9 (line 82) | def lock9(): function lock10 (line 88) | def lock10(): function lock11 (line 93) | def lock11(): function lock12 (line 98) | def lock12(): function unlock (line 104) | def unlock(): FILE: 2020/Defenit/Dodge/solve.py function PoW (line 14) | def PoW(): function recvMap (line 26) | def recvMap(): function printMap (line 36) | def printMap(Map): class Solver (line 43) | class Solver: method __init__ (line 44) | def __init__(self, GAMENUM): method roundUpdate (line 49) | def roundUpdate(self): function findPos (line 68) | def findPos(Map): function updatePos (line 79) | def updatePos(pos, speed): class Bullet (line 106) | class Bullet: method __init__ (line 107) | def __init__(self, pos, speed): method update (line 115) | def update(self): class Player (line 130) | class Player(Bullet): method __init__ (line 132) | def __init__(self, pos, speed): method updatespeed (line 148) | def updatespeed(self, direction): function bulletUpdate (line 155) | def bulletUpdate(bulletList): function playerUpdate (line 159) | def playerUpdate(): function playerPosCheck (line 166) | def playerPosCheck(idx, estimate, truth): function decide (line 176) | def decide(focus, swap=False): FILE: 2020/Defenit/Minesweeper/mines.py class exception (line 48) | class exception(Exception): class UnsolveableException (line 51) | class UnsolveableException(exception): function choose (line 56) | def choose(n, k): class Promise (line 82) | class Promise(object): method __init__ (line 83) | def __init__(self, queue): method set (line 90) | def set(self, value): method get (line 95) | def get(self): class TaskQueue (line 104) | class TaskQueue(object): method __init__ (line 105) | def __init__(self, number_of_threads): method run_task (line 114) | def run_task(self, task): method run_one (line 121) | def run_one(self, block=True): method run_forever (line 129) | def run_forever(self): method add_task (line 133) | def add_task(self, f, args=(), kwargs={}, block=True): class DummyTaskQueue (line 139) | class DummyTaskQueue(TaskQueue): method add_task (line 140) | def add_task(self, f, args=(), kwargs={}, block=True): class Solver (line 152) | class Solver(object): method __init__ (line 153) | def __init__(self, spaces): method add_information (line 161) | def add_information(self, information): method remove_information (line 173) | def remove_information(self, information): method add_known_value (line 178) | def add_known_value(self, space, value): method copy (line 181) | def copy(self): method get_clusters (line 190) | def get_clusters(self): method get_cluster_probabilities (line 212) | def get_cluster_probabilities(cluster): method get_probabilities (line 273) | def get_probabilities(self): method get_cluster_possibility (line 293) | def get_cluster_possibility(cluster, rand): method get_possibility (line 356) | def get_possibility(self, rand=None): method solver_from_cluster (line 372) | def solver_from_cluster(cluster): method check_state (line 385) | def check_state(solver, states_to_validate): method solve_cluster (line 449) | def solve_cluster(self, cluster): method solve_np (line 479) | def solve_np(self): method solve (line 502) | def solve(self, np=True): function picma_main (line 573) | def picma_main(width, height): function mines_main (line 603) | def mines_main(width, height, total, Map): class MineMap (line 660) | class MineMap(object): method __init__ (line 661) | def __init__(self, spaces): method __getitem__ (line 664) | def __getitem__(self, key): method __setitem__ (line 667) | def __setitem__(self, key, value): method get_bordering_spaces (line 670) | def get_bordering_spaces(self, space): method randomize_p (line 673) | def randomize_p(self, random, p=0.5): method randomize_count (line 677) | def randomize_count(self, random, count): class RectMap (line 686) | class RectMap(MineMap): method __init__ (line 687) | def __init__(self, width, height): method __getitem__ (line 699) | def __getitem__(self, key): method __setitem__ (line 703) | def __setitem__(self, key, value): method get_bordering_spaces (line 707) | def get_bordering_spaces(self, space): class PicmaPuzzle (line 715) | class PicmaPuzzle(object): method __init__ (line 716) | def __init__(self, minemap): method create_solver (line 720) | def create_solver(self): method make_solveable (line 726) | def make_solveable(self, random): method trim (line 752) | def trim(self): function picmagen (line 761) | def picmagen(rectmap, random): function picmagen_main (line 783) | def picmagen_main(width, height): function picmapregen_main (line 792) | def picmapregen_main(width, height): FILE: 2020/Defenit/Minesweeper/solve.py function readMap (line 15) | def readMap(done=False): function printMap (line 28) | def printMap(Map): function decide (line 36) | def decide(Map, UpdatedMap): FILE: 2020/HackIM/SecureLinearFunctionEvaluation/lfe.py function cal_res (line 10) | def cal_res(a, b, cs, otinp): function main (line 29) | def main(): FILE: 2020/HackIM/SecureLinearFunctionEvaluation/solve.py function genotinp (line 22) | def genotinp(cs): FILE: 2020/KAPO/0ero_Trust_Login/solve.py function calc_session_key (line 33) | def calc_session_key(key, iv, data): function get_command (line 50) | def get_command(session_key, data): FILE: 2020/KAPO/fixed_point_revenge/chall.py function crc64 (line 4) | def crc64(x): function f (line 29) | def f(s): function g (line 35) | def g(t, s): function xor (line 38) | def xor(a, b): FILE: 2020/NahamCon/Awkward/solve.py function execute (line 10) | def execute(payload): FILE: 2020/NahamCon/Homecooked/decrypt.py function a (line 8) | def a(num): function b (line 18) | def b(num): FILE: 2020/NahamCon/Homecooked/solve.py function genlist (line 5) | def genlist(start, l): FILE: 2020/PlaidCTF/dyrpto/generate_problem.py function get_padding (line 14) | def get_padding(): function bytes_to_int (line 18) | def bytes_to_int(message): function int_to_bytes (line 21) | def int_to_bytes(message): function pad (line 27) | def pad(mi): function unpad (line 30) | def unpad(mi): function encrypt (line 33) | def encrypt(message): function decrypt (line 37) | def decrypt(ciphertext): FILE: 2020/PlaidCTF/dyrpto/generate_problem_modified.py function get_padding (line 15) | def get_padding(): function bytes_to_int (line 19) | def bytes_to_int(message): function int_to_bytes (line 22) | def int_to_bytes(message): function pad (line 28) | def pad(mi): function unpad (line 31) | def unpad(mi): function encrypt (line 34) | def encrypt(message): function decrypt (line 38) | def decrypt(ciphertext): function randstr (line 47) | def randstr(n): FILE: 2020/Pragyan/AskTheOracle/solve.py function form (line 12) | def form(ct, iv): function listxor (line 17) | def listxor(l1, l2): function leak (line 21) | def leak(): FILE: 2020/Pragyan/Htide/solve.py function authorize (line 8) | def authorize(key): function leak (line 22) | def leak(additional): function main (line 38) | def main(): FILE: 2020/Pwn2Win/Androids_Encryption/server.py function to_blocks (line 10) | def to_blocks(txt): function xor (line 14) | def xor(b1, b2=None): function encrypt (line 32) | def encrypt(txt, key, iv): function enc_plaintext (line 50) | def enc_plaintext(): function enc_flag (line 56) | def enc_flag(): function menu (line 60) | def menu(): function main (line 75) | def main(): FILE: 2020/Pwn2Win/Androids_Encryption/server_local.py function to_blocks (line 15) | def to_blocks(txt): function xor (line 19) | def xor(b1, b2=None): function encrypt (line 36) | def encrypt(txt, key, iv): function enc_plaintext (line 54) | def enc_plaintext(): function enc_flag (line 60) | def enc_flag(): function menu (line 64) | def menu(): function main (line 79) | def main(): FILE: 2020/Pwn2Win/Androids_Encryption/solve.py function to_blocks (line 23) | def to_blocks(txt): function xor (line 27) | def xor(b1, b2=None): function encrypt_your_secret (line 40) | def encrypt_your_secret(pt): function encrypt_my_secret (line 51) | def encrypt_my_secret(): FILE: 2020/Pwn2Win/Omni_Crypto/enc.py function getPrimes (line 5) | def getPrimes(size): FILE: 2020/Pwn2Win/Omni_Crypto/enc_modified.py function getPrimes (line 5) | def getPrimes(size): FILE: 2020/SSTF/Baby_ROCA/BabyROCA.py function GenROCAPrime (line 6) | def GenROCAPrime(): FILE: 2020/SSTF/Decrypt_Vulnerable_Data_#1/challenge.py class LFSR (line 4) | class LFSR: method __init__ (line 5) | def __init__(self, size, salt, invert): method clock (line 13) | def clock(self): function encryptData (line 20) | def encryptData(key, data): function decryptData (line 37) | def decryptData(key, ct): FILE: 2020/SSTF/Decrypt_Vulnerable_Data_#2/challenge.py function shuffle (line 19) | def shuffle(C, k, perm): class LFSR (line 40) | class LFSR: method __init__ (line 41) | def __init__(self, size, salt, invert): method clock (line 49) | def clock(self): function int_to_bytes (line 57) | def int_to_bytes(n): function bytes_to_int (line 62) | def bytes_to_int(a): function encryptKey (line 70) | def encryptKey(key): function encryptData (line 92) | def encryptData(key, data): FILE: 2020/SSTF/RC_four/challenge.py function encrypt (line 6) | def encrypt(data): FILE: 2020/TAMUctf/BLIND/solve.py function execute (line 10) | def execute(payload): FILE: 2020/TAMUctf/ETERNAL_GAME/game.py function gen_hash (line 11) | def gen_hash(x): function extract_int (line 16) | def extract_int(s): function multiply (line 25) | def multiply(): function print_value (line 40) | def print_value(): function get_proof (line 44) | def get_proof(): function play_game (line 51) | def play_game(): function prize (line 77) | def prize(): function new (line 107) | def new(): function main_menu (line 117) | def main_menu(): FILE: 2020/TAMUctf/ETERNAL_GAME/solve.py function extract_int (line 28) | def extract_int(s): function get_hash (line 38) | def get_hash(): function prize (line 46) | def prize(num, proof): FILE: 2020/TAMUctf/PASSWORD_EXTRACTION/solve.py function request (line 22) | def request(username, password=''): function binarysearch (line 28) | def binarysearch(pos): function leak (line 46) | def leak(payload): FILE: 2020/WhiteHat_GrandPrix/Cryptography_01/solve.py function enc (line 14) | def enc(msg): function genlist (line 22) | def genlist(chset, start=None, end=None): FILE: 2020/h4c/14461009_but_its_harder/hangulcipher.py function hangul_to_seq (line 44) | def hangul_to_seq(x): function encrypt (line 53) | def encrypt(plain,key): FILE: 2020/h4c/14461009_but_its_harder/solve.py function hangul_to_seq (line 45) | def hangul_to_seq(x): function seq_to_hangul (line 55) | def seq_to_hangul(x): function encrypt (line 67) | def encrypt(plain, key): function decrypt (line 71) | def decrypt(ciphertext, key): FILE: 2020/h4c/OldTextbook/main.py function is_prime (line 4) | def is_prime(p,hardness=1000): function generate_pub_key (line 11) | def generate_pub_key(bits): function main (line 21) | def main(): FILE: 2020/zer0pts/dirty_laundry/chall.py class PRNG256 (line 7) | class PRNG256(object): method __init__ (line 8) | def __init__(self, seed): method _pick (line 12) | def _pick(self): method rand (line 17) | def rand(self): function paillier_enc (line 26) | def paillier_enc(m, p, noise): function make_shares (line 36) | def make_shares(secret, k, shares, prime=PRIME): FILE: 2020/zer0pts/dirty_laundry/solve.py class PRNG256 (line 8) | class PRNG256(object): method __init__ (line 9) | def __init__(self, seed): method _pick (line 13) | def _pick(self): method rand (line 18) | def rand(self): FILE: 2020/zer0pts/diysig/solve.py function init (line 17) | def init(opt): function recvhex (line 26) | def recvhex(p): function disclose (line 30) | def disclose(): function encsig (line 40) | def encsig(msg): function verify (line 50) | def verify(enc, sig): FILE: 2020/zer0pts/diysig/src/diysig.py class DIYSig (line 3) | class DIYSig(object): method __init__ (line 7) | def __init__(self): method encsig (line 13) | def encsig(self, m): method getsig (line 19) | def getsig(self, c): method _hash (line 25) | def _hash(self, m): method pubkey (line 42) | def pubkey(self): FILE: 2020/zer0pts/diysig/src/server.py class DIYSigHandler (line 5) | class DIYSigHandler(socketserver.BaseRequestHandler, object): method recvline (line 6) | def recvline(self): method menu (line 16) | def menu(self): method encsig (line 29) | def encsig(self): method verify (line 52) | def verify(self): method disclose (line 80) | def disclose(self): method handle (line 90) | def handle(self): class DIYSigServer (line 102) | class DIYSigServer(socketserver.ThreadingTCPServer, object): method server_bind (line 103) | def server_bind(self): FILE: 2021/CryptoCTF/Triplet/Triplet.py function die (line 8) | def die(*args): function pr (line 12) | def pr(*args): function sc (line 17) | def sc(): function main (line 20) | def main(): FILE: 2021/CryptoCTF/hyper_normal/hyper_normal.py function transpose (line 8) | def transpose(x): function vsum (line 12) | def vsum(u, v): function sprod (line 19) | def sprod(a, u): function encrypt (line 25) | def encrypt(msg): FILE: 2021/InCTF/Trouble_With_Pairs/BLS.py function hash_to_G2 (line 49) | def hash_to_G2(msg, DST, hash): class BaseG2Ciphersuite (line 54) | class BaseG2Ciphersuite(abc.ABC): method _is_valid_privkey (line 62) | def _is_valid_privkey(privkey: int) -> bool: method _is_valid_pubkey (line 66) | def _is_valid_pubkey(pubkey: bytes) -> bool: method _is_valid_message (line 71) | def _is_valid_message(message: bytes) -> bool: method _is_valid_signature (line 75) | def _is_valid_signature(signature: bytes) -> bool: method SkToPk (line 83) | def SkToPk(cls, privkey: int) -> BLSPubkey: method KeyGen (line 99) | def KeyGen(cls, IKM: bytes, key_info: bytes = b'') -> int: method KeyValidate (line 111) | def KeyValidate(PK: BLSPubkey) -> bool: method _CoreSign (line 126) | def _CoreSign(cls, SK: int, message: bytes, DST: bytes) -> BLSSignature: method _CoreVerify (line 145) | def _CoreVerify(cls, PK: BLSPubkey, message: bytes, method Aggregate (line 174) | def Aggregate(cls, signatures: Sequence[BLSSignature]) -> BLSSignature: method _CoreAggregateVerify (line 197) | def _CoreAggregateVerify(cls, PKs: Sequence[BLSPubkey], messages: Sequ... method Sign (line 230) | def Sign(cls, SK: int, message: bytes) -> BLSSignature: method Verify (line 234) | def Verify(cls, PK: BLSPubkey, message: bytes, signature: BLSSignature... method AggregateVerify (line 238) | def AggregateVerify(cls, PKs: Sequence[BLSPubkey], class G2Basic (line 243) | class G2Basic(BaseG2Ciphersuite): method AggregateVerify (line 247) | def AggregateVerify(cls, PKs: Sequence[BLSPubkey], class G2MessageAugmentation (line 254) | class G2MessageAugmentation(BaseG2Ciphersuite): method Sign (line 258) | def Sign(cls, SK: int, message: bytes) -> BLSSignature: method Verify (line 263) | def Verify(cls, PK: BLSPubkey, message: bytes, signature: BLSSignature... method AggregateVerify (line 267) | def AggregateVerify(cls, PKs: Sequence[BLSPubkey], class G2ProofOfPossession (line 275) | class G2ProofOfPossession(BaseG2Ciphersuite): method _is_valid_pubkey (line 280) | def _is_valid_pubkey(cls, pubkey: bytes) -> bool: method AggregateVerify (line 292) | def AggregateVerify(cls, PKs: Sequence[BLSPubkey], method PopProve (line 297) | def PopProve(cls, SK: int) -> BLSSignature: method PopVerify (line 302) | def PopVerify(cls, PK: BLSPubkey, proof: BLSSignature) -> bool: method _AggregatePKs (line 306) | def _AggregatePKs(PKs: Sequence[BLSPubkey]) -> BLSPubkey: method FastAggregateVerify (line 323) | def FastAggregateVerify(cls, PKs: Sequence[BLSPubkey], FILE: 2021/InCTF/Trouble_With_Pairs/server.py class Unbuffered (line 8) | class Unbuffered(object): method __init__ (line 9) | def __init__(self, stream): method write (line 12) | def write(self, data): method writelines (line 16) | def writelines(self, datas): method __getattr__ (line 20) | def __getattr__(self, attr): class Challenge (line 36) | class Challenge(): method __init__ (line 37) | def __init__(self): method Read (line 44) | def Read(self, inp): method Verify_aggregate (line 60) | def Verify_aggregate(self): method Verify_individual (line 73) | def Verify_individual(self): method Get_Majority (line 81) | def Get_Majority(self): FILE: 2021/InCTF/Trouble_With_Pairs/solve.py function hash (line 29) | def hash(msg, hash): function forgery (line 34) | def forgery(prev_sign_raw): function get_flag (line 42) | def get_flag(get_fake_flag=False): FILE: 2022/CODEGATE/Final/Look_It_Up/solve.py function transact (line 22) | def transact(bytecode): function H (line 39) | def H(data: bytes) -> int: function isPowerOf2 (line 43) | def isPowerOf2(n: int) -> bool: function sanity_check (line 49) | def sanity_check( function final_check (line 57) | def final_check( function check3 (line 83) | def check3(n: int, f: List[int], t: List[int], s1: List[int], s2: List[i... function brute (line 90) | def brute() -> None: function challenge1 (line 107) | def challenge1(challenge): function challenge2 (line 117) | def challenge2(challenge): function challenge3 (line 131) | def challenge3(challenge): function declaredSolved (line 138) | def declaredSolved(challenge): function main (line 142) | def main(): FILE: 2022/CryptoCTF/Aniely/aniely/aniely.py function aniely_stream (line 7) | def aniely_stream(passphrase): function aniely_encrypt (line 41) | def aniely_encrypt(msg, passphrase): FILE: 2022/CryptoCTF/Aniely/solve.py function aniely_stream (line 11) | def aniely_stream(passphrase): function aniely_encrypt (line 46) | def aniely_encrypt(msg, passphrase): FILE: 2022/CryptoCTF/Cantilever/cantilever/cantilever.py function gen_primes (line 6) | def gen_primes(nbit, imbalance): function genkey (line 28) | def genkey(nbit, imbalance, e): FILE: 2022/CryptoCTF/polyRSA/polyRSA/polyRSA.py function keygen (line 6) | def keygen(nbit = 64): function encrypt (line 14) | def encrypt(msg, n, e = 31337): FILE: 2022/Hack-A-Sat/Matters_of_State/solve.py function _interact (line 24) | def _interact(tn, s): function interact (line 39) | def interact(pos: int, check: float) -> Tuple[float, float]: function binary_search (line 69) | def binary_search(): FILE: 2022/Lake/Immutable/immutable.py function gib_flag (line 19) | def gib_flag(): function auth (line 23) | def auth(addr): function audit (line 27) | def audit(): function target (line 39) | def target(addr): function rugpull (line 42) | def rugpull(): FILE: 2022/Lake/Immutable/immutable_local.py function gib_flag (line 16) | def gib_flag(): function auth (line 20) | def auth(addr): function audit (line 24) | def audit(): function target (line 36) | def target(addr): function rugpull (line 39) | def rugpull(): FILE: 2022/Lake/Immutable/test/solution.js function hexToBytes (line 11) | function hexToBytes(hex) { FILE: 2022/Lake/NeutronMail/solve.py function _generate (line 13) | def _generate(self, key_size): function __new__ (line 69) | def __new__(cls, content): FILE: 2022/Lake/QuinEVM/quinevm.py function gib_flag (line 18) | def gib_flag(): function verify (line 22) | def verify(addr): FILE: 2022/Lake/QuinEVM/quinevm_local.py function gib_flag (line 15) | def gib_flag(): function verify (line 19) | def verify(addr): FILE: 2022/PlaidCTF/choreography/cipher.py function encrypt1 (line 11) | def encrypt1(k, plaintext): function encrypt2 (line 19) | def encrypt2(k, plaintext): function handle_queries (line 30) | def handle_queries(f): FILE: 2022/PlaidCTF/choreography/solve.py function encrypt1 (line 27) | def encrypt1(k, plaintext): function encrypt2 (line 36) | def encrypt2(k, plaintext): function decrypt1 (line 45) | def decrypt1(k, ciphertext): function generate_data (line 51) | def generate_data(): function PoW (line 63) | def PoW(): function encryption_oracle_send (line 81) | def encryption_oracle_send(pts): function encryption_oracle_recv (line 91) | def encryption_oracle_recv(pts, cts): function decryption_oracle_send (line 98) | def decryption_oracle_send(cts): function decryption_oracle_recv (line 109) | def decryption_oracle_recv(cts, pts_swapped): function oracle_recv (line 117) | def oracle_recv(data): function f_extract_key (line 125) | def f_extract_key(X, Y, delta): function recover_key (line 131) | def recover_key(): function get_flag (line 167) | def get_flag(key): function main (line 175) | def main(): FILE: 2022/RCTF/IS_THIS_LCG/task/curve_challenge.py function gen_p2 (line 10) | def gen_p2(): FILE: 2022/RCTF/IS_THIS_LCG/task/matrix_challenge.py function gen_p3 (line 10) | def gen_p3(): FILE: 2022/RCTF/IS_THIS_LCG/task/partial_challenge.py function gen_p1 (line 9) | def gen_p1(): FILE: 2022/RCTF/IS_THIS_LCG/task/util.py function mt2dec (line 1) | def mt2dec(X, n, m): FILE: 2022/RCTF/S2DH/helpers.py function possibly_parallel (line 3) | def possibly_parallel(num_cores): function supersingular_gens (line 13) | def supersingular_gens(E): function fast_log3 (line 34) | def fast_log3(x, base): function test_fast_log3 (line 67) | def test_fast_log3(): FILE: 2022/RCTF/S2DH/public_values_aux.py function generate_distortion_map (line 5) | def generate_distortion_map(E): function generate_torsion_points (line 10) | def generate_torsion_points(E, a, b): function check_torsion_points (line 20) | def check_torsion_points(E, a, b, P2, Q2, P3, Q3): function gen_bob_keypair (line 29) | def gen_bob_keypair(E_start, b, P2, Q2, P3, Q3): FILE: 2022/asis/disinvolute/collect.py function extract (line 24) | def extract(idx: int) -> None: FILE: 2022/asis/prepsi/prepsi.py function distance (line 7) | def distance(u, v): function randstr (line 15) | def randstr(l): FILE: 2022/b01lers/Data_Science/data_science-source.c function myrand (line 6) | double myrand() { function compute (line 16) | double compute(double a, double b, double A, double B, double C) { function main (line 70) | int main(int ARGC, const char** const ARGV) { FILE: 2022/b01lers/Data_Science/solve.py function recv_menu (line 12) | def recv_menu(): FILE: 2022/b01lers/Hardcore/Hardcore.py function digest_to_array (line 9) | def digest_to_array(digest): function bitstring_to_bytes (line 20) | def bitstring_to_bytes(s): function generate_hardcore (line 25) | def generate_hardcore(secret, r): function predictor (line 28) | def predictor(r, probability = 1): function parse_input (line 41) | def parse_input(): function Level (line 50) | def Level(probability): function main (line 66) | def main(): FILE: 2022/b01lers/Hardcore/solve.py function solve1 (line 17) | def solve1(): function solve2 (line 37) | def solve2(): FILE: 2022/m0lecon/MOO/server.py function gen_prime (line 8) | def gen_prime(): function f1 (line 22) | def f1(a, p, fs): function f2 (line 36) | def f2(a, m, fs): FILE: 2022/m0lecon/MOO/solve.py function recvint (line 19) | def recvint() -> int: function solve_quadratic (line 23) | def solve_quadratic(a, b, c) -> Tuple[int, int]: FILE: 2022/redpwn/small-fortune/script.py function gm_encrypt (line 14) | def gm_encrypt(msg, n, x): FILE: 2022/uiu/Elliptic_Curve_Crypto/ecc.py class Fp (line 13) | class Fp: method __init__ (line 14) | def __init__(self, x): method __str__ (line 17) | def __str__(self): method __int__ (line 22) | def __int__(self): method __eq__ (line 25) | def __eq__(a, b): method __ne__ (line 28) | def __ne__(a, b): method __add__ (line 31) | def __add__(a, b): method __sub__ (line 34) | def __sub__(a, b): method __mul__ (line 37) | def __mul__(a, b): method __truediv__ (line 40) | def __truediv__(a, b): class ClockPoint (line 44) | class ClockPoint: method __init__ (line 45) | def __init__(self, x, y): method __str__ (line 50) | def __str__(self): method __eq__ (line 53) | def __eq__(self, other): method get_hash (line 58) | def get_hash(self): method __add__ (line 61) | def __add__(self, other): function scalar_mult (line 67) | def scalar_mult(x: ClockPoint, n: int) -> ClockPoint: FILE: 2022/uiu/Elliptic_Curve_Crypto/solve.py class Fp (line 10) | class Fp: method __init__ (line 11) | def __init__(self, x): method __str__ (line 14) | def __str__(self): method __int__ (line 19) | def __int__(self): method __eq__ (line 22) | def __eq__(a, b): method __ne__ (line 25) | def __ne__(a, b): method __add__ (line 28) | def __add__(a, b): method __sub__ (line 31) | def __sub__(a, b): method __mul__ (line 34) | def __mul__(a, b): method __truediv__ (line 37) | def __truediv__(a, b): class ClockPoint (line 41) | class ClockPoint: method __init__ (line 42) | def __init__(self, x, y): method __str__ (line 47) | def __str__(self): method __eq__ (line 50) | def __eq__(self, other): method get_hash (line 55) | def get_hash(self): method __add__ (line 58) | def __add__(self, other): function scalar_mult (line 64) | def scalar_mult(x: ClockPoint, n: int) -> ClockPoint: FILE: 2023/CCE/NZK-SIARK/GF.py class GF (line 1) | class GF: # Polynomial = x^8 + x^4 + x^3 + x^1 + x^0 method __init__ (line 2) | def __init__(self, val): method __add__ (line 5) | def __add__(self, other): method __sub__ (line 8) | def __sub__(self, other): method __mul__ (line 11) | def __mul__(self, other): method lrotate (line 24) | def lrotate(self, other): method __rshift__ (line 27) | def __rshift__(self, other): method __eq__ (line 30) | def __eq__(self, other): method __str__ (line 33) | def __str__(self): method __int__ (line 36) | def __int__(self): FILE: 2023/CCE/NZK-SIARK/prob.py function get_sbox_and_verify (line 5) | def get_sbox_and_verify(x): function key_schedule (line 12) | def key_schedule(round_keys, KEY): function add_round_key (line 31) | def add_round_key(state, round_key): function sub_bytes (line 36) | def sub_bytes(state): function shift_rows (line 41) | def shift_rows(state): function mix_columns (line 47) | def mix_columns(state): FILE: 2023/CCE/NZK-SIARK/solve.py function key_schedule (line 24) | def key_schedule(round_keys, KEY): function add_round_key (line 47) | def add_round_key(state, round_key): function inv_sub_bytes (line 53) | def inv_sub_bytes(state): function inv_mix_columns (line 59) | def inv_mix_columns(state): function inv_shift_rows (line 79) | def inv_shift_rows(state): function sub_bytes (line 100) | def sub_bytes(state): function shift_rows (line 106) | def shift_rows(state): function mix_columns (line 127) | def mix_columns(state): function test_inv (line 147) | def test_inv(): function honest_response (line 161) | def honest_response(): function forge_response (line 175) | def forge_response(target): function print_state (line 199) | def print_state(s): FILE: 2023/CCE/Wrong-Implementation/solve.py function recover_key (line 35) | def recover_key(pt_oracle: bytes, ct_oracle: bytes) -> bytes: FILE: 2023/CCE/Wrong-Implementation/wrong-implementation.py function encrypt (line 9) | def encrypt(P, K): FILE: 2023/Dice/BBBB/bbbb.py function generate_key (line 7) | def generate_key(rng, seed): function generate_params (line 22) | def generate_params(): function main (line 29) | def main(): FILE: 2023/TSG/Delta-Force/elliptic_curve.py class EC (line 3) | class EC: method __init__ (line 6) | def __init__(self, k, a): method iszeropoint (line 18) | def iszeropoint(self, p): method negate (line 25) | def negate(self, p): method add (line 31) | def add(self, p1, p2): method scalar (line 56) | def scalar(self, a, p):