FWPM_FILTER_ENUM_TEMPLATE0 structure (fwpmtypes.h)

The FWPM_FILTER_ENUM_TEMPLATE0 structure is used for enumerating filters.

Syntax

typedef struct FWPM_FILTER_ENUM_TEMPLATE0_ {
  GUID                                 *providerKey;
  GUID                                 layerKey;
  FWP_FILTER_ENUM_TYPE                 enumType;
  UINT32                               flags;
  FWPM_PROVIDER_CONTEXT_ENUM_TEMPLATE0 *providerContextTemplate;
  UINT32                               numFilterConditions;
  FWPM_FILTER_CONDITION0               *filterCondition;
  UINT32                               actionMask;
  GUID                                 *calloutKey;
} FWPM_FILTER_ENUM_TEMPLATE0;

Members

providerKey

Uniquely identifies the provider associated with this filter.

layerKey

Layer whose fields are to be enumerated.

enumType

A FWP_FILTER_ENUM_TYPE value that determines how the filter conditions are interpreted.

flags

Value Meaning
**FWP_FILTER_ENUM_FLAG_BEST_TERMINATING_MATCH **
Only return the terminating filter with the highest weight.
**FWP_FILTER_ENUM_FLAG_SORTED**
Return all matching filters sorted by weight (highest to lowest).
**FWP_FILTER_ENUM_FLAG_BOOTTIME_ONLY**
Return only boot-time filters.
**FWP_FILTER_ENUM_FLAG_INCLUDE_BOOTTIME**
Include boot-time filters; ignored if the **FWP_FILTER_ENUM_FLAG_BOOTTIME_ONLY** flag is set.
**FWP_FILTER_ENUM_FLAG_INCLUDE_DISABLED**
Include disabled filters; ignored if the **FWP_FILTER_ENUM_FLAG_BOOTTIME_ONLY** flag is set.

providerContextTemplate

A FWPM_PROVIDER_CONTEXT_ENUM_TEMPLATE0 structure that is used to limit the number of filters enumerated. If non-NULL, only enumerate filters whose provider context matches the template.

numFilterConditions

Number of filter conditions. If zero, then all filters match.

filterCondition

An array of FWPM_FILTER_CONDITION0 structures that contain distinct filter conditions (duplicated filter conditions will generate an error).

actionMask

Only filters whose action type contains at least one of the bits in actionMask will be returned. Using the FWP_ACTION_ constants directly may not work as intended since they contain multiple bits. Some common examples are in the table below (^ represents the logical XOR operator).

Value Meaning
FWP_ACTION_BLOCK ^ FWP_ACTION_FLAG_TERMINATING
Enumerate filters that have an **FWP_ACTION_BLOCK** action.
FWP_ACTION_PERMIT ^ FWP_ACTION_FLAG_TERMINATING
Enumerate filters that have an **FWP_ACTION_PERMIT** action.
**FWP_ACTION_FLAG_CALLOUT**
Enumerate filters that reference callout drivers.
**Note**  **calloutKey** must not be **NULL**.
 
0xFFFFFFFF
Ignore the filter's action type when enumerating.

calloutKey

Uniquely identifies the callout.

Remarks

FWPM_FILTER_ENUM_TEMPLATE0 is a specific implementation of FWPM_FILTER_ENUM_TEMPLATE. See WFP Version-Independent Names and Targeting Specific Versions of Windows for more information.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2008 [desktop apps only]
Header fwpmtypes.h

See also

FWPM_FILTER_CONDITION0

FWPM_PROVIDER_CONTEXT_ENUM_TEMPLATE0

FWP_FILTER_ENUM_TYPE

Windows Filtering Platform API Structures