Skip to content

Instantly share code, notes, and snippets.

@libcrack
libcrack / dnsbl.sh
Created May 12, 2024 14:24
Script to extract allow and deny lists from pfblockerng in pfSense boxes
#!/bin/sh
# [email protected]
# Mon Sep 9 21:30:51 CEST 2019
denylist=/root/dnsbl.deny
allowlist=/root/dnsbl.allow
allowtmp=/tmp/dnsbl_tmp.sup
logfile=/var/log/pfblockerng/dnsbl.log
@libcrack
libcrack / bypass_filter.php
Created May 12, 2024 14:17
PHP script to enable/disable custom pfSense firewall rules
#!/usr/local/bin/php-cgi -f
# [email protected]
# Thu Mar 2 19:48:14 CET 2023
<?php
require_once("globals.inc");
require_once("filter.inc");
require_once("util.inc");
require_once("config.inc");
@libcrack
libcrack / manpages-install.sh
Created May 12, 2024 14:05
Install FreeBSD manpages in pfSense boxes
#!/bin/sh
# [email protected]
# Thu Mar 2 19:48:14 CET 2023
#
# From http://ftp.freebsd.org/pub/FreeBSD/README.TXT
#
# releases/${MACHINE}/${MACHINE_ARCH}/*-RELEASE/
# The official FreeBSD releases as individual tarballs to download; useful
# for jail hosting, updating machines in situ, etc. Make sure to look in
# the ${MACHINE_ARCH} sub-directory for the most recent releases (e.g.,
@libcrack
libcrack / cve-get.py
Created May 9, 2024 04:07
Print the summary and CVSSv3 vector for the CVEs passed as arguments
#!/usr/bin/env python3
# coding: utf-8
# Thu May 9 05:51:35 CEST 2024
# sucata & surmano
#
# https://nvd.nist.gov/vuln/detail/CVE-2018-7105
# https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?name=CVE-2018-7105&vector=AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H&version=3.0&source=NIST
"""
Print the summary and CVSS3 vector for the CVEs passed as arguments (March 2014).
@libcrack
libcrack / ipmi.sh
Created May 9, 2024 02:19
Example commands to manage an HPE server iLO via IPMI
#!/usr/bin/env bash
# [email protected]
# Thu May 9 04:04:44 CEST 2024
#
# ——————————————————————————————————————————————————————————————————————————————————————————————
#
# $ ipmitool -H 10.10.10.10 -I lanplus -U admin
# Password:
# Unable to Get Channel Cipher Suites
# No command provided!
@libcrack
libcrack / unpack-scexe.sh
Created May 9, 2024 01:37
Script to unpack HPE iLO scexe firmware files
#!/usr/bin/env bash
# [email protected]
# Thu May 9 02:27:35 CEST 2024
# This script unpacks HPE iLO4 firmware scexe files
if [[ $# -ne 1 ]]; then
printf "Usage: $0 <CP053894.scexe>\n"
exit 1
fi
@libcrack
libcrack / shellcode_from_file.c
Created July 1, 2023 18:30
Execute shellcode from file
/*
* Exec shellcode from file (no need of -z execstack)
* gcc ./shellcode_from_file.c -o ./shellcode_from_file
*
* Sat Jul 1 20:21:12 CEST 2023
* [email protected]
*
* 1. Create a payload:
* msfvenom -p osx/x64/exec CMD=/bin/sh -f raw -o osx-exec.raw
*
@libcrack
libcrack / shellcode_mmap.c
Created July 1, 2023 18:28
Execute shellcode from file using mmap()
/*
* Exec shellcode from file
* gcc ./shellcode_mmap.c -o ./shellcode_mmap
*
* Sat Jul 1 20:21:12 CEST 2023
* [email protected]
*
* 1. Create a payload:
* msfvenom -p osx/x64/exec CMD=/bin/sh -f raw -o osx-exec.raw
*
#!/bin/bash
#
# findilos - Search a local network segment for iLOs
# The iLO is the Integrated Lights-Out management processor
# used on HP ProLiant and BladeSystem servers
#
scriptversion="1.0"
#
# Author: [email protected]
#
@libcrack
libcrack / PKGBUILD
Created March 3, 2019 23:03
mirrorlist-manager AUR package: PKGBUILD, setup.py, mirrorist-manager.desktop.in
# Bastard System Operator From Hell: <[email protected]>
pkgname=mirrorlist-manager
pkgver=1.1
pkgrel=1
pkgdesc="A Qt frontend for Pacman mirrorlist management"
arch=('x86_64')
url="https://github.com/Rizwan-Hasan/ArchLinux-Mirrorlist-Manager"
license=('GPL3')
depends=('python>=3.7.0' 'python-pyqt5>=5.11.2' 'python-sip-pyqt5>=4.19.12' 'pyqt5-common>=5.11.2' 'python-pandas>=0.23.4' 'pacman-contrib')