DF - Fuzz open and close test (Reliability)

This test performs thousands of create-open-close sequences and employs several different ways of opening and closing instances of the specified device or devices: Basic Open Operations, Direct Device Open Operations, and an Open and Close stress test.

Basic Open Operations

During the Basic Open Operations, the Fuzz test repeatedly opens (creates) instances of the specified devices or the devices exported by the specified driver by using different methods and options.

The Fuzz test always performs the Basic Open Operations. You do not need to select them and you cannot exclude them from a test session.

The Fuzz test performs all open operations in user mode by calling system services (ZwXxx Routines) that are appropriate to the device. If an open call returns a handle to the device, the Fuzz test uses the handle to perform the other device tests selected for the test session.

There are five types of Basic Open Operations:

  • Standard open: the Fuzz test opens the device asynchronously and specifies only the native device name.

  • Open with added backslash: the Fuzz test issues an open call for the device name followed by a backslash (), such as \device\cdrom\, as though the call were to open a root directory within the device.

    This operation determines how the driver or file system manages open requests in its namespace. In particular, if the device does not support open requests in its namespace, the driver must prevent unauthorized access, either by failing the requests, or by setting the FILE_DEVICE_SECURE_OPEN device characteristic when it calls IoCreateDevice or IoCreateDeviceSecure to create the device object.

  • Open as a named pipe: the Fuzz test opens the device and establishes a named pipe to the device. The access parameter (ShareAccess) is initially set to read and write, but is adjusted if the request fails. If the device does not support named pipes, it should fail the request.

  • Open as a mailslot: the Fuzz test opens the device as a mailslot. If the device does not support this type of connection, it should fail the request.

  • Open as a tree connection: the Fuzz test opens the device as a tree connection for use in remote network access. The access parameter (ShareAccess) is initially set to read and write, but is adjusted if the request fails. If the device does not support this type of connection, it should fail the request.

The parameters used in the open calls vary to accommodate the characteristics of the device and make it likely that the calls succeed. For example, if a basic open operation fails because the call did not meet the security requirements of the device, the Fuzz test repeats the open operation with a request for lesser access. For example, if an open operation that requested write access returns a security violation error, the open is repeated with a request for read access.

Direct Device Open Operations

During the Direct Device Open Operations, the Fuzz test opens the device directly, as a device, not as a file in a file system. Direct Device Open Operations are always synchronous. If the call is successful, the Fuzz test uses the handle provided to perform other selected tests.

Open and Close Test

During the Open and Close Test, the Fuzz test creates several threads, each of which performs thousands of create-open-close sequences. This tests the driver's ability to handle an extraordinary volume of otherwise simple and anticipated calls.

The Open and Close Test uses the same options used in Basic Open Operation and Open with Added Backslash tests and are performed just prior to these tests.

Test binary: Devfund_FuzzTest.dll Test method: DoOpenCloseTest

Test details

   
Specifications
  • Device.DevFund.Reliability.BasicReliabilityAndPerformance
  • Device.DevFund.Reliability.BasicSecurity
  • Device.DevFund.DriverFramework.KMDF.Reliability
  • Device.DevFund.DriverFramework.UMDF.Reliability
Platforms
  • Windows 10, client editions (x86)
  • Windows 10, client editions (x64)
  • Windows Server 2016 (x64)
  • Windows 10, client editions (Arm64)
  • Windows 10, mobile edition (Arm)
  • Windows 10, mobile edition (Arm64)
Supported Releases
  • Windows 10
  • Windows 10, version 1511
  • Windows 10, version 1607
  • Windows 10, version 1703
  • Windows 10, version 1709
  • Windows 10, version 1803
  • Windows 10, version 1809
  • Windows 10, version 1903
  • Next update to Windows 10
Expected run time (in minutes) 15
Category Scenario
Timeout (in minutes) 180
Requires reboot false
Requires special configuration true
Type automatic

 

Additional documentation

Tests in this feature area might have additional documentation, including prerequisites, setup, and troubleshooting information, that can be found in the following topic(s):

Running the test

Before you run the test, complete the test setup as described in the test requirements: Device.Fundamentals Reliability Testing Prerequisites.

Troubleshooting

For generic troubleshooting of HLK test failures, see Troubleshooting Windows HLK Test Failures.

For troubleshooting information specific to the Device Fundamentals tests in the HLK and WDK, see Device.DevFund additional documentation.

More information

Parameters

Parameter name Parameter description
DQ A WDTF SDEL query that is used to identify the target device(s) - https://go.microsoft.com/fwlink/?LinkId=232678
Wpa2PskAesSsid Required ONLY if DUT or one of its child devices is a WiFi adapter. Please provide SSID of a WPA2 AES WiFi network that the test can use to test the WiFi adapter. The default is 'kitstestssid'.
Wpa2PskPassword Required ONLY if DUT or one of its child devices is a WiFi adapter. Please provide password of the WPA2 AES WiFi network specified using the Wpa2PskAesSsid parameter. The default is 'password'.
ChangeBufferProtectionFlags True or False. Changes the memory protection flags of buffers passed to the tested device. The memory protection flags alternates between no access, read-only, and read-only with page guard.
Impersonate True or False. Runs the test as a non administrative user.
FillZeroPageWithNull True or False. Maps the zero page and fills it with NULL values. This test identifies drivers that do not verify a pointer reference before dereferencing a pointer.
DoPoolCheck True or False. Monitors the driver's use of the paged and nonpaged system memory pools by using pool tags and lookaside lists. This option also monitors changes in the number of exceptions handled which might indicate errors in exception handling.
DoSync True or False. Also opens device handles in SYNC mode (FILE_SYNCHRONOUS_IO_ALERT). Random read and write operations are skipped.
TestCycles Number of test cycles.
DriverVerifierAdditionalDrivers Additional drivers that should have Driver Verifier enabled
DriverVerifierExcludedFlags Placeholder for Driver Verifier flags that may be manually excluded for the test run
WDKDeviceID Device id of device under test
QueryHardwareID Hardware id of device under test
WDTFREMOTESYSTEM Required ONLY if DUT or one of its child devices is a wired NIC that doesn't have an IPv6 gateway address. If determined to be required, please provide an IPv6 address that the test NIC can ping to test network I/O. Eg: fe80::78b6:810:9c12:46cd
DriverVerifierCustomizeConfiguration Specifies that this test may want to automatically update Driver Verifier settings