For excessively paranoid client authentication.
Updated Apr 5 2019:
because this is a gist from 2011 that people stumble into and maybe you should AES instead of 3DES in the year of our lord 2019.
some other notes:
#!/usr/bin/ruby | |
# This code is to demonstrate these very important things to remember about Ruby: | |
# | |
# 1. Classes are also Objects in Ruby. | |
# 2. Every Object in Ruby has its own Singleton Class (or "Meta Class" or "Eigen | |
# Class" | |
# 3. In other languages you may be familiar with the idea that each Object | |
# Instance is unique, but in Ruby, each Object Instance has its own unique | |
# Class definition, unique to JUST THAT instance. This is called the Object's | |
# singleton class. |
require 'rubygems' | |
require 'wirble' | |
require 'irb/completion' | |
require 'pp' | |
IRB.conf[:AUTO_INDENT] = true | |
Wirble.init | |
Wirble.colorize | |
class Object | |
# get all the methods for an object that aren't basic methods from Object |
cribbed from http://pastebin.com/xgzeAmBn
Templates to remind you of the options and formatting for the different types of objects you might want to document using YARD.
# open file handles | |
ObjectSpace.each_object(File) {|o| puts o.inspect} | |
# finding all the active Exceptions which one might have to catch in metasploit | |
# start msfconsole, proceed to the environment you want to examine, for instance if | |
# you want to see what exceptions are available in a meterp session, then establish | |
# one, interace with it, and then... | |
# run the irb command and enter the following | |
ObjectSpace.each_object(Class) {|o| puts o.inspect if o.ancestors.include?(Exception)} |
## | |
# This file is part of the Metasploit Framework and may be subject to | |
# redistribution and commercial restrictions. Please see the Metasploit | |
# web site for more information on licensing and terms of use. | |
# http://metasploit.com/ | |
## | |
require 'msf/core' | |
class Metasploit3 < Msf::Exploit::Remote |
Key-Type: 1 | |
Key-Length: 2048 | |
Subkey-Type: 1 | |
Subkey-Length: 2048 | |
Name-Real: Root Superuser | |
Name-Email: root@handbook.westarete.com | |
Expire-Date: 0 |
try `ctypes.jsm ExtractIconEx` it doesnt return anything | |
then try `ctypes.jsm ExtractIconExW` it returns one entry, this should have been returned on try on line above |
I just found this API ridiculously confusing to use, and maybe I just suck, but I don't want to figure it out again, so I'm writing it down here
Optional, but if you have an established gpg home dir that you want to use or you don't want it chosen for you
GPGME::Engine.home_dir = "/some/dir" # e.g. env['GNUPG_HOME']
import requests | |
import sys | |
import json | |
def waybackurls(host, with_subs): | |
if with_subs: | |
url = 'http://web.archive.org/cdx/search/cdx?url=*.%s/*&output=json&fl=original&collapse=urlkey' % host | |
else: | |
url = 'http://web.archive.org/cdx/search/cdx?url=%s/*&output=json&fl=original&collapse=urlkey' % host |