<!--
{
  "availability" : [
    "macCatalyst: 13.0.0 -",
    "macOS: 10.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Security",
  "identifier" : "/documentation/Security/kSecCodeInfoMainExecutable",
  "metadataVersion" : "0.1.0",
  "role" : "Global Variable",
  "symbol" : {
    "kind" : "Global Variable",
    "modules" : [
      "Security"
    ],
    "preciseIdentifier" : "c:@kSecCodeInfoMainExecutable"
  },
  "title" : "kSecCodeInfoMainExecutable"
}
-->

# kSecCodeInfoMainExecutable

A key whose value is a URL locating the main executable file of the code.

```
let kSecCodeInfoMainExecutable: CFString
```

## Discussion

The value is a <doc://com.apple.documentation/documentation/CoreFoundation/CFURL> object. For single files, the URL locates the file itself. For bundles, it locates the main executable as identified by the bundle’s `Info.plist` file.

This is generic information returned regardless of which [Code Signing Information Flags](/documentation/Security/code-signing-information-flags) you pass to the [`SecCodeCopySigningInformation(_:_:_:)`](/documentation/Security/SecCodeCopySigningInformation(_:_:_:)) 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)