Skip to content

Instantly share code, notes, and snippets.

@kawaii-ghost
Last active May 3, 2023 03:57
Show Gist options
  • Save kawaii-ghost/e38889b1ded26d0620ea0051521d43fb to your computer and use it in GitHub Desktop.
Save kawaii-ghost/e38889b1ded26d0620ea0051521d43fb to your computer and use it in GitHub Desktop.
#include <windows.h>
int main(void)
{
// I don't realize this lmao until i see KernelBase.dll
WriteFile(UlongToHandle(STD_OUTPUT_HANDLE), "Hello, world!\n", 14, NULL, NULL);
/*
* NtWriteFile(NtCurrentPeb()->ProcessParameter->StandardOutput,
* NULL,
* NULL,
* NULL,
* &IoStatusBlock,
* "Hello, world!",
* 14,
* NULL,
* NULL);
*/
ExitProcess(0);
// RtlExitUserProcess(0);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment