Skip to content

Instantly share code, notes, and snippets.

View AhnMo's full-sized avatar
🤔
Karma

Park Jung-hwan AhnMo

🤔
Karma
View GitHub Profile
@AhnMo
AhnMo / http_client_get.cc
Last active January 27, 2026 05:47
Wininet HTTP Client Example
#include <windows.h>
#include <wininet.h>
#include <stdio.h>
#pragma comment (lib, "Wininet.lib")
int main(int argc, char *argv[]) {
HINTERNET hSession = InternetOpen(
L"Mozilla/5.0", // User-Agent
@AhnMo
AhnMo / get_internet_connected_inferface_info.cc
Created December 16, 2017 13:39
Get Internet connected Interface information - Visual C++
#include <winsock2.h>
#include <iphlpapi.h>
#include <stdio.h>
#include <stdlib.h>
#pragma comment(lib, "IPHLPAPI.lib")
#define MALLOC(x) HeapAlloc(GetProcessHeap(), 0, (x))
#define FREE(x) HeapFree(GetProcessHeap(), 0, (x))
int __cdecl main() {
@AhnMo
AhnMo / fork.c
Created December 17, 2017 14:50 — forked from Cr4sh/fork.c
fork() for Windows
/*
* fork.c
* Experimental fork() on Windows. Requires NT 6 subsystem or
* newer.
*
* Copyright (c) 2012 William Pitcock <nenolod@dereferenced.org>
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
@AhnMo
AhnMo / ex1.js
Created December 19, 2017 18:02
Fucking Javascript Closure - eval
var x = 'outter';
(function () {
var x = 'inner';
alert(eval('x'));
})();
// inner
@AhnMo
AhnMo / pattern.py
Created April 20, 2018 14:37 — forked from dev-zzo/pattern.py
pattern_create.rb in Python
#!/usr/bin/python
"""Utility functions to work with character patterns."""
__lower_alpha = 'abcdefghijklmnopqrstuvwxyz'
__upper_alpha = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
__numeric = '0123456789'
def pattern_create(length, charsets=None):
"""Generates a unique, nonrepeating pattern of a given length.
ahnmo@peterparker:~$ cat is511.py 
import socket

HOST = 'localhost'
PORT = 3000

payload = 'GET /../../../../../../../../etc/passwd HTTP/1.0\r\n\r\n'

s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
#!/usr/bin/python
from binascii import crc32
sample_str = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
target = 77236792
def check(x):
return crc32(x) == target
def crack(cur, size):
for i in sample_str:
https://developers.google.com/android/drivers#sailfishopr3.170623.013
https://manatails.net/blog/2018/06/building-userdebug-android-images-for-pixel/
https://source.android.com/setup/build/downloading
https://source.android.com/setup/build/building
https://source.android.com/setup/build/running
https://developers.google.com/android/images#sailfish
https://source.android.com/setup/start/build-numbers#source-code-tags-and-builds
#!/usr/bin/env python
import SimpleHTTPServer
import SocketServer
import logging
import sys
import os
PORT = 3000
BASE = '..'
import BaseHTTPServer, SimpleHTTPServer
PORT = 8080
class SimpleHTTPRequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):
def do_GET(self):
self.send_response(200)
self.end_headers()
self.wfile.write(b'<h1 style="text-align: center">UNDER CONSTRUCTION</h1>')