---
title: "SecTrustEvaluateAsync(_:_:_:)"
framework: security
role: symbol
role_heading: Function
path: "security/sectrustevaluateasync(_:_:_:)"
---

# SecTrustEvaluateAsync(_:_:_:)

Evaluates a trust object asynchronously on the specified dispatch queue.

## Declaration

```swift
func SecTrustEvaluateAsync(_ trust: SecTrust, _ queue: dispatch_queue_t?, _ result: @escaping SecTrustCallback) -> OSStatus
```

## Parameters

- `trust`: The trust management object to evaluate. A trust management object includes the certificate to be verified plus the policy or policies to be used in evaluating trust. It can optionally also include other certificates to be used in verifying the first certificate. Use the doc://com.apple.security/documentation/Security/SecTrustCreateWithCertificates(_:_:_:) function to create a trust management object.
- `queue`: The dispatch queue on which the result block should execute.
- `result`: A block called with the result of evaluation. See doc://com.apple.security/documentation/Security/SecTrustResultType for descriptions of possible values.

## Return Value

Return Value A result code. See Security Framework Result Codes.

## Discussion

Discussion This function is functionally equivalent to SecTrustEvaluate(_:_:) except that it performs evaluation asynchronously and calls a block when evaluation completes. For a detailed discussion of the evaluation process, see SecTrustEvaluate(_:_:).
