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 | |
# coding: utf-8 | |
""" | |
This script will migrate data stored in the `D:\Data Analytics Projects\JTF-COVID\Testing Site Trends\Daily Reports` | |
directory to a a new `.xlsx` file which can be used for simple data analytics regarding JTF-COVID controlled COVID-19 | |
testing sites. | |
**Note:** This file has hard coded paths in the `main()` and `writeTrendsReport()` functions. | |
""" |
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
--- | |
title: "New York State Regional COVID-19 Breakdown" | |
output: html_notebook | |
--- | |
This is an [R Markdown](http://rmarkdown.rstudio.com) Notebook. When you execute code within the notebook, the results appear beneath the code. | |
<hr> | |
```{r} |
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
import csv | |
import ipinfo | |
import re | |
def main(): | |
with open('data.csv', newline='') as csvfile: | |
reader = csv.DictReader(csvfile) | |
for row in reader: | |
details = getDetails(row['IPAddress']) | |
writeDetails(details) |
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 netaddr import * | |
import pprint | |
import socket | |
data = raw_input("Enter the CIDR you would like me to resolve: ") | |
network = IPNetwork(data) | |
file = open ("hostnames.txt", "a") | |
for ip in network: |
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
import os | |
import re | |
import mysql.connector | |
from mysql.connector import Error | |
def getFiles(currentWD): | |
filesToRead = [] | |
for dirname, dirnames, filenames in os.walk(currentWD): | |
for filename in filenames: | |
# ignore some files we don't care about |
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
import os | |
import time | |
# In the current configuration, this script should be able to process: | |
# 200,000 rps (records per second) | |
# GLOBAL VARIABLE | |
emailDomains = ['@hotmail.com', '@yahoo.com', '@gmail.com', '@aol.com', '@hotmail.fr', '@live.com', '@yahoo.fr', | |
'@yahoo.com.tw', '@hotmail.co.uk', '@ymail.com', '@msn.com', '@breakthru.com', '@rediffmail.com', |
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
readfile = raw_input("Please Enter The File You Wish To Read: ") | |
savefile = raw_input("Please Enter The File You Wish To Save: ") | |
read = open(readfile, "r") | |
save = open(savefile, "w+") | |
for line in read: | |
text = " " # Enter what you would like to append here | |
text2 = line | |
newline = text+text2 # You can swap the variables here if you want to add something to the beginning or end of the line. |
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 PIL import ImageGrab | |
import webbrowser | |
import time | |
browser = 'firefox' | |
url = 'https://twitter.com/cyb3rdude' | |
webbrowser.get(browser).open_new_tab(url) | |
# Wait a few seconds to allow the page to load | |
time.sleep(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
from threading import Thread | |
import requests | |
import time | |
with open('domains.txt') as f: | |
domainList = f.readlines() | |
domainList = [x.strip() for x in domainList] | |
#TODO: Check list for .onion domains and ignore said entries |