SubnetMask Property for IP Addresses

The SubnetMask property describes the subnet mask to be applied for routing for the IP address.

Quick Info

Type: Null-terminated Unicode string
Access: Read/write
Status: Required
Function: ClusterResourceControl
Structure: CLUSPROP_SZ
Control Code: CLUSCTL_RESOURCE_GET_PRIVATE_PROPERTIES

Remarks

The data in the SubnetMask property must be formatted as xxx.xxx.xxx.xxx where xxx represents a decimal number between 0 and 255. The value 255.255.255.255 is not valid.

When ClusterResourceControl processes the CLUSCTL_RESOURCE_GET_PRIVATE_PROPERTIES control code, it returns a property list that includes the SubnetMask property as one of the entries. The property value portion of the entry contains a CLUSPROP_SZ structure that is set as follows:

CLUSPROP_SZ SubnetMaskValue;
LPCWSTR SubnetMaskData = L "122.232.561.478";
SubnetMaskValue.Syntax = CLUSPROP_SYNTAX_LIST_VALUE_SZ;
SubnetMaskValue.cbLength = sizeof(SubnetMaskData);
lstrcpyW(SubnetMaskValue.sz, SubnetMaskData);