Skip to content

Instantly share code, notes, and snippets.

@byronwai
byronwai / 01-blink.ino
Last active May 5, 2025 17:34
All Demo Code for Digispark
param (
[string]$Target, # Target IP or domain provided as an argument
[string]$OutputFile = "ScanResults.csv" # Default output file
)
# Check if Target is provided
if (-not $Target) {
Write-Host "Usage: .\PortScanner.ps1 -Target <IP or Domain>"
exit
}
import requests
import time
import re
import csv
# GitLab instance details
GITLAB_URL = "https://gitlab.example.com" # Replace with your GitLab instance URL
PRIVATE_TOKEN = "<your_access_token>" # Replace with your GitLab admin token
OUTPUT_CSV = "GitLab_AWS_Keys_Report.csv"
@byronwai
byronwai / can0.log
Created May 29, 2024 03:20
The candump result while I played with all buttons on RAMN in SINCON 2024 car hacking workshop
(1716454260.542046) can0 024#0000691932A710F1
(1716454260.543251) can0 039#0000691932A710F1
(1716454260.544673) can0 062#08A46918F74AD29D
(1716454260.552524) can0 024#0000691A88F61968
(1716454260.553374) can0 039#0000691A88F61968
(1716454260.553881) can0 062#08A46919617AD5EA
(1716454260.562387) can0 024#0000691B1EC61E1F
(1716454260.562579) can0 039#0000691B1EC61E1F
(1716454260.563463) can0 062#08A2691A69575177
(1716454260.572013) can0 024#0000691CBD537A81
#!/bin/bash
# Usage: ./batch-vol-nix.sh <volatility_directory> <output_format> <memory_images_dir_or_file> <output_dir> <number_of_thread>
## Example: ./batch-vol-nix.sh "./volatility/" "quick" "./memory-images/" "./vol-log/" "5"
# Custom Volatility 3 location (directory)
volatility_directory="$1"
# Output format (quick, csv, json)
output_format="$2"
#!/bin/bash
# Usage: ./batch-vol-nix-yara.sh <volatility_directory> <output_format> <mem_dir> <yara_rule_dir> <output_dir> <number_of_thread>
## Example: ./batch-vol-nix-yara.sh "./volatility/" "quick" "./memory-images/" "./yara-rules/" "./yara-log/" "5"
# Custom Volatility 3 location (directory)
volatility_directory="$1"
# Output format (quick, csv, json)
output_format="$2"
@byronwai
byronwai / convert.ps1
Created December 4, 2023 07:48
Base64 to transfer file
# Set the path to the executable file
$executablePath = "C:\path\to\executable.exe"
# Set the output path for the Base64 string
$outputFilePath = "C:\base64\output.txt"
# Read the content of the executable file as bytes
$fileBytes = [System.IO.File]::ReadAllBytes($executablePath)
# Convert the byte array to a Base64 string
import random
import sys
def str_xor(secret, key):
#extend key to secret length
new_key = key
i = 0
import hashlib
### THIS FUNCTION WILL NOT HELP YOU FIND THE FLAG --LT ########################
def str_xor(secret, key):
#extend key to secret length
new_key = key
i = 0
while len(new_key) < len(secret):
new_key = new_key + key[i]
i = (i + 1) % len(key)
import hashlib
### THIS FUNCTION WILL NOT HELP YOU FIND THE FLAG --LT ########################
def str_xor(secret, key):
#extend key to secret length
new_key = key
i = 0
while len(new_key) < len(secret):
new_key = new_key + key[i]
i = (i + 1) % len(key)