Skip to content

Instantly share code, notes, and snippets.

View Clevero's full-sized avatar

Marcel Caspar Clevero

  • Frankfurt am Main
View GitHub Profile
@perryflynn
perryflynn / find-log4j-debian.sh
Last active January 21, 2022 19:32
Find log4j for CVE-2021-44228 on some places * Log4Shell REPO: https://github.com/perryflynn/find-log4j
# by Christian Blechert <christian@serverless.industries>
# ATTENTION! It only checks ext3 + ext4 filesystems right now!
# Extend it if you use something else
# Repo: https://github.com/perryflynn/find-log4j
while read -u 3 -r JAR
do
@athoune
athoune / mailq.py
Last active October 17, 2019 20:11
Parsing mailq format (from Postfix 2.x)
#!/usr/bin/env python3
import subprocess
import re
from pypred import Predicate
SPACE = re.compile(r"\s+")
def mailq():
@blupu
blupu / add-custom-data.php
Last active March 10, 2018 14:59
WP-AppKit - Custom template if post has a specific category
<?php
/*
* @desc Add custom data to what is returned by the web services. All custom data will be available to the JS API.
* @param $post_data
* @param $post
* @param $component
*/
function wpak_add_custom_data( $post_data, $post, $component ) {
$taxonomy = 'category'; // We search for categories
#!/bin/bash
PAST_TIMESTAMP="$(date +%s -d '5 min ago')000"
mongoexport \
--csv --quiet \
--fields timestamp,source_ip,source_port,destination_port,honeypot \
--db mnemosyne \
--collection session \
--query "{ timestamp: {\$gt: new Date($PAST_TIMESTAMP)}}" > /tmp/mhn-report.txt
@subodhghulaxe
subodhghulaxe / last_names.php
Created December 27, 2013 16:04
List of last names as php array
<?php
$last_names = array(
'Abbott',
'Acevedo',
'Acosta',
'Adams',
'Adkins',
'Aguilar',
'Aguirre',
'Albert',
#!/bin/sh
# Schwanzvergleich powered by http://pinguinblog.de
export LC_ALL=C
echo `uptime|grep days|sed 's/.*up \([0-9]*\) day.*/\1\/10+/'; cat /proc/cpuinfo|grep '^cpu MHz'|awk '{print $4"/30 +";}';free|grep '^Mem'|awk '{print $3"/1024/3+"}'; df -P -k -x nfs -x smbfs | grep -v '(1k|1024)-blocks' | awk '{if ($1 ~ "/dev/(cciss|scsi|sd)"){ s+= $2} s+= $2;} END {print s/1024/50"/15+70";}'`|bc|sed 's/\(.$\)/.\1cm/'
@brysonian
brysonian / first_names.php
Created April 21, 2009 22:21
list of first names formatted as a PHP array
<?php
$names = array(
'Allison',
'Arthur',
'Ana',
'Alex',
'Arlene',
'Alberto',
'Barry',