Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KDT-860: Add new beta APIs for macOS 15.0+ #7

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

kp-michele-emiliani
Copy link
Collaborator

@kp-michele-emiliani kp-michele-emiliani commented Aug 16, 2024

PR to use the new APIs for macos 15.0+ versions.
Since old APIs still work on macos 15.0, I will revisit these change once 15.1 release is closer

@kp-michele-emiliani kp-michele-emiliani self-assigned this Aug 16, 2024
This is needed because GHA runners on macos13 support
up to Xcode 15, and we need v16 for the new APIs
Xcode suggested these changes. TBD if we are gonna keep them
No need to check for macos version, since NWEndpoint is
available from macos 10.14+
https://developer.apple.com/documentation/network/nwendpoint
New macos 15.0+ APIs uses Network.NWEndpoint for both
TCP remoteEndpoint (new name is remoteFlowEndpoint) and
UDP localEndpoint (new name is localFlowEndpoint).
The old APIs use a different type, which is NetworkExtension.NWEndpoint.

Network.NWEndpoint is available also on older macos versions, so we can just use that
type in our FlowTCP and FlowUDP classes, then for older versions convert from
NetworkExtension.NWEndpoint to it
@kp-michele-emiliani kp-michele-emiliani force-pushed the KDT-860-deprecated-apis-macos-15 branch from d984d5f to 7cdeb47 Compare September 23, 2024 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant