Skip to content

Instantly share code, notes, and snippets.

@nl5887
nl5887 / gist:ec5462b1671451163b29
Created August 18, 2015 19:59
install openoffice headless amazon linux
8 cd /usr/local/
9 wget http://download.documentfoundation.org/libreoffice/stable/5.0.0/rpm/x86_64/LibreOffice_5.0.0_Linux_x86-64_rpm.tar.gz
10 tar -xvf LibreOffice_5.0.0_Linux_x86-64_rpm.tar.gz
11 cd LibreOffice_5.0.0
12 cd LibreOffice_5.0.0_Linux_x86-64_rpm.tar.gz
13 cd LibreOffice_5.0.0.5_Linux_x86-64_rpm/
20 yum localinstall *.rpm --skip-broken
47 yum install cairo
50 yum install cups
51 /opt/libreoffice5.0/program/soffice --headless --convert-to csv websiteregister-rijksoverheid-20150730.ods
@nl5887
nl5887 / cargo-update-dependency.py
Last active June 16, 2023 09:29
Update cargo.toml dependencies recursively
import os
import toml
import argparse
parser = argparse.ArgumentParser(description='Update cargo toml module path')
parser.add_argument('--module', metavar='m', type=str, required=True)
parser.add_argument('--work-dir', type=str, default='.')
parser.add_argument('--version', type=str)
parser.add_argument('--path', type=str)
@nl5887
nl5887 / gist:8433808
Created January 15, 2014 10:10
Google App Engine boilerplate: Running background services.
package service
import (
_ "encoding/base64"
_ "fmt"
_ "net/http"
"appengine"
"appengine/urlfetch"
"appengine/runtime"
"time"
@nl5887
nl5887 / ApplicationProxy.cs
Created February 22, 2015 11:34
Compile and run dynamic .NET code in sandbox
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
namespace dutchcoders.Sandbox
{
public class ApplicationProxy : MarshalByRefObject
{
@nl5887
nl5887 / gpg-agent.conf
Last active November 14, 2022 09:37
Using GPG Agent on OS-X
launchctl unload -w -S Aqua /System/Library/LaunchAgents/gpg.agent.daemon.plist
launchctl load -w -S Aqua /System/Library/LaunchAgents/gpg.agent.daemon.plist
@nl5887
nl5887 / 001_readme.md
Last active July 10, 2022 02:44
Metasploit Meterpreter handler servers (HTTP/HTTPS)

This gist contains a list of verified Metasploit Meterpreter http(s) handlers and Powershell Empire http(s) listeners.

Servers could be malicious, or just part of a red teaming action.

Thanks to censys.io and Jose.

@nl5887
nl5887 / transfer.fish
Last active March 22, 2022 09:07
Bash and zsh alias for transfer.sh. Transfers files and directories to transfer.sh.
function transfer
if test (count $argv) -eq 0
echo "No arguments specified. Usage:\necho transfer /tmp/test.md\ncat /tmp/test.md | transfer test.md"
return 1
end
## get temporarily filename, output is written to this file show progress can be showed
set tmpfile ( mktemp -t transferXXX )
## upload stdin or file
@nl5887
nl5887 / 00_readme.md
Last active November 19, 2021 23:24
Ghidra decompile

Ghydra decompiler

This python script communicates with the Ghydra decompiler. Currently it succeeds in communicating, sending hardcoded opcodes and returning decompiled code.

Currently working on reversing the getPcodePacked command.

Next steps:

  • implement exception handling
  • implement callbacks
  • allow decompilation of custom payloads
@nl5887
nl5887 / convert.bash
Last active November 9, 2021 13:11
Quicktime to Animated gif using FFMPEG
#!/bin/bash
# convert to gif (improved palette) and 5 second still at the end
ffmpeg -i sans.mov -filter_complex "fps=25,setpts=PTS/5,split[v1][v2]; [v1]palettegen=stats_mode=full,tpad=stop_mode=clone:stop_duration=5 [palette];[v2][palette]paletteuse=dither=sierra2_4a" -loop 0 sans4.gif
@nl5887
nl5887 / gist:e6a082d3c5fa7ed97778b5247f34a07f
Last active June 30, 2021 11:29
pass git credentials using environment variables
git config --global credential."https://gitlab.com".helper '!f() { test "$1" = get && echo "username=${GIT_USER}"; echo "password=${GIT_PASS}"; }; f'