Skip to content

Instantly share code, notes, and snippets.

View auser's full-sized avatar

Ari auser

View GitHub Profile
@JamesMenetrey
JamesMenetrey / tutorial.txt
Created November 13, 2018 14:54
PwnTools; example of usage
Source: https://tc.gts3.org/cs6265/2017/l/lab04/README-tut.txt
====================================
Lec04: Writing Exploits with PwnTool
====================================
http://docs.pwntools.com/
http://docs.pwntools.com/en/stable/intro.html
@hjertnes
hjertnes / doom.txt
Created April 6, 2018 08:28
Doom Emacs Cheatsheet
SPC
SPC: find file
, switch buffer
. browse files
: MX
; EX
< switch buffer
` eval
u universal arg
x pop up scratch
@jhaddix
jhaddix / cloud_metadata.txt
Last active April 30, 2024 09:38 — forked from BuffaloWill/cloud_metadata.txt
Cloud Metadata Dictionary useful for SSRF Testing
## AWS
# from http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html#instancedata-data-categories
http://169.254.169.254/latest/user-data
http://169.254.169.254/latest/user-data/iam/security-credentials/[ROLE NAME]
http://169.254.169.254/latest/meta-data/iam/security-credentials/[ROLE NAME]
http://169.254.169.254/latest/meta-data/ami-id
http://169.254.169.254/latest/meta-data/reservation-id
http://169.254.169.254/latest/meta-data/hostname
http://169.254.169.254/latest/meta-data/public-keys/0/openssh-key
@jashmenn
jashmenn / geth-and-remix.scpt
Created November 16, 2017 17:48
open geth and remix in tabs via applescript
-- osascript services.scpt
tell application "iTerm 3"
activate
set myterm to (create window with default profile)
tell myterm
set mysession to (current session)
tell mysession
set name to "geth"
write text "cd ~/projects/fs/newline/newline-content-internal/fullstack-web3/private-net"
write text "./bin/geth --datadir=./datadir --nodiscover --rpc --rpcapi \"db,personal,eth,net,web3,debug\" --rpccorsdomain='*' --rpcaddr=\"localhost\" --rpcport 8545 --ws --wsapi \"db,personal,eth,net,web3,debug\" --wsorigins='*' --wsaddr=\"localhost\" --wsport 8546 console"
@voluntas
voluntas / sysctl.conf
Created October 14, 2017 13:07 — forked from techgaun/sysctl.conf
Sysctl configuration for high performance
### KERNEL TUNING ###
# Increase size of file handles and inode cache
fs.file-max = 2097152
# Do less swapping
vm.swappiness = 10
vm.dirty_ratio = 60
vm.dirty_background_ratio = 2
@vgpena
vgpena / loadModel.py
Last active November 17, 2020 16:39
Basic text classification with Keras and TensorFlow
import json
import numpy as np
import keras
import keras.preprocessing.text as kpt
from keras.preprocessing.text import Tokenizer
from keras.models import model_from_json
# we're still going to use a Tokenizer here, but we don't need to fit it
tokenizer = Tokenizer(num_words=3000)
# for human-friendly printing
@danielkcz
danielkcz / firebase.functions.js
Last active January 11, 2019 12:40
Firebase authentication with Graphcool
const functions = require('firebase-functions')
const admin = require('firebase-admin')
// This is hosted using Firebase Functions to gain easier access without meddling with service key
admin.initializeApp(functions.config().firebase)
exports.verifyToken = functions.https.onRequest((req, res) => {
const { idToken } = req.query
if (!idToken) {
@danielbierwirth
danielbierwirth / TCPTestClient.cs
Last active April 27, 2024 20:24
TCP Client-Server Connection Example | Unity | C# | Bidirectional communication sample: Client can connect to server; Client can send and receive messages: Server accepts clients; Server reads client messages; Server sends messages to client
// This work is licensed under the Creative Commons Attribution-ShareAlike 4.0 International License.
// To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/4.0/
// or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
using System;
using System.Collections;
using System.Collections.Generic;
using System.Net.Sockets;
using System.Text;
using System.Threading;
using UnityEngine;
from matplotlib import pyplot as plt
import cv2
img = cv2.imread('/Users/mustafa/test.jpg')
gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
plt.imshow(gray)
plt.title('my picture')
plt.show()