Skip to content

Latest commit

 

History

History
139 lines (105 loc) · 9.39 KB

nf-azroles-iazclientcontext-accesscheck.md

File metadata and controls

139 lines (105 loc) · 9.39 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:azroles.IAzClientContext.AccessCheck
IAzClientContext::AccessCheck (azroles.h)
Determines whether the current client context is allowed to perform the specified operations.
AccessCheck
AccessCheck method [Security]
AccessCheck method [Security]
AzClientContext object
AccessCheck method [Security]
IAzClientContext interface
AzClientContext object [Security]
AccessCheck method
IAzClientContext interface [Security]
AccessCheck method
IAzClientContext.AccessCheck
IAzClientContext::AccessCheck
azroles/IAzClientContext::AccessCheck
security.iazclientcontext_accesscheck
security\iazclientcontext_accesscheck.htm
security
0bd16cdb-3dba-4656-b264-32e622732155
12/05/2018
AccessCheck, AccessCheck method [Security], AccessCheck method [Security],AzClientContext object, AccessCheck method [Security],IAzClientContext interface, AzClientContext object [Security],AccessCheck method, IAzClientContext interface [Security],AccessCheck method, IAzClientContext.AccessCheck, IAzClientContext::AccessCheck, azroles/IAzClientContext::AccessCheck, security.iazclientcontext_accesscheck
azroles.h
Windows
Windows Vista [desktop apps only]
Windows Server 2003 [desktop apps only]
Azroles.lib
Azroles.dll
Windows
Windows Server 2003 Administration Tools Pack on Windows XP
19H1
IAzClientContext::AccessCheck
azroles/IAzClientContext::AccessCheck
c++
APIRef
kbSyntax
COM
Azroles.dll
IAzClientContext.AccessCheck
AzClientContext.AccessCheck

IAzClientContext::AccessCheck

-description

The AccessCheck method determines whether the current client context is allowed to perform the specified operations.

-parameters

-param bstrObjectName [in]

The name of the accessed object. This string is used in audits.

-param varScopeNames [in]

A variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds a VT_BSTR that contains the name of a scope that the object specified by the bstrObjectName parameter matches. The array can contain only one element. To use the default application level scope, set the first entry in the array to an empty string ("") or VT_EMPTY, or pass VT_EMPTY in to this parameter.

-param varOperations [in]

The operations for which access by the client context is checked. This is a variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds a VT_I2 or VT_I4 that represents the OperationID property of an IAzOperation object in the IAzApplication policy.

-param varParameterNames [in, optional]

The names of the parameters available to business rules (BizRules) through the AzBizRuleContext::GetParameter method. This is a variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds a VT_BSTR that contains a parameter name. This array must be sorted alphabetically by the caller; the sort order is as defined by a case-sensitive VarCmp. The order of the varParameterValues array must match the order of this array. The default value is VT_NULL.

-param varParameterValues [in, optional]

The values of the parameters that are available to business rules (BizRules) through the AzBizRuleContext::GetParameter method. This is a variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds a value that corresponds to an element in the varParameterNames array. The default value is VT_NULL. The entries in the array can hold any type except VT_UNKNOWN and VT_DISPATCH.

-param varInterfaceNames [in, optional]

The names by which the interfaces in the varInterfaces array will be known in a BizRule script. This is a variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds a string variant that contains an interface name. This method calls the IActiveScript::AddNamedItem method for each entry in the array. The default value is VT_NULL.

-param varInterfaceFlags [in, optional]

Flags that will be passed in the call to IActiveScript::AddNamedItem. This is a variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds a VT_I4. The SCRIPTITEM_ISVISIBLE flag is implied; the SCRIPTITEM_ISPERSISTENT flag is ignored. Each entry in the array must match the corresponding element in the varInterfaceNames array. The default value is VT_NULL.

-param varInterfaces [in, optional]

The IDispatch interfaces that will be made available to the BizRule script. This is a variant that contains either a SAFEARRAY or the JScript Array object. Each element of the array holds an IDispatch interface. Each entry in the array must match the corresponding element in the varInterfaceNames array. The default value is VT_NULL.

-param pvarResults [out]

A pointer to a VARIANT used to return a SAFEARRAY that contains the results of the access check. Each element of the SAFEARRAY is a VARIANT of type VT_I4. Each entry in the array matches the corresponding element in the varOperations array. If access to an operation is granted to the client context, a value of NO_ERROR is returned in the corresponding element in the pvarResults array. Any other value indicates that access to that operation is not granted. A typical value that indicates failure is ERROR_ACCESS_DENIED.

In JScript, the returned SAFEARRAY must be converted to the JScript Array object.

-returns

If the method succeeds, the method returns NO_ERROR.

If the method fails, it returns an HRESULT value that indicates the status of the method, not the result of the access check. Possible values include, but are not limited to, those in the following table. For a list of common error codes, see Common HRESULT Values.

Return code/value Description
ERROR_FILE_CORRUPT
This error code can be returned if an Active Directory authorization store is used and the administration of the scope has been delegated. The task and role definitions within a delegated scope cannot have BizRules. If a task or role definition within a delegated scope contains a BizRule (this is possible if the store is corrupted), the AccessCheck method will fail.
OLESCRIPT_E_SYNTAX
The BizRule used to evaluate access contains a syntax error.

-remarks

If the RoleForAccessCheck property is defined in the client context, the AccessCheck method will be performed only on that role.

When this method is called, the application group membership is added to the client context so that it does not need to be recomputed for subsequent access checks on the same client context.

This method cannot be called by a BizRule.