This file contains 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
Verifying that "ankurtyagi.id" is my Blockstack ID. https://onename.com/ankurtyagi |
This file contains 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 pprint import pprint | |
from googleapiclient.discovery import build | |
service = build("customsearch", "v1", developerKey="KEY_HERE") | |
def search(query): | |
res = service.cse().list(q=query, cx="CX_ID_HERE").execute() | |
if 1 <= res["queries"]["request"][0]["totalResults"]: | |
result = res["items"][0] | |
response = result["link"] + "\r\n" + result["snippet"] | |
else: |
This file contains 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 | |
from pprint import pprint | |
import requests | |
import json | |
def circllu_cveinfo(cve): | |
customheaders = { | |
"User-Agent": "Some script trying to be nice :)" | |
} |
This file contains 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 pprint import pprint | |
import datetime | |
import struct | |
import sys | |
def capinfos(filename): | |
# generates wireshark's capinfos like stats | |
# limited features | |
# needs additional testing | |
file_handle = open(filename, 'rb') |
This file contains 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 | |
def sec_to_human(secs): | |
units = dict({ | |
7*24*3600: "week", | |
24*3600: "day", | |
3600: "hour", | |
60: "minute", | |
1: "second" | |
}) |
This file contains 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
import socket | |
def internet(host="8.8.8.8", port=53, timeout=3): | |
""" | |
Host: 8.8.8.8 (google-public-dns-a.google.com) | |
OpenPort: 53/tcp | |
Service: domain (DNS/TCP) | |
""" | |
try: | |
socket.setdefaulttimeout(timeout) |
This file contains 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 sys | |
if len(sys.argv) != 3: | |
print "USAGE: %s <KFFSE_XHKYOKXOHOFEDM^E_Y> <0x2a>" % (sys.argv[0]) | |
sys.exit(1) | |
flag = sys.argv[1] | |
key = int(sys.argv[2], 16) |
This file contains 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 sys | |
import re | |
import datetime, time | |
import argparse | |
import nids | |
end_states = (nids.NIDS_CLOSE, nids.NIDS_TIMEOUT, nids.NIDS_RESET) |