Skip to content

Instantly share code, notes, and snippets.

@0x4d4e
0x4d4e / decrypt.java
Created January 28, 2021 10:27 — forked from ashee/decrypt.java
jboss - decrypt vault password
import javax.crypto.Cipher;
import javax.crypto.SecretKey;
import javax.crypto.SecretKeyFactory;
import javax.crypto.spec.PBEKeySpec;
import javax.crypto.spec.PBEParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
@0x4d4e
0x4d4e / DefineAuthChallenge.js
Created September 28, 2020 11:06 — forked from mobilequickie/DefineAuthChallenge.js
Amazon Cognito CUSTOM_CHALLENGE Lambda trigger - Define Auth Challenge function
// ### About this Flow ###
// Using Custom Auth Flow through Amazon Cognito User Pools with Lambda Triggers to complete a 'CUSTOM_CHALLENGE'. This is the same flow as one-time passcode generated and sent via SMS or Email.
// Instead, the service and user share a secret that was created during registration and both generate a 6-digit code based on the shared secret.
// If the two codes (typically only good for 30 seconds) match, the user is authenticated.
//
// ### About this function ###
// This DefineAuthChallengeCustom function (1st and 4th of 4 triggers) defines the type of challenge-response required for authentication.
// For HOTP, TOTP, U2F, or WebAuthn flows, we'll always use 'CUSTOM_CHALLENGE' and this function code won't change between the various auth methods.
// ### Next steps ###
@0x4d4e
0x4d4e / CR95HF_ICODE_psw_dump.py
Created February 17, 2020 21:12 — forked from ceres-c/CR95HF_ICODE_psw_dump.py
CR95HF Python script to read NXP ICODE tags in privacy mode
#!/usr/bin/python3
# Author: ceres-c 2019-12-29
# Authenticate to ICODE SLI tags
import hid
# Global defines & commands
password = [0x00, 0x00, 0x00, 0x00] # You have to find it yourself, try to search online in german ;-)
@0x4d4e
0x4d4e / install_sign_reload_vmware.sh
Created June 27, 2019 06:05
Install VMware Workstation modules and sign for SecureBoot
#!/bin/bash
echo "> Building VMware modules..."
systemctl stop vmware.service
vmware-modconfig --console --install-all
echo "> Signing modules ..."
/usr/src/kernels/$(uname -r)/scripts/sign-file sha256 /root/module_sign/MOK.priv /root/module_sign/MOK.der $(modinfo -n vmmon)
/usr/src/kernels/$(uname -r)/scripts/sign-file sha256 /root/module_sign/MOK.priv /root/module_sign/MOK.der $(modinfo -n vmnet)
@0x4d4e
0x4d4e / android-authenticator2-extract-qrcode.sh
Created March 11, 2018 09:22 — forked from ragusa87/android-authenticator2-extract-qrcode.sh
Extract data from android backup of Google Authenticator 2 to qrcodes
#!/bin/bash
# Extract data from nandroid backup of Google Authenticator 2
# > /data/data/com.google.android.apps.authenticator2/databases/databases
# require: sqlite3 + qrencode
sqlite3 databases <<!
.headers off
.mode csv
.output codes.csv
select printf("otpauth://totp/%s?secret=%s&issuer=%s",email,secret,issuer) from accounts;
@0x4d4e
0x4d4e / Main.java
Created January 20, 2017 08:26 — forked from rwestergren/Main.java
GetAndroidSig
import java.io.IOException;
import java.io.InputStream;
import java.lang.ref.WeakReference;
import java.security.cert.CertificateEncodingException;
import java.util.Enumeration;
import java.util.jar.JarEntry;
import java.util.jar.JarFile;
import java.util.logging.Level;
import java.util.logging.Logger;
@0x4d4e
0x4d4e / gist:a5c5acdaf332b54ec1c79999918e46a8 MacOS X El Capitan with Vagrant - MacOS X VM on Windows/Linux
* Install Virtual Box (https://www.virtualbox.org)
* Install Oracle VM VirtualBox Extension Pack (https://www.virtualbox.org)
* Install Vagrant
mkdir osxvm
cd osxvm
vagrant init jhcook/osx-elcapitan-10.11
* Edit Vagrantfile
@0x4d4e
0x4d4e / burpscript.py
Created November 19, 2015 13:44 — forked from mwielgoszewski/burpscript.py
This extension registers an IHttpListener configured to execute a custom script editable via the Script tab added to Burp. The script is executed in the context with the following global and local variables (extender, callbacks, helpers, toolFlag, messageIsRequest, messageInfo).
from java.awt import Font
from javax.swing import JScrollPane, JTextPane
from javax.swing.text import SimpleAttributeSet
from burp import IBurpExtender, IExtensionStateListener, IHttpListener, ITab
import base64
import traceback
@0x4d4e
0x4d4e / lzs.py
Created April 27, 2014 10:26 — forked from FiloSottile/lzs.py
#!/usr/bin/env python
#-*- coding:utf-8 -*-
##############################################################
# Lempel-Ziv-Stac decompression
# BitReader and RingList classes
#
# Copyright (C) 2011 Filippo Valsorda - FiloSottile
# filosottile.wiki gmail.com - www.pytux.it
#