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 python3 | |
| """ | |
| nmap2urls.py | |
| Takes an nmap XML file and prints a list of URLs discovered. | |
| Optionally fetches each URL and extracts Title, Server banner, and detects login/auth. | |
| Usage examples: | |
| python3 nmap2urls.py --info -t 5 scan.xml | |
| python3 nmap2urls.py -v --workers 20 scan.xml |
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
| Get-Process | Select-Object -Property Path | where {$_ -ne ""} |
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
| # Powershell script designed to be run on Windows 7 workstations and above. | |
| # Gets the following information which is useful in a pentest: | |
| # * A list of domain users (useful for finding intersting comments | |
| # * A list of shares in the domain (typically includes all Windows workstations/servers connected to the domain) | |
| # * A list of ACLs for each share, in a nice HTML table that can be copy/pasted into Word | |
| # * A list of files/directories in the root of each share | |
| # * A full recursive directory listing of each share (useful for finding interesting file names) | |
| # * A search for files containing specific strings. This often takes a long long time, hence is optional | |
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
| Reset-ComputerMachinePassword -Credential <DOMAIN>\<ADMINUSER> |
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 | |
| COLLECTIONDIR=~/collection/ | |
| USER=XXXX | |
| PASS=YYYY | |
| DOMAIN=ZZZZ | |
| while read HOST | |
| do |
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
| <# | |
| This script will create a report of users that are members of the following | |
| privileged groups: | |
| - Enterprise Admins | |
| - Schema Admins | |
| - Domain Admins | |
| - Cert Publishers | |
| - Administrators | |
| - Account Operators | |
| - Server Operators |
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
| # Redirect to a different page when a PHP file is uploaded | |
| SecRule FILES "(?i)\.php$" "t:none,log,redirect:http://cyberis.co.uk,msg:'PHP file upload blocked',id:1" | |
| # Deny when a semi-colon is found in the 'ip' parameter | |
| SecRule ARGS:ip ";" "t:none,log,deny,msg:'semi colon test',id:2" | |
| # Disable ModSecurity for a given page - NOTE THE ESCAPE OF THE '?' | |
| SecRule REQUEST_URI "/joomla/index.php/component/users/\?task=registration.register" "allow,id: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
| Get-ADUser -Filter * -Properties * ` | |
| | where {($_.enabled -eq $true) -and ($_.lockedout -eq $false)} ` | |
| | where {$_.passwordlastset -lt (Get-Date).AddYears(-1)} ` | |
| | select SamAccountName, passwordlastset ` | |
| | sort passwordlastset |
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
| Get-ADUser -Filter * -Properties * ` | |
| | where {($_.enabled -eq $true) -and ($_.lockedout -eq $false)} ` | |
| | where {$_.passwordneverexpires -eq $true} ` | |
| | select SamAccountName |
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
| runas.exe /netonly /user:DOMAIN\username mbsa.exe |