Author: dchapyshev
Date: Fri Jun 19 12:22:24 2009
New Revision: 41465
URL:
http://svn.reactos.org/svn/reactos?rev=41465&view=rev
Log:
- Check buffer length for
ProcessQuotaLimits/ProcessBasePriority/ProcessRaisePriority/ProcessWx86Information/ProcessDebugPort
cases
Modified:
trunk/reactos/ntoskrnl/ps/query.c
Modified: trunk/reactos/ntoskrnl/ps/query.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ps/query.c?rev=41…
==============================================================================
--- trunk/reactos/ntoskrnl/ps/query.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/ps/query.c [iso-8859-1] Fri Jun 19 12:22:24 2009
@@ -1057,10 +1057,72 @@
Status = STATUS_SUCCESS;
break;
+ case ProcessQuotaLimits:
+
+ /* Check buffer length */
+ if (ProcessInformationLength != sizeof(QUOTA_LIMITS))
+ {
+ Status = STATUS_INFO_LENGTH_MISMATCH;
+ break;
+ }
+
+ DPRINT1("Not implemented: ProcessQuotaLimits\n");
+ Status = STATUS_NOT_IMPLEMENTED;
+ break;
+
+ case ProcessBasePriority:
+
+ /* Check buffer length */
+ if (ProcessInformationLength != sizeof(KPRIORITY))
+ {
+ Status = STATUS_INFO_LENGTH_MISMATCH;
+ break;
+ }
+
+ DPRINT1("Not implemented: ProcessBasePriority\n");
+ Status = STATUS_NOT_IMPLEMENTED;
+ break;
+
+ case ProcessRaisePriority:
+
+ /* Check buffer length */
+ if (ProcessInformationLength != sizeof(ULONG))
+ {
+ Status = STATUS_INFO_LENGTH_MISMATCH;
+ break;
+ }
+
+ DPRINT1("Not implemented: ProcessRaisePriority\n");
+ Status = STATUS_NOT_IMPLEMENTED;
+ break;
+
+ case ProcessWx86Information:
+
+ /* Check buffer length */
+ if (ProcessInformationLength != sizeof(HANDLE))
+ {
+ Status = STATUS_INFO_LENGTH_MISMATCH;
+ break;
+ }
+
+ DPRINT1("Not implemented: ProcessWx86Information\n");
+ Status = STATUS_NOT_IMPLEMENTED;
+ break;
+
+ case ProcessDebugPort:
+
+ /* Check buffer length */
+ if (ProcessInformationLength != sizeof(HANDLE))
+ {
+ Status = STATUS_INFO_LENGTH_MISMATCH;
+ break;
+ }
+
+ DPRINT1("Not implemented: ProcessDebugPort\n");
+ Status = STATUS_NOT_IMPLEMENTED;
+ break;
+
/* We currently don't implement any of these */
- case ProcessQuotaLimits:
- case ProcessBasePriority:
- case ProcessRaisePriority:
case ProcessLdtInformation:
case ProcessLdtSize:
case ProcessIoPortHandlers:
@@ -1077,10 +1139,8 @@
case ProcessIoCounters:
case ProcessTimes:
case ProcessPooledUsageAndLimits:
- case ProcessWx86Information:
case ProcessHandleCount:
case ProcessWow64Information:
- case ProcessDebugPort:
default:
DPRINT1("Unsupported or unimplemented: %lx\n",
ProcessInformationClass);
Status = STATUS_INVALID_INFO_CLASS;