Skip to content

Instantly share code, notes, and snippets.

View blaquee's full-sized avatar

genuine_ blaquee

View GitHub Profile
@blaquee
blaquee / README.md
Created April 22, 2014 01:58 — forked from ah8r/README.md

Cardiac Arrest

Hut3 Cardiac Arrest - A script to check OpenSSL servers for the Heartbleed bug (CVE-2014-0160).

Note: This code was originally a GitHub Gist but has been copied to a full GitHub Repository so issues can also be tracked. Both will be kept updated with the latest code revisions.

DISCLAIMER: There have been unconfirmed reports that this script can render HP iLO unresponsive. This script complies with the TLS specification, so responsitivity issues are likely the result of a bad implementation of TLS on the server side. CNS Hut3 and Adrian Hayter do not accept responsibility if this script crashes a server you test it against. USE IT AT YOUR OWN RISK. As always, the correct way to test for the vulnerability is to check the version of OpenSSL installed on the server in question. OpenSSL 1.0.1 through 1.0.1f are vulnerable.

This script has several advantages over similar scripts that have been re

00415000 > $ 90 nop
00415001 . 90 nop
00415002 . 68 B142B600 push 0B642B1
00415007 . 5B pop ebx
00415008 . 90 nop
00415009 . BA 20504100 mov edx, 00415020
0041500E . 90 nop
0041500F . 90 nop
00415010 . BF 98050000 mov edi, 598
00415015 . 90 nop
@blaquee
blaquee / pipes
Last active August 29, 2015 14:08
c pipes
int open_pipe(int *readpipe, int *writepipe)
{
int fdpipe[2]; // read, write
#if defined(WIN32) || defined(_WIN32)
int r = pipe( fdpipe, BUFFER_SIZE, O_BINARY );
#else
int r = pipe(fdpipe);
#endif
*readpipe = fdpipe[0];
*writepipe = fdpipe[1];

Keybase proof

I hereby claim:

  • I am blaquee on github.
  • I am g3nuin3 (https://keybase.io/g3nuin3) on keybase.
  • I have a public key whose fingerprint is ADB4 BE35 7968 3F89 1B47 610F 841E C906 2AB6 E77E

To claim this, I am signing this object:

#undef UNICODE
#include <Windows.h>
#pragma comment(linker, "/INCLUDE:__tls_used")
void NTAPI TlsCallBack(PVOID h, DWORD dwReason, PVOID pv);
#pragma data_seg(".CRT$XLB")
PIMAGE_TLS_CALLBACK p_thread_callback = TlsCallBack;
#pragma data_seg()
@blaquee
blaquee / piserver
Created January 16, 2015 03:13
cherrypi server
import web
from web.wsgiserver import CherryPyWSGIServer
CherryPyWSGIServer.ssl_certificate = "/ssl/server.crt"
CherryPyWSGIServer.ssl_private_key = "/ssl/server.key"
urls = ("/secrets/.*", 'secrets')
app = web.application(urls, globals())
class hello:
004013FE |. 890424 MOV DWORD PTR SS:[LOCAL.271],EAX ; /string => OFFSET LOCAL.264
00401401 |. E8 EE060000 CALL <JMP.&msvcrt.strlen> ; \MSVCRT.strlen
00401406 |. 83F8 06 CMP EAX,6
00401409 |. 74 64 JE SHORT 0040146F
.text:00401CC1 push 24h
.text:00401CC3 call sub_401980
.text:00401CC8 mov eax, dword_413D1C
.text:00401CCD mov ecx, [eax+90h]
.text:00401CD3 push ecx
.text:00401CD4 push esi
.text:00401CD5 call get_embedded_exe
.text:00401CDA add esp, 0Ch
.text:00401CDD test eax, eax
.text:00401CDF jz short loc_401CF6
@blaquee
blaquee / crackme.cpp
Created February 10, 2015 02:49
crackme1
#include <Windows.h>
#include <strsafe.h>
#include <Shlobj.h>
#include <string.h>
//the exported function
typedef void(__cdecl* display_message)(void);
//this can change
#define DLL_NAME L"\\display.dll"
dc:14:de:8e:d7:c1:15:43:23:82:25:81:d2:59:e8:c0 245272
32:f9:38:a2:39:d0:c5:f5:ba:bd:b7:75:2b:00:f6:ab 197846
d0:db:8a:cb:74:c8:37:e4:9e:71:fc:7a:eb:d6:40:81 152046
34:47:0f:e9:1a:c2:eb:56:eb:cc:58:59:3a:02:80:b6 140777
df:17:d6:57:7a:37:00:7a:87:5e:4e:ed:2f:a3:d5:dd 91904
81:96:a6:8c:3a:75:f3:be:84:5e:cc:99:a7:ab:3e:d9 80499
7c:a8:25:21:13:a2:eb:00:a6:c1:76:ca:6b:48:6e:bf 78172
1c:1e:29:43:d2:0c:c1:75:40:05:30:03:d4:02:d7:9b 71851
8b:75:88:08:41:78:11:5b:49:68:11:42:64:12:6d:49 70786
c2:77:c8:c5:72:17:e2:5b:4f:a2:4e:e3:04:0c:35:c9 68654