Skip to content

Instantly share code, notes, and snippets.

View aziz0x00's full-sized avatar

Aziz aziz0x00

  • Mauritania
View GitHub Profile
@str4d
str4d / DemangleRust.py
Last active May 7, 2024 01:40
Ghidra script for demangling Rust symbols
# Attempts to demangle all mangled symbols in the current program using the Rust
# mangling schemes, and replace the default symbol and function signature
# (if applicable) with the demangled symbol.
#
# License: MIT OR Apache-2.0
#@author Jack Grigg <thestr4d@gmail.com>
#@category Symbol
import string
@jdah
jdah / .vimrc
Created June 14, 2021 11:54
jdh's NeoVim .vimrc
call plug#begin()
Plug 'drewtempelmeyer/palenight.vim'
Plug 'vim-airline/vim-airline'
Plug 'wlangstroth/vim-racket'
Plug 'sheerun/vim-polyglot'
Plug 'rust-lang/rust.vim'
Plug 'preservim/tagbar'
Plug 'universal-ctags/ctags'
Plug 'luochen1990/rainbow'
Plug 'vim-syntastic/syntastic'
@ashleighbasil
ashleighbasil / list_comprehension_vs_js_methods.sh
Created February 24, 2021 17:14
Prove aziz wrong on Twitter about comprehension speed
ash@ly:~$ python3
Python 3.8.5 (default, Jul 28 2020, 12:59:40)
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from time import perf_counter
>>> lst = range(10_000)
>>> before = perf_counter(); _=[i for i in lst if i % 2]; perf_counter() - before
0.0010968240001147933
## compare to JS
@pqlx
pqlx / ec-param-check.sage
Last active December 28, 2023 20:59
Identifying weak elliptic curve cryptography domain parameters.
def check_pohlig_hellman(curve, generator=None):
"""
The Pohlig-Hellman algorithm allows for quick (EC)DLP solving if the order of the curve is smooth,
i.e its order is a product of multiple (small) primes.
The best general purpose algorithm for finding a discrete logarithm is the Baby-step giant-step
algorithm, with a running time of O(sqrt(n)).
If the order of the curve (over a finite field) is smooth, we can however solve the (EC)DLP
algorithm by solving the (EC)DLP for all the prime powers that make up the order, then using the