Skip to content

Instantly share code, notes, and snippets.

View mdenzel's full-sized avatar
🤘

Mike mdenzel

🤘
View GitHub Profile
@mdenzel
mdenzel / vmount.sh
Last active May 11, 2024 20:39
Linux: mount a Veracrypt volume
#!/bin/bash
### CONFIG ###
MOUNT=/media/tmp
VERA=${VERA:-/dev/sdb1} #default value /dev/sdb1
##############
if [ "$1" == "-u" ]; then
sudo veracrypt -t -d $VERA
else
@mdenzel
mdenzel / hg-git-clone.sh
Last active May 11, 2024 20:42
Dev: github with mercurial/hg
#!/bin/bash
# --- functions ---
clone(){
#remove https://
repo=git+ssh://git@${1#"https://"}.git
#clone repo
hg clone $repo
if [ $? -ne 0 ]; then
@mdenzel
mdenzel / fedora-get-new-version.sh
Last active May 11, 2024 20:41
Linux: upgrade Fedora to next version
#!/bin/bash
VERSION=$(( `cat /etc/os-release | grep VERSION_ID | cut -d '=' -f2` + 1 ))
echo "Getting Fedora $VERSION"
sudo dnf --refresh upgrade || exit 13
sudo dnf install dnf-plugin-system-upgrade || exit 13
sudo dnf system-upgrade download --refresh --releasever=$VERSION || exit 13
sudo dnf system-upgrade reboot || exit 13
@mdenzel
mdenzel / bitlockermount.sh
Last active May 11, 2024 20:39
Linux: mount bitlocker drive
#!/bin/bash
### CONFIG ###
DISLOCKER=/media/tmp
MOUNTPOINT=/media/usb
##############
#error check
if [ $# -ne 1 ]; then
echo "usage: $0 <disk> [-u]"
@mdenzel
mdenzel / acquire-vm.sh
Last active May 11, 2024 20:40
DFIR: acquire VirtualBox VM
#!/bin/bash
### CONFIG ###
OUT=dump
##############
usage(){
echo -e "usage: \n\
(currently only VirtualBox supported) \n\
$0 -r <name of VM> (acquire RAM)\n\
@mdenzel
mdenzel / open-source-SOC.md
Last active September 6, 2023 08:16
Open-source tools to build a SOC

Low-Budget SOC

I always get complaints from my customers, that security is expensive.

So, this is the attempt to create a Security Operations Center (SOC) on a budget.

I assume a server is available and security personnel. (without people, there's no company...)

@mdenzel
mdenzel / hgignore
Last active May 11, 2024 20:42
Dev: example hgignore config
syntax: glob
#Projects
[Bb]in
[Dd]ebug
[Rr]elease
.hgignore
ideas.txt
#Temp files