Skip to content

Instantly share code, notes, and snippets.

View claudijd's full-sized avatar
🦬

Jonathan Claudius claudijd

🦬
View GitHub Profile
import random
emails = []
sample_size = 20
with open("emails.txt") as f:
for line in f:
emails.append(line)
for email in random.sample(emails, 20):
@claudijd
claudijd / amqp lambda
Created October 26, 2018 01:14
amqp "lambda"
require "bunny"
# Start a communication session with RabbitMQ
conn = Bunny.new
conn.start
# open a channel
ch = conn.create_channel
# declare a queue
@claudijd
claudijd / agent.rb
Created October 26, 2018 01:13
amqp agent
require "bunny"
# Start a communication session with RabbitMQ
conn = Bunny.new
conn.start
ch = conn.create_channel
q = ch.queue("test1")
loop do
@claudijd
claudijd / cloudformation-template-create-stack.json
Created September 26, 2018 21:36
cloudformation-template-create-stack.json
{
"AWSTemplateFormatVersion": "2010-09-09",
"Description": "The AWS CloudFormation template for this Serverless application",
"Resources": {
"ServerlessDeploymentBucket": {
"Type": "AWS::S3::Bucket"
}
},
"Outputs": {
"ServerlessDeploymentBucketName": {
@claudijd
claudijd / result.txt
Created September 17, 2018 15:11
Example SSH scan result...
(master) $ curl -i https://sshscan.rubidus.com/api/v1/scan/results?uuid=d46c613f-a7b1-429e-92e4-2bdb1aa858e6
HTTP/1.1 200 OK
Server: nginx/1.10.0 (Ubuntu)
Date: Mon, 17 Sep 2018 15:10:29 GMT
Content-Type: application/json
Content-Length: 1640
Connection: keep-alive
Access-Control-Allow-Methods: GET, POST, OPTIONS, HEAD
Access-Control-Allow-Origin: *
Access-Control-Max-Age: 86400
@claudijd
claudijd / gist:7d3f32e0e01a6ddd4e7284ac2abb651b
Created August 16, 2018 22:46
NPM Sec Warnings on Install....
WARN notice [SECURITY] atob has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=atob&version=2.0.3 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
WARN notice [SECURITY] tough-cookie has the following vulnerabilities: 1 high, 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=tough-cookie&version=0.9.15 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
WARN notice [SECURITY] request has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=request&version=2.29.0 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
WARN notice [SECURITY] hawk has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=hawk&version=1.0.0 - Run `npm i npm@latest -g` to upgrade your npm version, and t
@claudijd
claudijd / bmo_query_example.py
Created March 13, 2018 14:46
Example of using BMO to query fixed bugs in a product
#!/usr/bin/env python
from __future__ import print_function
import time
import bugzilla
import sys
if sys.version_info[0] >= 3:
api_key = input("Enter Bugzilla API Key: ")
@claudijd
claudijd / protocol.rb
Created March 2, 2018 05:29
A quick example of Nagios NRPE v2 protocol object reading/writing using bindata
require 'bindata'
require 'zlib'
# Extend string class to make it easier to work with hexified binary strings
class String
def unhexify
[self].pack("H*")
end
def hexify
@claudijd
claudijd / shim.py
Last active February 13, 2018 19:45
A work in progress shim to play around with credential generation and auth bits
# A testing harness/shim for playing around with taskcluster authentication
import yaml
import taskcluster
import requests
import json
import datetime
#Example config.yaml
# clientId: INSERT_CLIENT_ID
@claudijd
claudijd / sync_fork_with_r7.rb
Created September 10, 2012 03:52
Syncing my metasploit-framework fork with upstream-master
#Just a simple script to sync master with upstream-master
#Set rapid7 as remote upstream
puts "[+] Setting Rapid7 as upstream remote"
`git remote add upstream git://github.com/rapid7/metasploit-framework.git`
#Get all the upstream changes
puts "[+] Grabbing upstream remote changes"
`git fetch upstream`