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
924117dfd0f821775216dc77898e45f969a0cc998b0095fa6fd6f18681fad044 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

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
/blog | |
/blog/ | |
/blog/blog.rss | |
/blog/page-data/ | |
/blog/page-data/app-data.json | |
/blog/sw.js | |
/blog/_wpeprivate/config.json | |
/books | |
/.bower.json | |
/bower.json |
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 ipaddress import ip_network, ip_address | |
import json | |
import requests | |
import sys | |
def find_aws_region(): | |
ip_json = requests.get('https://ip-ranges.amazonaws.com/ip-ranges.json') | |
#ip_json = json.load(open('ip-ranges.json')) | |
ip_json = ip_json.json() | |
prefixes = ip_json['prefixes'] |
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
SELECT distinct issuer_ca_id, COUNT(*) FROM certificate_identity ci WHERE ci.NAME_TYPE = 'dNSName' AND reverse(lower(ci.NAME_VALUE)) LIKE reverse(lower('%gov.in')) GROUP BY issuer_ca_id ORDER BY COUNT(*) desc; | |
SELECT certificate_id,issuer_o,issuer_cn FROM ccadb_certificate WHERE certificate_id IN(SELECT distinct certificate_id FROM certificate_identity ci WHERE ci.NAME_TYPE = 'dNSName' AND reverse(lower(ci.NAME_VALUE)) LIKE reverse(lower('%appsecco.com'))); | |
SELECT distinct ca.name, COUNT(*) count FROM certificate_identity ci, ca ca WHERE ci.NAME_TYPE = 'dNSName' AND reverse(lower(ci.NAME_VALUE)) LIKE reverse(lower('%gov.in')) AND ca.id=ci.issuer_ca_id GROUP BY ca.name ORDER BY count desc; |
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
Python debugger: | |
Stop programs mid execution | |
Examine it line by line | |
Look at the contents of the variable in the middle of the execution | |
Any python script can be set to be debugged | |
2 ways to start the debugger: | |
import pdb; pdb.set_trace() | |
python -m pdb script.py |
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
find-subdomains-vt() | |
{ curl -s https://www.virustotal.com/ui/domains/$1/subdomains\?limit\=$2 | jq .data[].id; } |
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
find-cert() | |
{ curl -s https://certspotter.com/api/v0/certs?domain=$1 | jq -c '.[].dns_names' | grep -o '"[^"]\+"'; } |
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 __future__ import print_function | |
__author__ = 'Bharath' | |
__version__ = "0.1.0" | |
try: | |
import psycopg2 | |
except ImportError: | |
raise ImportError('\n\033[33mpsycopg2 library missing. pip install psycopg2\033[1;m\n') | |
sys.exit(1) |