UDP network privacy for command-line apps?

In regards to answer to this question:
https://developer.apple.com/forums/thread/660472

How do the new network privacy permissions apply to command-line apps that send and listen for UDP replies?

I have 2 macOS command-line binaries that listen for a UDP reply to a UDP broadcast. They have identical file names but are in different directories. One binary broadcasts and receives a UDP reply, but the newer binary does not.

The System Preferences : Security & Privacy : Firewall : Firewall options... pane shows all the instances of the command-line binary, all with "Allow incoming connections" set to green bubble (true?).

Is there some other network privacy setting that affects UDP I/O, and is it possible to determine if that current network privacy permission settings for the two binaries are the same or different?

Added: It appears that the iOS Simulator also shows this difference in behavior between iOS apps compiled and run with Xcode 11.0 on old versions of Catalina vs. with Xcode 12.0 on newly updated Catalina. Old works. New does not.

How do the new network privacy permissions apply to command-line apps
that send and listen for UDP replies?

Local network privacy is an iOS feature and iOS does not support third-party command-line tools.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
iOS does support embedding the source code of a command line tool within an apps Xcode project and compiling the tool as part of the app build.
By simply changing the name of main() and putting a prototype of the new munged main's name into the bridging header so it can be called from Swift. And redirecting stdout (etc.) to, say, a global C string buffer, where Swift can unsafely peek and poke.

So this first-party UDP broadcast command-line tool most certainly did run inside my iOS app 4 months ago. And received UDP replies. But no longer does after updating iOS and Xcode.

What changed? (not the source code of the embedded command-line tool (except for the ending print statements).

And the same thing happed to the UDP tool running on the last Catalina update.

And the same thing happed to the UDP tool running on the last Catalina
update.

So that means that your code is failing on macOS as well? If so, that clearly has nothing to do with local network privacy.

I think you should open a DTS tech support incident for this so that I can look at your code in detail. Clearly something weird is going on and it’s hard to work out what that is based on the code fragments you’ve posted in your various threads.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
UDP network privacy for command-line apps?
 
 
Q