This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # While doing IR, we found a log entry which suggested that sftp was open, file was uploaded, but we | |
| # couldn't figure out how it was executed as there wasn't a second login attempt to start the script | |
| # This script explains it. | |
| # Feb 3 15:30:17 kali sshd[5222]: Accepted password for joe from 192.168.61.1 port 28568 ssh2 | |
| # Feb 3 15:30:17 kali sshd[5222]: pam_unix(sshd:session): session opened for user joe by (uid=0) | |
| # Feb 3 15:30:17 kali sshd[5227]: subsystem request for sftp by user joe | |
| # Feb 3 15:30:20 kali sshd[5222]: pam_unix(sshd:session): session closed for user joe |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # by Konrads Smelkovs <[email protected]> | |
| # Cool contributions by sash | |
| # Licence - CC-BY, else do whatever you want with this | |
| import urllib2 | |
| import json | |
| import time | |
| import sys | |
| import argparse |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/perl -w | |
| # Copyright 2014 Konrads Smelkovs <[email protected]> | |
| #$ cat shooturl.sh | |
| # #!/bin/bash | |
| # /usr/local/bin/CutyCapt --insecure --url=$1 --out=`echo $1|tr '/:' '__'`.png | |
| # Usage: gnmap-to-http-urls.pl scan.gnmap | xargs -P 5 -n 1 --verbose ./shooturl.sh | |
| while (<>) { | |
| next unless m!\d+/open/!; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### THE AMAZING OBJECT IDENTIFIER ##### | |
| # By Konrads Smelkovs <[email protected]> | |
| # Math.cos(1); | |
| # x=document.createElement("div") | |
| # Math.atan2(1,"Allocated div"); | |
| # x.className="foo"; | |
| # Math.sin(1); | |
| # Math.atan(1); | |
| # | |
| # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # Solution to DRG Challenge at FIRSTCON 2014 | |
| # Two bytes from a UDP packet NUL'ed, need to find them so that checksum matches | |
| import sys | |
| from timeit import timeit | |
| from scapy.all import * | |
| pref="\x00\x03\x00\x01XtG8hI" | |
| targetchecksum=0x808c | |
| #targetchecksum=0x8549 | |
| #targetchecksum=0x8555 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import cmd,urllib2, argparse,urlparse,re,urllib,binascii | |
| DEFAULT_SPLIT=256 # AIX max len is 4k, so we're just shy | |
| def debug(text): | |
| global args | |
| if args.debug: | |
| print "[DD] " + text | |
| class WebRCE(object): | |
| def __init__(self): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 6.7.8.9 | |
| 2.2.2.2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/perl -w | |
| #/ | |
| # This software is Copyright (c) 2013 Konrads Smelkovs <[email protected]>, | |
| # and it is hereby released to the general public under the following terms: | |
| # Redistribution and use in source and binary forms, with or without | |
| # modification, are permitted. | |
| # | |
| # This script converts AIX /etc/security/passw | |
| # cat /etc/security/passwd | |
| # root: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/perl -wn | |
| @a=split /[^\d.]/; | |
| foreach (@a){ | |
| print "$1\n" if m!^(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})$!; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from sulley import * | |
| from requests import ipfix | |
| sess = sessions.session(session_filename='audits/ipfix.session',proto="udp",log_level=1,sleep_time=0.1) | |
| target = sessions.target('1.2.3.4',2055) | |
| target.netmon = pedrpc.client('127.0.0.1',26001) | |
| sess.add_target(target) | |
| # sess.connect(s_get("flowheader")) |