Swift and Objective-C
Applicability and integration
Available integrations:
SCM import
CLI and IDE: test or monitor your app
Available functions:
Test your app's SBOM using
pkg:swift
,pkg:cocoapods
Test your app's packages using
pkg:swift
,pkg:cocoapods
Technical specifications
Supported package managers and registries
For Swift and Objective-C, Snyk supports the following package managers: CocoaPods, Swift Package Manager v3.0 or higher.
As package registries, Snyk for Swift and Objective-C uses multiple sources, including cocoapods.org and swiftpackageregistry.com.
Supported frameworks and libraries
For Swift and Objective-C, the following frameworks and libraries are supported:
Swift standard library - Comprehensive
Foundation- Comprehensive
Appkit - Comprehensive
Swift UI - Comprehensive
UI Kit - Comprehensive
Asynchttpclient - Comprehensive
Commoncrypt - Comprehensive
Commoncrypto - Comprehensive
Cryptokit - Comprehensive
Cryptoswift - Comprehensive
Cryptor - Comprehensive
AlamoFire - Comprehensive
Filekit - Comprehensive
google-gemini/generative-ai-swift - Comprehensive
MacPaw/OpenAI - Comprehensive
dylanshine/openai-kit - Comprehensive
Pathos - Comprehensive
SQLite3 - Comprehensive
Webkit - Comprehensive
SwiftCLI - Comprehensive
ShellOut - Comprehensive
SwiftShell - Comprehensive
Subprocess - Comprehensive
Shout - Comprehensive
Swiftline - Comprehensive
RNCryptor - Comprehensive
Swift for Snyk Code
For Swift with Snyk Code, Snyk supports Swift versions up to 5.7.x. You can use higher versions, but Snyk does not provide support for them.
For Swift with Snyk Code, the following file formats are supported: .swift
Available features:
Reports
Interfile analysis
Swift for Snyk Open Source
For Swift with Snyk Open Source, you can use Swift 3.0 or higher.
Supported file formats
For Swift and Objective-C with Snyk Open Source, the following file formats are supported:
For CocoaPods:
podfile
,podfile.lock
,For Swift:
package.swift
For Swift and Objective-C with Snyk Open Source, Snyk provides support for package managers as follows:
For CocoaPods: CLI support, Git support, License scanning
For Swift Package Manager: CLI support
Requirements for Swift Package Manager
A Package.swift
file must be present for the Snyk CLI to discover the Project.
Snyk uses the swift package show-dependencies
command to build the dependency graph.
Swift Package Manager supports pre-processing and post-processing. For post-processing, custom commands can add extra dependencies. Detecting such dependencies is not supported.
It is not possible to scan Swift Package Manager Projects using Git import.
Cocoapods and CLI
To build the dependency graph, Snyk examines the Podfile
and Podfile.lock
files.
When working with Swift and Objective-C projects from the Snyk CLI, you can prevent testing any lock files that are out-of-sync by using the --strict-out-of-sync=true
For Cocoapods and Git, to test your Projects, Snyk analyzes the Podfile
and Podfile.lock
files.
The following summarizes support for Git import and testing.
Features
Available features:
License scanning (CocoaPods)
Reports
Last updated
Was this helpful?