Skip to content

Latest commit

 

History

History
157 lines (128 loc) · 5.32 KB

nf-dhcpv6csdk-dhcpv6requestprefix.md

File metadata and controls

157 lines (128 loc) · 5.32 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:dhcpv6csdk.Dhcpv6RequestPrefix
Dhcpv6RequestPrefix function (dhcpv6csdk.h)
Requests a specific prefix.
Dhcpv6RequestPrefix
Dhcpv6RequestPrefix function [DHCP]
dhcp.dhcpv6requestprefix
dhcpv6csdk/Dhcpv6RequestPrefix
dhcp\dhcpv6requestprefix.htm
DHCP
60f18e54-a0a4-4fbe-a416-16b924ce4616
12/05/2018
Dhcpv6RequestPrefix, Dhcpv6RequestPrefix function [DHCP], dhcp.dhcpv6requestprefix, dhcpv6csdk/Dhcpv6RequestPrefix
dhcpv6csdk.h
Windows
Windows Vista [desktop apps only]
Windows Server 2008 [desktop apps only]
Dhcpcsvc6.lib
Dhcpcsvc6.dll
Windows
19H1
Dhcpv6RequestPrefix
dhcpv6csdk/Dhcpv6RequestPrefix
c++
APIRef
kbSyntax
DllExport
Dhcpcsvc6.dll
Dhcpv6RequestPrefix

Dhcpv6RequestPrefix function

-description

The Dhcpv6RequestPrefix function requests a specific prefix.

-parameters

-param adapterName [in]

GUID of the adapter on which the prefix request must be sent.

-param pclassId [in]

Pointer to a DHCPV6CAPI_CLASSID structure that contains the binary ClassId information to send on the wire. This parameter is optional.

Note  DHCPv6 Option Code 15 (0x000F) is not supported by this API. Typically, the User Class option is used by a client to identify the type or category of user or application it represents. A server selects the configuration information for the client based on the classes identified in this option.
 

-param prefixleaseInfo [in, out]

Pointer to a DHCPV6PrefixLeaseInformation structure that contains the prefix lease information.

The following members of the DHCPV6PrefixLeaseInformation structure must follow these guidelines.

DHCPV6PrefixLeaseInformation member Consideration
nPrefixes Must contain a maximum value of 10. The caller should have the memory allocated in the prefixArray member based on the number of prefixes specified.
iaid A unique positive number assigned to this member. This same value should be reused if this function is called again.This mandatory value must be set by the calling application.
ServerIdLen Must contain a maximum value of 128. The caller must have the memory allocated in the ServerId member based on the specified ServerIdLen value.
 

The caller must follow these considerations when assigning the values of the nPrefixes, iaid, and ServerIdLen members of the DHCPV6PrefixLeaseInformation structure. Based on these values, memory must also be properly allocated to the ServerId and PrefixArray members before the Dhcpv6RequestPrefix function is called.

-param pdwTimeToWait [out]

Contains the number of seconds a requesting application needs to wait before calling the Dhcpv6RenewPrefix function to renew its acquired prefixes. A value of 0xFFFFFFFF indicates that the application does not need to renew its lease.

-returns

Returns ERROR_SUCCESS upon successful completion.

Return code Description
ERROR_MORE_DATA
The value of the nPrefixes or the ServerIdLen member specified is less than the number of prefixes available from the server or the available server ID length. Increase the nPrefixes or the ServerIdLen member and make sure the corresponding memory has been allocated properly before calling the Dhcpv6RequestPrefix function again.
ERROR_INVALID_PARAMETER
Returned if one of the following conditions are true:
  • AdapterName is NULL. Or no adapter is found with the GUID specified.
  • prefixleaseInfo is NULL.
  • pdwTimeToWait is NULL.
  • The iaid member of the prefixleaseInfo is zero.
ERROR_INVALID_NAME
The AdapterName is not in the correct format. It should be in this format: {00000000-0000-0000-0000-000000000000}.