IoCreateUnprotectedSymbolicLink function

The IoCreateUnprotectedSymbolicLink routine sets up an unprotected symbolic link between a device object name and a corresponding Win32-visible name.

Syntax

NTSTATUS IoCreateUnprotectedSymbolicLink(
  PUNICODE_STRING SymbolicLinkName,
  PUNICODE_STRING DeviceName
);

Parameters

SymbolicLinkName

Supplies the symbolic link name as a Unicode string.

DeviceName

Supplies the name of the device object to which the symbolic link name refers.

Return Value

IoCreateUnprotectedSymbolicLink returns the final status of the operation.

Remarks

WDM drivers do not name device objects and therefore should not use this routine. Instead, a WDM driver should call IoRegisterDeviceInterface to set up a symbolic link.

IoCreateUnprotectedSymbolicLink can be used by drivers if the user needs to be able to manipulate the symbolic link. For example, the parallel and serial drivers create unprotected symbolic links for LPTx and COMx, so that users can manipulate and reassign them by using the MODE command.

In general, drivers should call this routine instead of IoCreateSymbolicLink if a protected subsystem lets end users change what a named device references as, for example, when using LPT1 to access a network printer.

For more information about when to use IoCreateSymbolicLink, see Named Device Objects.

Requirements

   
Minimum supported client Available starting with Windows 2000.
Target Platform Universal
Header wdm.h (include Wdm.h, Ntddk.h, Ntifs.h)
Library NtosKrnl.lib
DLL NtosKrnl.exe
IRQL PASSIVE_LEVEL
DDI compliance rules IrqlIoPassive4, PowerIrpDDis, HwStorPortProhibitedDDIs

See Also

IoAssignArcName

IoCreateSymbolicLink

IoDeleteSymbolicLink

IoRegisterDeviceInterface