---
title: "CMSDecoderCopyDetachedContent(_:_:)"
framework: security
role: symbol
role_heading: Function
path: "security/cmsdecodercopydetachedcontent(_:_:)"
---

# CMSDecoderCopyDetachedContent(_:_:)

Obtains the detached content specified with the CMSDecoderSetDetachedContent function.

## Declaration

```swift
func CMSDecoderCopyDetachedContent(_ cmsDecoder: CMSDecoder, _ detachedContentOut: UnsafeMutablePointer<CFData?>) -> OSStatus
```

## Parameters

- `cmsDecoder`: The CMSDecoder reference returned by the CMSDecoderCreate function.
- `detachedContentOut`: On return, points to the data reference specified by an earlier call to the CMSDecoderSetDetachedContent function. Returns a NULL data reference if no detached content has been specified. You must use the CFRelease function to free this reference when you are finished using it.

## Return Value

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

## See Also

### Related Documentation

- [CMSDecoderCreate(_:)](security/cmsdecodercreate(_:).md)
