Skip to content

Instantly share code, notes, and snippets.

View pawlos's full-sized avatar
🐛

Paweł Łukasik pawlos

🐛
View GitHub Profile
@pawlos
pawlos / index.html
Created September 1, 2021 18:07 — forked from lbherrera/index.html
Solution for the MessageKeeper challenge from Pwn2Win 2021
<!DOCTYPE html>
<html>
<head>
<title>Pwn2Win | MessageKeeper</title>
</head>
<body>
<script>
let alphabet = "0123456789abcdef";
const sleep = (ms) => {
@pawlos
pawlos / fix vmwp.bat
Created February 16, 2021 20:37 — forked from kruxmeier/fix vmwp.bat
enable hardware performance counters in WSL2
REM open cmd.exe as admin to run this
REM Creates a patched vmwp.exe replacing these bytes:
REM 0F B6 43 64 41 89 47 64 0F B6 43 65 41 89 47 68 0F B6 43 66 41 89 47 6C 0F B6 43 67 41 89 47 70
REM 41 C7 47 64 01 00 00 00 41 C7 47 68 01 00 00 00 41 C7 47 6C 01 00 00 00 41 C7 47 70 01 00 00 00
REM Enables PMU, LBR, PEBS, IPT
cd %TEMP%
copy %windir%\system32\vmwp.exe .
@pawlos
pawlos / VCXSrv.0
Created June 13, 2020 15:43 — forked from stowler/VCXSrv.0
# It looks like -multiwindow mode triggers the static color visual in both the internal x2go xserver and the external vcxsrv
# But it also looks like -multiwindow mode is how x2go client allows resizing of the remote desktop
# ...so I'm looking for a way to allow resizing of remote desktop w/out triggering static color visual.
#
# ...output of vcxsrv.exe's usage note:
Usage...
Vcxsrv [:<display>] [option]
:display-number
@pawlos
pawlos / WADParser.py
Created March 1, 2018 18:25 — forked from jasonsperske/MIT-LICENSE
A simple Python program that can read DOOM.Hexen IWAD and PWAD files and render them as SVG see examples at http://jason.sperske.com/wad/
#!/usr/bin/env python3
import struct
import re
class Wad(object):
"""Encapsulates the data found inside a WAD file"""
def __init__(self, wadFile):
"""Each WAD files contains definitions for global attributes as well as map level attributes"""
@pawlos
pawlos / post_install.sh
Last active January 3, 2019 01:11 — forked from waleedahmad/post_install.sh
Ubuntu post installation script for installing software of your choice.
#!/bin/bash
if [[ $EUID -ne 0 ]]; then
echo "This script must be run as root"
exit 1
fi
user=$(who | awk '{print $1}')
#Update and Upgrade
echo "Updating and Upgrading"
@pawlos
pawlos / spectre.c
Created January 15, 2018 21:16 — forked from ErikAugust/spectre.c
Spectre example code
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#ifdef _MSC_VER
#include <intrin.h> /* for rdtscp and clflush */
#pragma optimize("gt",on)
#else
#include <x86intrin.h> /* for rdtscp and clflush */
#endif
<!-- 33c3ctf feuerfuchs exploit -->
<script>
var buffer;
var ua;
var vuln;
var ay = new Array(0x800);
var magic = 0x51535759;
var magic1 = 0x71737779;
function gc() {
/*************
* colors.js *
*************
*
* You're almost at the exit. You just need to get past this
* color lock.
*
* Changing your environment is no longer enough. You must
* learn to change yourself. I've sent you a little something
* that should help with that.
/****************
* drones101.js *
****************
*
* Do you remember, my dear Professor, a certain introductory
* computational rationality class you taught long ago? Assignment
* #2, behavior functions of autonomous agents? I remember that one
* fondly - but attack drones are so much easier to reason about
* when they're not staring you in the face, I would imagine!
/********************
* theLongWayOut.js *
********************
*
* Well, it looks like they're on to us. The path isn't as
* clear as I thought it'd be. But no matter - four clever
* characters should be enough to erase all their tricks.
*/
function startLevel(map) {