Share via


IInternetHostSecurityManager::ProcessUrlAction method

Gets the policy associated with the URL action in the specified context.

Syntax

HRESULT ProcessUrlAction(
  [in]  DWORD dwAction,
  [out] BYTE  *pPolicy,
  [in]  DWORD cbPolicy,
  [in]  BYTE  *pContext,
  [in]  DWORD cbContext,
  [in]  DWORD dwFlags,
  [in]  DWORD dwReserved
);

Parameters

  • dwAction [in]
    An unsigned long integer value that specifies the action to process. This can be one of the URL Action Flags values.

  • pPolicy [out]
    A pointer to the output buffer to store the policy. Because all URLPOLICY_* values are DWORD values, the buffer should be greater than or equal to the size of a DWORD. This can contain one of the URL Policy Flags values.

  • cbPolicy [in]
    A unsigned long integer value that specifies the size of the output buffer.

  • pContext [in]
    A pointer to a buffer that contains the context information used by the delegation routines.

  • cbContext [in]
    An unsigned long integer value that specifies the size of the context information buffer.

  • dwFlags [in]
    Unsigned long integer value that contains the flags controlling this method. This can be one of the PUAF values.

  • dwReserved [in]
    Reserved. Must be set to 0.

Return value

Returns one of the following values.

Return code Description
S_OK

Success. The URL policy is URLPOLICY_ALLOW.

S_FALSE

Found a valid URL policy that is not URLPOLICY_ALLOW.

E_OUTOFMEMORY

There is not enough memory to complete the operation.

 

Remarks

The method can also return an HRESULT derived from the Microsoft Win32 error code ERROR_NOT_FOUND to indicate that the URL action cannot be read from the registry.

Security Warning: Incorrect use of this method can compromise the security of your application. When your component receives a return value indicating S_FALSE or any error, assume that the URL action is not allowed under the current policy. If your component performs an action after receiving an error, users might be at risk of an elevation of privilege attack. Review Security Considerations: URL Security Zones API before you continue.

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows 2000 Server

DLL

Urlmon.dll

See also

IInternetHostSecurityManager