AuthorizationCopyInfo

Function AuthorizationCopyInfo 

Source
pub unsafe extern "C-unwind" fn AuthorizationCopyInfo(
    authorization: AuthorizationRef,
    tag: AuthorizationString,
    info: NonNull<*mut AuthorizationItemSet>,
) -> i32
Available on crate feature Authorization only.
Expand description

Returns sideband information (e.g. access credentials) obtained from a call to AuthorizationCreate. The format of this data depends of the tag specified.

Parameter authorization: (input) The authorization object on which this operation is performed.

Parameter tag: (input/optional) An optional string tag specifing which sideband information should be returned. When NULL is specified all available information is returned.

Parameter info: (output) A pointer to a newly allocated AuthorizationInfoSet in which the requested sideband infomation is returned (info should be deallocated by calling AuthorizationFreeItemSet() when it is no longer needed).

Returns: errAuthorizationSuccess 0 No error.

errAuthorizationInvalidRef -60002 The authorization parameter is invalid.

errAuthorizationInvalidTag -60003 The tag parameter is invalid.

errAuthorizationInvalidPointer -60004 The info parameter is invalid.

ยงSafety

  • authorization must be a valid pointer.
  • tag must be a valid pointer or null.
  • info must be a valid pointer.