Some APIs seem to require entitlements for any use (sandboxed or not) but don't have any indication where we might sign up. The particular usage here is com.apple.vm.networking for vmnet, as it looks like we can't even get started in development without it.
Post not yet marked as solved
Hi,
I am trying to create a virtual-machine using Virtualization.Framework (Reference) and trying to use VZFileHandleNetworkDeviceAttachment (Referece) as network device.
The creation and starting of VM are successful but am not receiving any raw packets via the created datagram socket.
Is there any working example for using VZFileHandleNetworkDeviceAttachment.
Thanks in advance.
Post not yet marked as solved
Host: Mac Ventura 13.3/m1
Xcode:14.3
My request for access to the com.apple.vm.networking entitlement has been approved. In Xcode I have also enabled the ability to automatically manage signing. Then i followed the steps in the link, focusing on new process part (https://developer.apple.com/forums/thread/663271)
I encountered some problems when I was trying to enable "com.apple.vm.networking"
Adopt an Explicit App ID
I already have an explicit App ID for a macOS target.
Configure Your App ID
My App ID has the VM Networking option checked.
Enable the Entitlement
(in the https://developer.apple.com/documentation/virtualization/running_macos_in_a_virtual_machine_on_apple_silicon_macs to download sample code)
In the sample code macOSVirtualMachineSampleApp.entitlements and InstallationTool.entitlements these two file, I have added the "com.apple.vm.net working", and set the value to YES, but for my build target(InstallationTool-Swift), there is no Personal VPN capability here, so I did not add this capability to update profile, but when I build my target, the terminal always appears the following error. This error caused my virtual machine to not start at all:
Message from debugger: no such process.
Program ended with exit code: -1
I searched the Internet for this error which may have been caused by my developer account authentication failure, but i'm not sure.
Please let me know where I went wrong. Now it seems that "com.apple.vm.networking" does not take effect or authorization is not successful. I also don't know whether there is something wrong with my configuration.
Anyway, I hope you can give me some advice.
Post not yet marked as solved
Currently facing below error while opening a Centos Virtual Machine
Translated Report (Full Report Below)
-------------------------------------
Process: VirtualBoxVM [17916]
Path: /Applications/VirtualBox.app/Contents/Resources/VirtualBoxVM.app/Contents/MacOS/VirtualBoxVM
Identifier: org.virtualbox.app.VirtualBoxVM
Version: 7.0.8 (7.0.8)
Code Type: ARM-64 (Native)
Parent Process: VBoxSVC [2215]
Responsible: VirtualBox [2211]
User ID: 501
Date/Time: 2023-06-12 14:45:57.8123 -0500
OS Version: macOS 13.4 (22F66)
Report Version: 12
Anonymous UUID: 3011B0EE-B295-B6AE-28D8-47D224DC9296
Time Awake Since Boot: 19000 seconds
System Integrity Protection: enabled
Crashed Thread: 12 EMT-3
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
abort() called
Model: MacBookPro18,1, BootROM 8422.121.1, proc 10:8:2 processors, 32 GB, SMC
Graphics: Apple M1 Pro, Apple M1 Pro, Built-In
Display: Color LCD, 3456 x 2234 Retina, Main, MirrorOff, Online
Display: DELL P2317H, 1920 x 1080 (1080p FHD - Full High Definition), MirrorOff, Online
Display: LG HDR 4K, 3840 x 2160 (2160p/4K UHD 1 - Ultra High Definition), MirrorOff, Online
Memory Module: LPDDR5, Hynix
AirPort: spairport_wireless_card_type_wifi (0x14E4, 0x4387), wl0: Apr 7 2023 15:18:26 version 20.96.28.1.8.7.146 FWID 01-aff1b48a
Bluetooth: Version (null), 0 services, 0 devices, 0 incoming serial ports
Network Service: Wi-Fi, AirPort, en0
Network Service: F5 K, VPN (com.f5.access.macos), utun3
USB Device: USB31Bus
USB Device: USB3.0 Hub
USB Device: USB 10/100/1000 LAN
USB Device: USB2.0 Hub
USB Device: BILLBOARD DEVICE
USB Device: Wireless Receiver
USB Device: USB31Bus
USB Device: Razer Cynosa Chroma Pro
USB Device: USB31Bus
Thunderbolt Bus: MacBook Pro, Apple Inc.
Thunderbolt Bus: MacBook Pro, Apple Inc.
Thunderbolt Bus: MacBook Pro, Apple Inc.
Post not yet marked as solved
I installed Gentoo in virtual machine using Apple Virtualization framework. In linux then I installed avahi, configured the network in Bridge mode. Now I want to connect from this virtual machine to other computer in local network. I can see other computers on the local network, and connect with them using local IP address. But for some reason these are not detected using .local domain. I run avahi-browse -at|grep PS3 and it detected 4 entries for this computer:
IPV4 _ssh._tcp local
IPV6 _ssh._tcp local
IPV4 _sftp-ssh._tcp local
IPV6 _sftp-ssh._tcp local
Also avahi-resolve -n PS3.local correctly detects IPv6 address of this machine.
So why cannot I connect with the computer using PS3.local name?
Post not yet marked as solved
My environment is a router with OpenWRT, a laptop connected to the router via patch cable and an untagged VLAN with VID 5 configured on that port in the router, and a MacBook M1 Pro connected via Wi-Fi to the router.
On the macbook, I created a VLAN interface by specifying en0 (AirPort) as the parent interface, then created a VM using QEMU with hvf accelerator or lima/UTM with VZ and I observe a strange situation: using arping, packets from the laptop sometimes reach the VM connected to the VLAN interface on the macbook, but arping running on the VM only sends requests but does not receive replies from the laptop. If I assign an IP address to the VLAN interface in macOS, packets are transmitted over either protocol without any problems. The problem is delivering packets to the virtual machine.
With tcpdump on the laptop I can see that it reply to arp requests, I can also see on the router that replies to arp requests passed through the Wi-Fi interface, but I don't see them in tcpdump on en0 on the macbook, which is also strange. But as I wrote before, if I assign an address from the same network on the macbook's VLAN interface, any packets are delivered between the laptop and macbook.
Laptop: 192.168.24.50
MacBook: 192.168.24.20 (vlan5 interface).
VM: 192.168.24.10
With lima-vm I use socket_vmnet in bridge mode. With QEMU I use vmnet-bridged.
➜ ~ ifconfig vlan5
vlan5: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1496
options=6063<RXCSUM,TXCSUM,TSO4,TSO6,PARTIAL_CSUM,ZEROINVERT_CSUM>
ether f0:2f:4b:xx:xx:xx
inet 192.168.24.20 netmask 0xffffff00 broadcast 192.168.24.255
vlan: 5 parent interface: en0
media: autoselect
status: active
➜ ~ ping 192.168.24.50 -c2
PING 192.168.24.50 (192.168.24.50): 56 data bytes
64 bytes from 192.168.24.50: icmp_seq=0 ttl=64 time=5.241 ms
64 bytes from 192.168.24.50: icmp_seq=1 ttl=64 time=5.429 ms
--- 192.168.24.50 ping statistics ---
2 packets transmitted, 2 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 5.241/5.335/5.429/0.094 ms
➜ ~ sudo arping -c 5 -i vlan5 192.168.24.50
ARPING 192.168.24.50
60 bytes from 10:e7:c6:xx:xx:xx (192.168.24.50): index=0 time=6.061 msec
60 bytes from 10:e7:c6:xx:xx:xx (192.168.24.50): index=1 time=6.084 msec
60 bytes from 10:e7:c6:xx:xx:xx (192.168.24.50): index=2 time=5.945 msec
60 bytes from 10:e7:c6:xx:xx:xx (192.168.24.50): index=3 time=3.092 msec
60 bytes from 10:e7:c6:xx:xx:xx (192.168.24.50): index=4 time=3.848 msec
--- 192.168.24.50 statistics ---
5 packets transmitted, 5 packets received, 0% unanswered (0 extra)
rtt min/avg/max/std-dev = 3.092/5.006/6.084/1.278 ms
➜ ~ ifconfig bridge100
bridge100: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1496
options=3<RXCSUM,TXCSUM>
ether f2:2f:4b:xx:xx:xx
Configuration:
id 0:0:0:0:0:0 priority 0 hellotime 0 fwddelay 0
maxage 0 holdcnt 0 proto stp maxaddr 100 timeout 1200
root id 0:0:0:0:0:0 priority 0 ifcost 0 port 0
ipfilter disabled flags 0x0
member: vlan5 flags=3<LEARNING,DISCOVER>
ifmaxaddr 0 port 22 priority 0 path cost 0
member: vmenet0 flags=3<LEARNING,DISCOVER>
ifmaxaddr 0 port 23 priority 0 path cost 0
Address cache:
10:e7:c6:xx:xx:xx Vlan1 vlan5 326 flags=0<>
52:55:55:ae:36:b4 Vlan1 vmenet0 1172 flags=0<>
nd6 options=201<PERFORMNUD,DAD>
media: autoselect
status: active
[root@VM1 ~]# arping 192.168.24.50 -c5
ARPING 192.168.24.50 from 192.168.24.10 lima0
Sent 5 probes (5 broadcast(s))
Received 0 response(s)
[root@VM1 ~]#
[root@laptop ~]# arping 192.168.24.10 -c5
ARPING 192.168.24.15 from 192.168.24.10 lima0
Unicast reply from 192.168.24.10 [52:55:55:AE:36:B4] 2.492ms
Unicast reply from 192.168.24.10 [52:55:55:AE:36:B4] 1.791ms
Unicast reply from 192.168.24.10 [52:55:55:AE:36:B4] 3.059ms
Sent 5 probes (1 broadcast(s))
Received 3 response(s)
[root@laptop ~]#
What could be the reason for this behavior?