Skip to content

Instantly share code, notes, and snippets.

View adityaarakeri's full-sized avatar
:octocat:
Always learning

Adi adityaarakeri

:octocat:
Always learning
  • San Francisco Bay Area
View GitHub Profile
@adityaarakeri
adityaarakeri / curl.md
Created October 25, 2019 04:06 — forked from subfuzion/curl.md
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@adityaarakeri
adityaarakeri / OffensivePython.ipynb
Created September 18, 2019 04:03 — forked from fheisler/OffensivePython.ipynb
Hunter2: Offensive Python Workshop
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
import asyncio
loop = asyncio.get_event_loop()
async def hello():
await asyncio.sleep(3)
print('Hello!')
if __name__ == '__main__':
loop.run_until_complete(hello())
@adityaarakeri
adityaarakeri / requests.py
Created June 26, 2019 07:06 — forked from random-robbie/requests.py
Python Requests Ignore Bad SSL certificate
import requests
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
URL = "https://www.somesitewithbadssl.com"
headers = {"User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:54.0) Gecko/20100101 Firefox/54.0","Connection":"close","Accept-Language":"en-US,en;q=0.5","Accept":"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8","Upgrade-Insecure-Requests":"1"}
response = session.get(URL, headers=headers, timeout=15, verify=False)
result = response.text
print (result)
@adityaarakeri
adityaarakeri / Makefile
Created May 2, 2019 20:55 — forked from mpneuried/Makefile
Simple Makefile to build, run, tag and publish a docker containier to AWS-ECR
# import config.
# You can change the default config with `make cnf="config_special.env" build`
cnf ?= config.env
include $(cnf)
export $(shell sed 's/=.*//' $(cnf))
# import deploy config
# You can change the default deploy config with `make cnf="deploy_special.env" release`
dpl ?= deploy.env
include $(dpl)
import httplib
import base64
try:
import json
except ImportError:
import simplejson as json
config = {"username": "your-sauce-username",
"access-key": "your-sauce-api-key"}
@adityaarakeri
adityaarakeri / curl.md
Created March 20, 2019 06:39 — forked from btoone/curl.md
A curl tutorial using GitHub's API

Introduction

An introduction to curl using GitHub's API.

The Basics

Makes a basic GET request to the specifed URI

curl https://api.github.com/users/caspyin