<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: 10.1.0 -",
    "tvOS: -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "SystemConfiguration",
  "identifier" : "/documentation/SystemConfiguration/SCDynamicStoreCopyDHCPInfo",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "System Configuration"
    ],
    "preciseIdentifier" : "c:@F@SCDynamicStoreCopyDHCPInfo"
  },
  "title" : "SCDynamicStoreCopyDHCPInfo"
}
-->

# SCDynamicStoreCopyDHCPInfo

Returns the DHCP information for the specified service.

```
CFDictionaryRefSCDynamicStoreCopyDHCPInfo(SCDynamicStoreRef store, CFStringRef serviceID);
```

## Parameters

`store`

The dynamic store session that should be used for communication with the server. If this is `NULL`, a temporary session is used.

`serviceID`

The service ID. Pass `NULL` to retrieve information for the primary service.

## Return Value

A dictionary containing DHCP information if successful, or `NULL` if unsuccessful. You must use the <doc://com.apple.documentation/documentation/CoreFoundation/CFRelease> function to release return values other than `NULL`.

## Discussion

Use [`DHCPInfoGetOptionData`](/documentation/SystemConfiguration/DHCPInfoGetOptionData) to extract individual options from the dictionary returned by this function.

---

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)