VerifierIoWMIRegistrationControl

INT64 __stdcall VerifierIoWMIRegistrationControl(_DEVICE_OBJECT *DeviceObject, UINT64 Action){
  int v2; 
  CHAR *v4; 
  __int128 v6; 
  VOID *retaddr; 
  v2 = Action;
  if( !VfSafeMode && (Action & 0x80000000) != 0i64 )
  {
    switch( Action & 0x7FFFFFFF )
    {
      case 1ui64:
LABEL_7:
        ViTargetWMIRegister(DeviceObject, retaddr);
        break;
      case 2ui64:
        ViTargetWMIDeregister(DeviceObject, retaddr);
        break;
      case 3ui64:
        ViTargetWMIDeregister(DeviceObject, retaddr);
        goto LABEL_7;
    }
  }
  v6 = 0i64;
  if( (MmVerifierData & 0x10) != 0 && v2 >= 0 )
  {
    VfAvlInitializeLockContext((INT64)&v6, 1i64);
    v4 = VfAvlLookupTreeNode(&ViDevObjAvl, (INT64)&v6, (UINT64)DeviceObject, 0i64);
    if( v4 )
    {
      switch( v2 )
      {
        case 1:
          goto LABEL_14;
        case 2:
          _InterlockedAnd((volatile signed __int32 *)v4 + 4, 0xFFFFFFFE);
          break;
        case 3:
LABEL_14:
          _InterlockedOr((volatile signed __int32 *)v4 + 4, 1u);
          break;
      }
    }
    VfAvlCleanupLockContext((INT64)&v6);
  }
  return((__int64(__fastcall *)(_DEVICE_OBJECT *, _QWORD))pXdvIoWMIRegistrationControl)(
           DeviceObject,
           (unsigned int)v2);
}

Referenced by:

No references.