<!--
{
  "availability" : [
    "iOS: 7.0.0 -",
    "iPadOS: 7.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.9.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "GSS",
  "identifier" : "/documentation/GSS/GSSCredentialCopyUUID(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "GSS"
    ],
    "preciseIdentifier" : "c:@F@GSSCredentialCopyUUID"
  },
  "title" : "GSSCredentialCopyUUID(_:)"
}
-->

# GSSCredentialCopyUUID(_:)

Returns a copy of the universally unique identifier corresponding to a GSS credential.

```
func GSSCredentialCopyUUID(_ credential: gss_cred_id_t) -> Unmanaged<CFUUID>?
```

## Parameters

`credential`

The credential whose unique identifier you want.

## Return Value

A `CFUUID` object that corresponds to the given credential. Use `CFRelease` to free this object’s memory when you are done with it.

## Discussion

When you want to restore the credential from the `CFUUID`, use [`GSSCreateCredentialFromUUID(_:)`](/documentation/GSS/GSSCreateCredentialFromUUID(_:)).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)