mikebrady / shairport-sync

AirPlay and AirPlay 2 audio player
Other
7.2k stars 571 forks source link

[Problem]: Frequent “Unable to connect” messages on iOS and tvOS without actually selecting a speaker #1757

Closed aaronk6 closed 6 months ago

aaronk6 commented 11 months ago

What happened?

I’m frequently getting “Unable to connect” messages on iOS 17.x and tvOS 17.x. What’s interesting about these messages is that they appear without me actually selecting a speaker. Simply opening a the speaker selection view on iOS is enough. Sometimes not even that. However, when I then actually select to a speaker, it connects just fine.

Screenshot 2023-11-01 at 18 42 21

Screencast:

https://github.com/mikebrady/shairport-sync/assets/446063/cfb4cd80-9f1a-43ca-98ad-657535061f30

The issue seems to occur when Shairport Sync is already playing something on that speaker. My setup is that I’m constantly playing audio via OwnTone to Shairport Sync to have music in the bathrooms, but allow clients to override the stream (using allow_session_interruption = "yes" in the Shairport Sync config). Now that https://github.com/mikebrady/shairport-sync/issues/1723 is fixed, overriding an existing session works perfectly.

So it’s really “just” the “Unable to Connect” message, which is—at first glance—a cosmetic issue, but it can get very annoying as it sometimes also occurs when the iPhone is just lying on the table and streaming music. It will turn on the display just for showing this message. On the Apple TV, it will even interrupt a running show.

“Unable to Connect” interrupting a show on tvOS

![IMG_7229]()

It’s also worth noting that this only happens on Shairport Sync receivers. Besides these, I have a Denon AVR X1700H, which is also AirPlay 2-compatible, and two HomePods.

I believe this started after upgrading to iOS 17 and tvOS 17 which includes some changes in regards to AirPlay. For example, it will proactively suggest to connect to an AirPlay speaker if you start to play something on the iPhone. My hunch is that iOS is regularly trying to probe speakers to see if they can be offered as AirPlay targets. Shairport Sync seems to reply to this request in a way that triggers this message.

The attached log output is shown when I open the speaker selection view on iOS while OwnTone is streaming to the Bad DG speaker.

@mikebrady, you wrote here that this might be tough one. I’m reporting it anyway to see if other people experience this, too, and maybe we will find out eventually how to adhere more closely to the protocol to prevent this message from showing up.

Relevant log output

bad_dg_1     |          0.915234351 "rtp.c:468" New latency: 99017, sync latency: 87992, minimum latency: 0, maximum latency: 0, fixed offset: 11025, audio_backend_latency_offset: 0.000000.
bad_dg_1     |          0.000099833 "rtp.c:513" AP1 control thread: set_ntp_anchor_info: rtptime: 1607793594, networktime: 1ea97bde6249d3d3, frame adjustment:   0.000.
bad_dg_1     |          0.091605223 "dacp.c:803" DACP Composite ID seen
bad_dg_1     |          0.000064148 "dacp.c:771" DACP Track Name seen
bad_dg_1     |          0.000035037 "dacp.c:779" DACP Artist Name seen
bad_dg_1     |          0.000033037 "dacp.c:787" DACP Album Name seen
bad_dg_1     |          0.000149407 "dacp.c:795" DACP Genre seen
bad_dg_1     |          0.000128611 "dacp.c:825" DACP Song Time seen: "0" of length 4.
bad_dg_1     |          0.000285815 "dbus-service.c:226" Build metadata
bad_dg_1     |          0.000436574 "mpris-service.c:167" Build metadata
bad_dg_1     |          0.016574778 "rtsp.c:710" Airplay Volume for connection 28 is -10.800000.
bad_dg_1     |          0.000101018 "rtsp.c:702" Found RTSP connection thread 31 in a non-running state.
bad_dg_1     |          0.000212908 "rtsp.c:705" Connection 31: deleted.
bad_dg_1     |          0.000186963 "rtsp.c:726" Airplay Volume for new connections is -10.800000.
bad_dg_1     |          0.000440407 "rtsp.c:5588" Connection 32 is at: 0xf0a93160.
bad_dg_1     |          0.000182482 "rtsp.c:5670" Connection 32: New connection from 192.168.88.91:54858 to self at 192.168.88.8:7000.
bad_dg_1     |          0.001551555 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "GET":
bad_dg_1     |          0.000100315 "rtsp.c:5253"   Type: "X-Apple-ProtocolVersion", content: "1"
bad_dg_1     |          0.000061185 "rtsp.c:5253"   Type: "Content-Length", content: "70"
bad_dg_1     |          0.000035241 "rtsp.c:5253"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000043926 "rtsp.c:5253"   Type: "CSeq", content: "0"
bad_dg_1     |          0.000032148 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000082352 "rtsp.c:5253"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>qualifier</key>
bad_dg_1     |  <array>
bad_dg_1     |      <string>txtAirPlay</string>
bad_dg_1     |  </array>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000061963 "rtsp.c:2039" Connection 32: GET /info :: Content-Length 70
bad_dg_1     |          0.000045741 "rtsp.c:2041" GET request
bad_dg_1     |          0.000032537 "rtsp.c:2041"   Type: "X-Apple-ProtocolVersion", content: "1"
bad_dg_1     |          0.000047981 "rtsp.c:2041"   Type: "Content-Length", content: "70"
bad_dg_1     |          0.000034241 "rtsp.c:2041"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000047333 "rtsp.c:2041"   Type: "CSeq", content: "0"
bad_dg_1     |          0.000033019 "rtsp.c:2041"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000067500 "rtsp.c:2041"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>qualifier</key>
bad_dg_1     |  <array>
bad_dg_1     |      <string>txtAirPlay</string>
bad_dg_1     |  </array>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000168018 "rtsp.c:1677" GET /info:
bad_dg_1     |          0.000044797 "rtsp.c:1677"   Type: "X-Apple-ProtocolVersion", content: "1"
bad_dg_1     |          0.000046888 "rtsp.c:1677"   Type: "Content-Length", content: "70"
bad_dg_1     |          0.000034445 "rtsp.c:1677"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000044944 "rtsp.c:1677"   Type: "CSeq", content: "0"
bad_dg_1     |          0.000032519 "rtsp.c:1677"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000074870 "rtsp.c:1677"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>qualifier</key>
bad_dg_1     |  <array>
bad_dg_1     |      <string>txtAirPlay</string>
bad_dg_1     |  </array>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000053982 "rtsp.c:1686" Connection 32: GET_INFO: Source AirPlay Version is: 710.79.1.
bad_dg_1     |          0.000064037 "rtsp.c:1709" GET /info Stage 1: qualifier: txtAirPlay
bad_dg_1     |          0.003056315 "rtsp.c:1796" GET /info Stage 1 Response:
bad_dg_1     |          0.000076018 "rtsp.c:1796"   Response Code: 501.
bad_dg_1     |          0.000034926 "rtsp.c:1796"   Type: "CSeq", content: "0"
bad_dg_1     |          0.000034333 "rtsp.c:1796"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000033445 "rtsp.c:1796"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000614055 "rtsp.c:1796"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>audioLatencies</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>default</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>102</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     |  <key>keepAliveLowPower</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>keepAliveSendStatsAsBody</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>manufacturer</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     |  <key>nameIsFactoryDefault</key>
bad_dg_1     |  <false/>
bad_dg_1     |  <key>protocolVersion</key>
bad_dg_1     |  <string>1.1</string>
bad_dg_1     |  <key>sdk</key>
bad_dg_1     |  <string>AirPlay;2.0.2</string>
bad_dg_1     |  <key>sourceVersion</key>
bad_dg_1     |  <string>366.0</string>
bad_dg_1     |  <key>statusFlags</key>
bad_dg_1     |  <integer>2052</integer>
bad_dg_1     |  <key>txtAirPlay</key>
bad_dg_1     |  <data>
bad_dg_1     |  BWFjbD0wGmRldmljZWlkPTAyOjQyOmMwOmE4OjU4OjAzG2ZlYXR1cmVzPTB4NDA1RkNB
bad_dg_1     |  MDAsMHgxQzM0MAdyc2Y9MHgwCWZsYWdzPTB4NBRtb2RlbD1TaGFpcnBvcnQgU3luYw1t
bad_dg_1     |  YW51ZmFjdHVyZXI9DXNlcmlhbE51bWJlcj0NcHJvdG92ZXJzPTEuMQ1zcmN2ZXJzPTM2
bad_dg_1     |  Ni4wJ3BpPThmMDVjODYxLTA3MjQtNDdkMC1hZjU5LWZjNWYxYWFjODU0MShnaWQ9OGYw
bad_dg_1     |  NWM4NjEtMDcyNC00N2QwLWFmNTktZmM1ZjFhYWM4NTQxBmdjZ2w9MENwaz0yYjQwNGRl
bad_dg_1     |  YTdiZGE2ZTNhMjc3ZDRmZDFlMWM3ZGE3MmE2OGJkYmViNzRiOWIyMTM4NzU2NDBjN2E5
bad_dg_1     |  OTU4MGU0
bad_dg_1     |  </data>
bad_dg_1     |  <key>features</key>
bad_dg_1     |  <integer>496155702053376</integer>
bad_dg_1     |  <key>deviceID</key>
bad_dg_1     |  <string>02:42:c0:a8:58:03</string>
bad_dg_1     |  <key>pi</key>
bad_dg_1     |  <string>8f05c861-0724-47d0-af59-fc5f1aac8541</string>
bad_dg_1     |  <key>name</key>
bad_dg_1     |  <string>Bad DG</string>
bad_dg_1     |  <key>model</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000582945 "rtsp.c:5312" Connection 32: RTSP Response:
bad_dg_1     |          0.000040926 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000031203 "rtsp.c:5313"   Type: "CSeq", content: "0"
bad_dg_1     |          0.000031371 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000030296 "rtsp.c:5313"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000490593 "rtsp.c:5313"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>audioLatencies</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>default</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>102</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     |  <key>keepAliveLowPower</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>keepAliveSendStatsAsBody</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>manufacturer</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     |  <key>nameIsFactoryDefault</key>
bad_dg_1     |  <false/>
bad_dg_1     |  <key>protocolVersion</key>
bad_dg_1     |  <string>1.1</string>
bad_dg_1     |  <key>sdk</key>
bad_dg_1     |  <string>AirPlay;2.0.2</string>
bad_dg_1     |  <key>sourceVersion</key>
bad_dg_1     |  <string>366.0</string>
bad_dg_1     |  <key>statusFlags</key>
bad_dg_1     |  <integer>2052</integer>
bad_dg_1     |  <key>txtAirPlay</key>
bad_dg_1     |  <data>
bad_dg_1     |  BWFjbD0wGmRldmljZWlkPTAyOjQyOmMwOmE4OjU4OjAzG2ZlYXR1cmVzPTB4NDA1RkNB
bad_dg_1     |  MDAsMHgxQzM0MAdyc2Y9MHgwCWZsYWdzPTB4NBRtb2RlbD1TaGFpcnBvcnQgU3luYw1t
bad_dg_1     |  YW51ZmFjdHVyZXI9DXNlcmlhbE51bWJlcj0NcHJvdG92ZXJzPTEuMQ1zcmN2ZXJzPTM2
bad_dg_1     |  Ni4wJ3BpPThmMDVjODYxLTA3MjQtNDdkMC1hZjU5LWZjNWYxYWFjODU0MShnaWQ9OGYw
bad_dg_1     |  NWM4NjEtMDcyNC00N2QwLWFmNTktZmM1ZjFhYWM4NTQxBmdjZ2w9MENwaz0yYjQwNGRl
bad_dg_1     |  YTdiZGE2ZTNhMjc3ZDRmZDFlMWM3ZGE3MmE2OGJkYmViNzRiOWIyMTM4NzU2NDBjN2E5
bad_dg_1     |  OTU4MGU0
bad_dg_1     |  </data>
bad_dg_1     |  <key>features</key>
bad_dg_1     |  <integer>496155702053376</integer>
bad_dg_1     |  <key>deviceID</key>
bad_dg_1     |  <string>02:42:c0:a8:58:03</string>
bad_dg_1     |  <key>pi</key>
bad_dg_1     |  <string>8f05c861-0724-47d0-af59-fc5f1aac8541</string>
bad_dg_1     |  <key>name</key>
bad_dg_1     |  <string>Bad DG</string>
bad_dg_1     |  <key>model</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000146592 "rtsp.c:1535" Responding with content of length 905
bad_dg_1     |          0.004946593 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "POST":
bad_dg_1     |          0.000580185 "rtsp.c:5253"   Type: "X-Apple-AbsoluteTime", content: "720555677"
bad_dg_1     |          0.000949648 "rtsp.c:5253"   Type: "X-Apple-HKP", content: "6"
bad_dg_1     |          0.000068389 "rtsp.c:5253"   Type: "X-Apple-Client-Name", content: "iphone-sx4utj"
bad_dg_1     |          0.000045685 "rtsp.c:5253"   Type: "X-Apple-PD", content: "1"
bad_dg_1     |          0.000032537 "rtsp.c:5253"   Type: "Content-Length", content: "37"
bad_dg_1     |          0.000031778 "rtsp.c:5253"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000042908 "rtsp.c:5253"   Type: "CSeq", content: "1"
bad_dg_1     |          0.000030518 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000049611 "rtsp.c:5253"   No Content Plist. Content length: 37.
bad_dg_1     |          0.000044352 "rtsp.c:2204" Connection 32: pair-verify Content-Length 37
bad_dg_1     |          0.006872852 "rtsp.c:2240" pair-verify response
bad_dg_1     |          0.000347611 "rtsp.c:2240"   Response Code: 200.
bad_dg_1     |          0.000235630 "rtsp.c:2240"   Type: "CSeq", content: "1"
bad_dg_1     |          0.000212574 "rtsp.c:2240"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000207407 "rtsp.c:2240"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000411519 "rtsp.c:2240"   No Content Plist. Content length: 140.
bad_dg_1     |          0.000210296 "rtsp.c:5312" Connection 32: RTSP Response:
bad_dg_1     |          0.000201222 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000197630 "rtsp.c:5313"   Type: "CSeq", content: "1"
bad_dg_1     |          0.000185944 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000203482 "rtsp.c:5313"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000380666 "rtsp.c:5313"   No Content Plist. Content length: 140.
bad_dg_1     |          0.000286723 "rtsp.c:1535" Responding with content of length 140
bad_dg_1     |          0.014117925 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "POST":
bad_dg_1     |          0.000725556 "rtsp.c:5253"   Type: "X-Apple-AbsoluteTime", content: "720555677"
bad_dg_1     |          0.000060259 "rtsp.c:5253"   Type: "X-Apple-HKP", content: "4"
bad_dg_1     |          0.000035426 "rtsp.c:5253"   Type: "X-Apple-Client-Name", content: "iphone-sx4utj"
bad_dg_1     |          0.000044241 "rtsp.c:5253"   Type: "Content-Length", content: "9"
bad_dg_1     |          0.000033204 "rtsp.c:5253"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.001754148 "rtsp.c:5253"   Type: "CSeq", content: "2"
bad_dg_1     |          0.000047018 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000044278 "rtsp.c:5253"   No Content Plist. Content length: 9.
bad_dg_1     |          0.000041593 "rtsp.c:2248" Connection 32: handle_pair-setup Content-Length 9
bad_dg_1     |          0.082853444 "rtsp.c:2286" pair-setup response
bad_dg_1     |          0.000037482 "rtsp.c:2286"   Response Code: 200.
bad_dg_1     |          0.000016851 "rtsp.c:2286"   Type: "CSeq", content: "2"
bad_dg_1     |          0.000048741 "rtsp.c:2286"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000017019 "rtsp.c:2286"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000022889 "rtsp.c:2286"   No Content Plist. Content length: 409.
bad_dg_1     |          0.000016481 "rtsp.c:5312" Connection 32: RTSP Response:
bad_dg_1     |          0.000016722 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000015760 "rtsp.c:5313"   Type: "CSeq", content: "2"
bad_dg_1     |          0.000016129 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000014982 "rtsp.c:5313"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000022981 "rtsp.c:5313"   No Content Plist. Content length: 409.
bad_dg_1     |          0.000022519 "rtsp.c:1535" Responding with content of length 409
bad_dg_1     |          0.088257907 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "POST":
bad_dg_1     |          0.000046111 "rtsp.c:5253"   Type: "X-Apple-AbsoluteTime", content: "720555677"
bad_dg_1     |          0.000020908 "rtsp.c:5253"   Type: "X-Apple-HKP", content: "4"
bad_dg_1     |          0.000015203 "rtsp.c:5253"   Type: "X-Apple-Client-Name", content: "iphone-sx4utj"
bad_dg_1     |          0.000019593 "rtsp.c:5253"   Type: "Content-Length", content: "457"
bad_dg_1     |          0.000015407 "rtsp.c:5253"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000019500 "rtsp.c:5253"   Type: "CSeq", content: "3"
bad_dg_1     |          0.000015704 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000021500 "rtsp.c:5253"   No Content Plist. Content length: 457.
bad_dg_1     |          0.000021093 "rtsp.c:2248" Connection 32: handle_pair-setup Content-Length 457
bad_dg_1     |          0.054626907 "rtsp.c:2286" pair-setup response
bad_dg_1     |          0.000036741 "rtsp.c:2286"   Response Code: 200.
bad_dg_1     |          0.000015870 "rtsp.c:2286"   Type: "CSeq", content: "3"
bad_dg_1     |          0.000015907 "rtsp.c:2286"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000015537 "rtsp.c:2286"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000020445 "rtsp.c:2286"   No Content Plist. Content length: 69.
bad_dg_1     |          0.000016685 "rtsp.c:5312" Connection 32: RTSP Response:
bad_dg_1     |          0.000014352 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000015093 "rtsp.c:5313"   Type: "CSeq", content: "3"
bad_dg_1     |          0.000015777 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000015852 "rtsp.c:5313"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000021296 "rtsp.c:5313"   No Content Plist. Content length: 69.
bad_dg_1     |          0.000020167 "rtsp.c:1535" Responding with content of length 69
bad_dg_1     |          0.007991815 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "POST":
bad_dg_1     |          0.000048296 "rtsp.c:5253"   Type: "X-Apple-ET", content: "32"
bad_dg_1     |          0.000016148 "rtsp.c:5253"   Type: "Content-Length", content: "16"
bad_dg_1     |          0.000015037 "rtsp.c:5253"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000019241 "rtsp.c:5253"   Type: "CSeq", content: "4"
bad_dg_1     |          0.000015130 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000497074 "rtsp.c:5253"   No Content Plist. Content length: 16.
bad_dg_1     |          0.000036926 "rtsp.c:5312" Connection 32: RTSP Response:
bad_dg_1     |          0.000015296 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000014019 "rtsp.c:5313"   Type: "CSeq", content: "4"
bad_dg_1     |          0.000015481 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000014167 "rtsp.c:5313"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000149074 "rtsp.c:5313"   No Content Plist. Content length: 142.
bad_dg_1     |          0.000272759 "rtsp.c:1535" Responding with content of length 142
bad_dg_1     |          0.030281037 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "POST":
bad_dg_1     |          0.000045704 "rtsp.c:5253"   Type: "X-Apple-ET", content: "32"
bad_dg_1     |          0.000016037 "rtsp.c:5253"   Type: "Content-Length", content: "164"
bad_dg_1     |          0.000014870 "rtsp.c:5253"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000019741 "rtsp.c:5253"   Type: "CSeq", content: "5"
bad_dg_1     |          0.000018611 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000019963 "rtsp.c:5253"   No Content Plist. Content length: 164.
bad_dg_1     |          0.000021833 "rtsp.c:5312" Connection 32: RTSP Response:
bad_dg_1     |          0.000016093 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000014907 "rtsp.c:5313"   Type: "CSeq", content: "5"
bad_dg_1     |          0.000014186 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000016981 "rtsp.c:5313"   Type: "Content-Type", content: "application/octet-stream"
bad_dg_1     |          0.000021870 "rtsp.c:5313"   No Content Plist. Content length: 32.
bad_dg_1     |          0.000020500 "rtsp.c:1535" Responding with content of length 32
bad_dg_1     |          0.004453315 "rtsp.c:5251" Connection 32: Received an RTSP Packet of type "SETUP":
bad_dg_1     |          0.000047204 "rtsp.c:5253"   Type: "Content-Length", content: "480"
bad_dg_1     |          0.000016241 "rtsp.c:5253"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000020074 "rtsp.c:5253"   Type: "CSeq", content: "6"
bad_dg_1     |          0.000014315 "rtsp.c:5253"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000074037 "rtsp.c:5253"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>timingProtocol</key>
bad_dg_1     |  <string>None</string>
bad_dg_1     |  <key>statsCollectionEnabled</key>
bad_dg_1     |  <false/>
bad_dg_1     |  <key>isRemoteControlOnly</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>osName</key>
bad_dg_1     |  <string>iPhone OS</string>
bad_dg_1     |  <key>sessionUUID</key>
bad_dg_1     |  <string>D2DA47E2-39C3-4277-8A50-45A06C902084</string>
bad_dg_1     |  <key>osBuildVersion</key>
bad_dg_1     |  <string>21A360</string>
bad_dg_1     |  <key>sourceVersion</key>
bad_dg_1     |  <string>710.79.1</string>
bad_dg_1     |  <key>osVersion</key>
bad_dg_1     |  <string>17.0.3</string>
bad_dg_1     |  <key>sessionCorrelationUUID</key>
bad_dg_1     |  <string>7BD21E39-82DC-4A97-876A-96EEC6B9969A</string>
bad_dg_1     |  <key>deviceID</key>
bad_dg_1     |  <string>C4:C1:7D:F0:2C:2C</string>
bad_dg_1     |  <key>model</key>
bad_dg_1     |  <string>iPhone16,1</string>
bad_dg_1     |  <key>name</key>
bad_dg_1     |  <string>iphone-sx4utj</string>
bad_dg_1     |  <key>macAddress</key>
bad_dg_1     |  <string>C4:C1:7D:F0:40:65</string>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000032777 "rtsp.c:2869" Connection 32: SETUP (AirPlay 2)
bad_dg_1     |          0.000016611 "rtsp.c:2870" SETUP (AirPlay 2) SETUP incoming message
bad_dg_1     |          0.000015204 "rtsp.c:2870"   Type: "Content-Length", content: "480"
bad_dg_1     |          0.000015537 "rtsp.c:2870"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000022204 "rtsp.c:2870"   Type: "CSeq", content: "6"
bad_dg_1     |          0.000015278 "rtsp.c:2870"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000062185 "rtsp.c:2870"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>timingProtocol</key>
bad_dg_1     |  <string>None</string>
bad_dg_1     |  <key>statsCollectionEnabled</key>
bad_dg_1     |  <false/>
bad_dg_1     |  <key>isRemoteControlOnly</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>osName</key>
bad_dg_1     |  <string>iPhone OS</string>
bad_dg_1     |  <key>sessionUUID</key>
bad_dg_1     |  <string>D2DA47E2-39C3-4277-8A50-45A06C902084</string>
bad_dg_1     |  <key>osBuildVersion</key>
bad_dg_1     |  <string>21A360</string>
bad_dg_1     |  <key>sourceVersion</key>
bad_dg_1     |  <string>710.79.1</string>
bad_dg_1     |  <key>osVersion</key>
bad_dg_1     |  <string>17.0.3</string>
bad_dg_1     |  <key>sessionCorrelationUUID</key>
bad_dg_1     |  <string>7BD21E39-82DC-4A97-876A-96EEC6B9969A</string>
bad_dg_1     |  <key>deviceID</key>
bad_dg_1     |  <string>C4:C1:7D:F0:2C:2C</string>
bad_dg_1     |  <key>model</key>
bad_dg_1     |  <string>iPhone16,1</string>
bad_dg_1     |  <key>name</key>
bad_dg_1     |  <string>iphone-sx4utj</string>
bad_dg_1     |  <key>macAddress</key>
bad_dg_1     |  <string>C4:C1:7D:F0:40:65</string>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000097426 "rtsp.c:2889" Connection 32 SETUP: No "streams" array has been found -- create an event thread and open a TCP port.
bad_dg_1     |          0.000027796 "rtsp.c:2925" Connection 32: Remote Control connection from 192.168.88.91:54858 ("iphone-sx4utj") to self at 192.168.88.8:7000.
bad_dg_1     |          0.000094222 "rtsp.c:3453"  SETUP response
bad_dg_1     |          0.000017982 "rtsp.c:3453"   Response Code: 200.
bad_dg_1     |          0.000014055 "rtsp.c:3453"   Type: "CSeq", content: "6"
bad_dg_1     |          0.000013945 "rtsp.c:3453"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000015333 "rtsp.c:3453"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000179852 "rtsp.c:3453"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict/>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000068685 "rtsp.c:5309" Connection 32 (RC): RTSP Response:
bad_dg_1     |          0.000017741 "rtsp.c:5310"   Response Code: 200.
bad_dg_1     |          0.000014778 "rtsp.c:5310"   Type: "CSeq", content: "6"
bad_dg_1     |          0.000015537 "rtsp.c:5310"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000051370 "rtsp.c:5310"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000191963 "rtsp.c:5310"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict/>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000065463 "rtsp.c:1535" Responding with content of length 42
bad_dg_1     |          0.007245204 "rtsp.c:5247" Connection 32 (RC): Received an RTSP Packet of type "GET":
bad_dg_1     |          0.000050037 "rtsp.c:5249"   Type: "X-Apple-ProtocolVersion", content: "1"
bad_dg_1     |          0.000021259 "rtsp.c:5249"   Type: "CSeq", content: "7"
bad_dg_1     |          0.000014537 "rtsp.c:5249"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000019537 "rtsp.c:5249"   No Content Plist. Content length: 0.
bad_dg_1     |          0.000019000 "rtsp.c:2039" Connection 32: GET /info :: Content-Length 0
bad_dg_1     |          0.000628482 "rtsp.c:2041" GET request
bad_dg_1     |          0.000021629 "rtsp.c:2041"   Type: "X-Apple-ProtocolVersion", content: "1"
bad_dg_1     |          0.000055296 "rtsp.c:2041"   Type: "CSeq", content: "7"
bad_dg_1     |          0.000017482 "rtsp.c:2041"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000022593 "rtsp.c:2041"   No Content Plist. Content length: 0.
bad_dg_1     |          0.000045314 "rtsp.c:1677" GET /info:
bad_dg_1     |          0.000016686 "rtsp.c:1677"   Type: "X-Apple-ProtocolVersion", content: "1"
bad_dg_1     |          0.000019740 "rtsp.c:1677"   Type: "CSeq", content: "7"
bad_dg_1     |          0.000015408 "rtsp.c:1677"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000055166 "rtsp.c:1677"   No Content Plist. Content length: 0.
bad_dg_1     |          0.000668167 "rtsp.c:1821" GET /info Stage 2 Response
bad_dg_1     |          0.000062370 "rtsp.c:1821"   Response Code: 501.
bad_dg_1     |          0.000015741 "rtsp.c:1821"   Type: "CSeq", content: "7"
bad_dg_1     |          0.000014389 "rtsp.c:1821"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000047482 "rtsp.c:1821"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000385185 "rtsp.c:1821"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>audioLatencies</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>default</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>102</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     |  <key>keepAliveLowPower</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>keepAliveSendStatsAsBody</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>manufacturer</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     |  <key>nameIsFactoryDefault</key>
bad_dg_1     |  <false/>
bad_dg_1     |  <key>protocolVersion</key>
bad_dg_1     |  <string>1.1</string>
bad_dg_1     |  <key>sdk</key>
bad_dg_1     |  <string>AirPlay;2.0.2</string>
bad_dg_1     |  <key>sourceVersion</key>
bad_dg_1     |  <string>366.0</string>
bad_dg_1     |  <key>statusFlags</key>
bad_dg_1     |  <integer>2052</integer>
bad_dg_1     |  <key>features</key>
bad_dg_1     |  <integer>496155702053376</integer>
bad_dg_1     |  <key>deviceID</key>
bad_dg_1     |  <string>02:42:c0:a8:58:03</string>
bad_dg_1     |  <key>pi</key>
bad_dg_1     |  <string>8f05c861-0724-47d0-af59-fc5f1aac8541</string>
bad_dg_1     |  <key>name</key>
bad_dg_1     |  <string>Bad DG</string>
bad_dg_1     |  <key>model</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000083963 "rtsp.c:5309" Connection 32 (RC): RTSP Response:
bad_dg_1     |          0.000017574 "rtsp.c:5310"   Response Code: 200.
bad_dg_1     |          0.000042981 "rtsp.c:5310"   Type: "CSeq", content: "7"
bad_dg_1     |          0.000019445 "rtsp.c:5310"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000014703 "rtsp.c:5310"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.001075778 "rtsp.c:5310"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>audioLatencies</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>default</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>100</integer>
bad_dg_1     |      </dict>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>audioType</key>
bad_dg_1     |          <string>media</string>
bad_dg_1     |          <key>inputLatencyMicros</key>
bad_dg_1     |          <integer>0</integer>
bad_dg_1     |          <key>outputLatencyMicros</key>
bad_dg_1     |          <integer>400000</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>102</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     |  <key>keepAliveLowPower</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>keepAliveSendStatsAsBody</key>
bad_dg_1     |  <true/>
bad_dg_1     |  <key>manufacturer</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     |  <key>nameIsFactoryDefault</key>
bad_dg_1     |  <false/>
bad_dg_1     |  <key>protocolVersion</key>
bad_dg_1     |  <string>1.1</string>
bad_dg_1     |  <key>sdk</key>
bad_dg_1     |  <string>AirPlay;2.0.2</string>
bad_dg_1     |  <key>sourceVersion</key>
bad_dg_1     |  <string>366.0</string>
bad_dg_1     |  <key>statusFlags</key>
bad_dg_1     |  <integer>2052</integer>
bad_dg_1     |  <key>features</key>
bad_dg_1     |  <integer>496155702053376</integer>
bad_dg_1     |  <key>deviceID</key>
bad_dg_1     |  <string>02:42:c0:a8:58:03</string>
bad_dg_1     |  <key>pi</key>
bad_dg_1     |  <string>8f05c861-0724-47d0-af59-fc5f1aac8541</string>
bad_dg_1     |  <key>name</key>
bad_dg_1     |  <string>Bad DG</string>
bad_dg_1     |  <key>model</key>
bad_dg_1     |  <string>Shairport Sync</string>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000096296 "rtsp.c:1535" Responding with content of length 570
bad_dg_1     |          0.004077445 "rtsp.c:5247" Connection 32 (RC): Received an RTSP Packet of type "RECORD":
bad_dg_1     |          0.000051796 "rtsp.c:5249"   Type: "CSeq", content: "8"
bad_dg_1     |          0.000024926 "rtsp.c:5249"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000021722 "rtsp.c:5249"   No Content Plist. Content length: 0.
bad_dg_1     |          0.000018315 "rtsp.c:1615" Connection 32: RECORD on Remote Control stream
bad_dg_1     |          0.000020148 "rtsp.c:5309" Connection 32 (RC): RTSP Response:
bad_dg_1     |          0.000014556 "rtsp.c:5310"   Response Code: 200.
bad_dg_1     |          0.000013833 "rtsp.c:5310"   Type: "CSeq", content: "8"
bad_dg_1     |          0.000018167 "rtsp.c:5310"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000014741 "rtsp.c:5310"   No Content Plist. Content length: 0.
bad_dg_1     |          0.007496611 "rtsp.c:5247" Connection 32 (RC): Received an RTSP Packet of type "SETUP":
bad_dg_1     |          0.000052259 "rtsp.c:5249"   Type: "Content-Length", content: "252"
bad_dg_1     |          0.000017074 "rtsp.c:5249"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000021074 "rtsp.c:5249"   Type: "CSeq", content: "9"
bad_dg_1     |          0.000015259 "rtsp.c:5249"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000062908 "rtsp.c:5249"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>streams</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>clientUUID</key>
bad_dg_1     |          <string>997C7C26-F3C7-4CDC-ADD3-403DE27E1905</string>
bad_dg_1     |          <key>clientTypeUUID</key>
bad_dg_1     |          <string>1910A70F-DBC0-4242-AF95-115DB30604E1</string>
bad_dg_1     |          <key>channelID</key>
bad_dg_1     |          <string>0221CCE5-1ABC-4F8B-B36B-CCFC4EF00EF0</string>
bad_dg_1     |          <key>controlType</key>
bad_dg_1     |          <integer>1</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>130</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000029148 "rtsp.c:2869" Connection 32: SETUP (AirPlay 2)
bad_dg_1     |          0.000015889 "rtsp.c:2870" SETUP (AirPlay 2) SETUP incoming message
bad_dg_1     |          0.000014481 "rtsp.c:2870"   Type: "Content-Length", content: "252"
bad_dg_1     |          0.000014852 "rtsp.c:2870"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000019500 "rtsp.c:2870"   Type: "CSeq", content: "9"
bad_dg_1     |          0.000014185 "rtsp.c:2870"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000047982 "rtsp.c:2870"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>streams</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>clientUUID</key>
bad_dg_1     |          <string>997C7C26-F3C7-4CDC-ADD3-403DE27E1905</string>
bad_dg_1     |          <key>clientTypeUUID</key>
bad_dg_1     |          <string>1910A70F-DBC0-4242-AF95-115DB30604E1</string>
bad_dg_1     |          <key>channelID</key>
bad_dg_1     |          <string>0221CCE5-1ABC-4F8B-B36B-CCFC4EF00EF0</string>
bad_dg_1     |          <key>controlType</key>
bad_dg_1     |          <integer>1</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>130</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000038166 "rtsp.c:3211" Connection 32: SETUP on Remote Control stream. A "streams" array has been found
bad_dg_1     |          0.000151149 "rtsp.c:3404" Connection 32 (RC): SETUP: Remote Control Stream received from 192.168.88.91.
bad_dg_1     |          0.000031889 "rtsp.c:3406" Remote Control Stream SETUP incoming message
bad_dg_1     |          0.000081814 "rtsp.c:3406"   Type: "Content-Length", content: "252"
bad_dg_1     |          0.000020186 "rtsp.c:3406"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000084462 "rtsp.c:3406"   Type: "CSeq", content: "9"
bad_dg_1     |          0.000018463 "rtsp.c:3406"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000052593 "rtsp.c:3406"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict>
bad_dg_1     |  <key>streams</key>
bad_dg_1     |  <array>
bad_dg_1     |      <dict>
bad_dg_1     |          <key>clientUUID</key>
bad_dg_1     |          <string>997C7C26-F3C7-4CDC-ADD3-403DE27E1905</string>
bad_dg_1     |          <key>clientTypeUUID</key>
bad_dg_1     |          <string>1910A70F-DBC0-4242-AF95-115DB30604E1</string>
bad_dg_1     |          <key>channelID</key>
bad_dg_1     |          <string>0221CCE5-1ABC-4F8B-B36B-CCFC4EF00EF0</string>
bad_dg_1     |          <key>controlType</key>
bad_dg_1     |          <integer>1</integer>
bad_dg_1     |          <key>type</key>
bad_dg_1     |          <integer>130</integer>
bad_dg_1     |      </dict>
bad_dg_1     |  </array>
bad_dg_1     | </dict>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000097278 "rtsp.c:3453"  SETUP response
bad_dg_1     |          0.000017648 "rtsp.c:3453"   Response Code: 200.
bad_dg_1     |          0.000014037 "rtsp.c:3453"   Type: "CSeq", content: "9"
bad_dg_1     |          0.000014333 "rtsp.c:3453"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000014611 "rtsp.c:3453"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000373537 "rtsp.c:3453"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict/>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000045630 "rtsp.c:5309" Connection 32 (RC): RTSP Response:
bad_dg_1     |          0.000016185 "rtsp.c:5310"   Response Code: 200.
bad_dg_1     |          0.000014074 "rtsp.c:5310"   Type: "CSeq", content: "9"
bad_dg_1     |          0.000015093 "rtsp.c:5310"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000014537 "rtsp.c:5310"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000131074 "rtsp.c:5310"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict/>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000036000 "rtsp.c:1535" Responding with content of length 42
bad_dg_1     |          0.222441167 "rtsp.c:5247" Connection 32 (RC): Received an RTSP Packet of type "TEARDOWN":
bad_dg_1     |          0.000047185 "rtsp.c:5249"   Type: "Content-Length", content: "42"
bad_dg_1     |          0.000017018 "rtsp.c:5249"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000020500 "rtsp.c:5249"   Type: "CSeq", content: "10"
bad_dg_1     |          0.000024778 "rtsp.c:5249"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000034093 "rtsp.c:5249"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict/>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000024648 "rtsp.c:2738" Connection 32: TEARDOWN 2 Remote Control stream.
bad_dg_1     |          0.000022241 "rtsp.c:2740" TEARDOWN:
bad_dg_1     |          0.000019277 "rtsp.c:2740"   Type: "Content-Length", content: "42"
bad_dg_1     |          0.000016815 "rtsp.c:2740"   Type: "Content-Type", content: "application/x-apple-binary-plist"
bad_dg_1     |          0.000021445 "rtsp.c:2740"   Type: "CSeq", content: "10"
bad_dg_1     |          0.000014555 "rtsp.c:2740"   Type: "User-Agent", content: "AirPlay/710.79.1"
bad_dg_1     |          0.000027982 "rtsp.c:2740"   Content Plist (as XML):
bad_dg_1     | --
bad_dg_1     | <?xml version="1.0" encoding="UTF-8"?>
bad_dg_1     | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
bad_dg_1     | <plist version="1.0">
bad_dg_1     | <dict/>
bad_dg_1     | </plist>
bad_dg_1     | --
bad_dg_1     |          0.000027648 "rtsp.c:2757" Connection 32: TEARDOWN Remote Control stream -- close the connection.
bad_dg_1     |          0.000022555 "rtsp.c:2664" Connection 32: TEARDOWN Remote Control stream connection.
bad_dg_1     |          0.000022574 "rtsp.c:2731" Connection 32: TEARDOWN Remote Control stream -- close the connection complete
bad_dg_1     |          0.000023167 "rtsp.c:5309" Connection 32 (RC): RTSP Response:
bad_dg_1     |          0.000015630 "rtsp.c:5310"   Response Code: 200.
bad_dg_1     |          0.000014833 "rtsp.c:5310"   Type: "CSeq", content: "10"
bad_dg_1     |          0.000013741 "rtsp.c:5310"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000015352 "rtsp.c:5310"   Type: "Connection", content: "close"
bad_dg_1     |          0.000015203 "rtsp.c:5310"   No Content Plist. Content length: 0.
bad_dg_1     |          0.029152556 "rtsp.c:1334" Connection 32: Connection closed by client.
bad_dg_1     |          0.000109222 "rtsp.c:5068" Connection 32: Remote Control stream rtsp_conversation_thread_func_cleanup_function called.
bad_dg_1     |          0.000024685 "rtsp.c:2664" Connection 32: TEARDOWN Remote Control stream connection.
bad_dg_1     |          0.000022223 "rtsp.c:2731" Connection 32: TEARDOWN Remote Control stream -- close the connection complete
bad_dg_1     |          0.000020277 "rtsp.c:5100" Connection 32: terminating -- closing RTSP connection socket 19: from 192.168.88.91:54858 to self at 192.168.88.8:7000.
bad_dg_1     |          0.000397000 "rtsp.c:5167" Connection 32: Closed.
bad_dg_1     |          0.000028371 "rtsp.c:5389" Connection 32: RTSP thread exit.
bad_dg_1     |          0.309040499 "rtp.c:468" New latency: 99180, sync latency: 88155, minimum latency: 0, maximum latency: 0, fixed offset: 11025, audio_backend_latency_offset: 0.000000.
bad_dg_1     |          0.000051852 "rtp.c:513" AP1 control thread: set_ntp_anchor_info: rtptime: 1607838135, networktime: 1ea97bde9e7d3453, frame adjustment:   0.000.
bad_dg_1     |          0.090442722 "dacp.c:803" DACP Composite ID seen
bad_dg_1     |          0.000036408 "dacp.c:771" DACP Track Name seen
bad_dg_1     |          0.000016074 "dacp.c:779" DACP Artist Name seen
bad_dg_1     |          0.000015278 "dacp.c:787" DACP Album Name seen
bad_dg_1     |          0.000014629 "dacp.c:795" DACP Genre seen
bad_dg_1     |          0.000014815 "dacp.c:825" DACP Song Time seen: "0" of length 4.
bad_dg_1     |          0.000670815 "dbus-service.c:226" Build metadata
bad_dg_1     |          0.000249722 "mpris-service.c:167" Build metadata
bad_dg_1     |          0.659081204 "rtp.c:771" clock synchronisation request: return time is    0.579 milliseconds.
bad_dg_1     |          0.079398166 "rtsp.c:5251" Connection 28: Received an RTSP Packet of type "SET_PARAMETER":
bad_dg_1     |          0.000048315 "rtsp.c:5253"   Type: "CSeq", content: "8"
bad_dg_1     |          0.000017593 "rtsp.c:5253"   Type: "User-Agent", content: "owntone/28.8"
bad_dg_1     |          0.000018870 "rtsp.c:5253"   Type: "Client-Instance", content: "68906BCA5356CD45"
bad_dg_1     |          0.000020444 "rtsp.c:5253"   Type: "DACP-ID", content: "68906BCA5356CD45"
bad_dg_1     |          0.000020445 "rtsp.c:5253"   Type: "Active-Remote", content: "3232258051"
bad_dg_1     |          0.000020055 "rtsp.c:5253"   Type: "Session", content: "1"
bad_dg_1     |          0.000015204 "rtsp.c:5253"   Type: "Content-Type", content: "text/parameters"
bad_dg_1     |          0.000021241 "rtsp.c:5253"   Type: "Content-Length", content: "44"
bad_dg_1     |          0.000015444 "rtsp.c:5253"   No Content Plist. Content length: 44.
bad_dg_1     |          0.000057519 "rtsp.c:5312" Connection 28: RTSP Response:
bad_dg_1     |          0.000017685 "rtsp.c:5313"   Response Code: 200.
bad_dg_1     |          0.000013574 "rtsp.c:5313"   Type: "CSeq", content: "8"
bad_dg_1     |          0.000013982 "rtsp.c:5313"   Type: "Server", content: "AirTunes/366.0"
bad_dg_1     |          0.000015555 "rtsp.c:5313"   No Content Plist. Content length: 0.
bad_dg_1     |          0.000187222 "metadata_hub.c:587" MH Progress String set to: "3954172641/3954203361/3954203361"
bad_dg_1     |          0.000506723 "dbus-service.c:226" Build metadata
bad_dg_1     |          0.001024907 "mpris-service.c:167" Build metadata
bad_dg_1     |          0.177975555 "rtp.c:468" New latency: 98991, sync latency: 87966, minimum latency: 0, maximum latency: 0, fixed offset: 11025, audio_backend_latency_offset: 0.000000.
bad_dg_1     |          0.000055815 "rtp.c:513" AP1 control thread: set_ntp_anchor_info: rtptime: 1607882676, networktime: 1ea97bdedab094d3, frame adjustment:   0.000.
bad_dg_1     |          0.108238963 "dacp.c:803" DACP Composite ID seen
bad_dg_1     |          0.000041111 "dacp.c:771" DACP Track Name seen
bad_dg_1     |          0.000017111 "dacp.c:779" DACP Artist Name seen
bad_dg_1     |          0.000015204 "dacp.c:787" DACP Album Name seen
bad_dg_1     |          0.000014093 "dacp.c:795" DACP Genre seen
bad_dg_1     |          0.000013703 "dacp.c:825" DACP Song Time seen: "0" of length 4.
bad_dg_1     |          0.000117445 "dbus-service.c:226" Build metadata
bad_dg_1     |          0.000218018 "mpris-service.c:167" Build metadata
bad_dg_1     |          0.901311092 "rtp.c:468" New latency: 99154, sync latency: 88129, minimum latency: 0, maximum latency: 0, fixed offset: 11025, audio_backend_latency_offset: 0.000000.
bad_dg_1     |          0.000069500 "rtp.c:513" AP1 control thread: set_ntp_anchor_info: rtptime: 1607927217, networktime: 1ea97bdf16e3f553, frame adjustment:   0.000.
bad_dg_1     |          0.109292371 "dacp.c:803" DACP Composite ID seen
bad_dg_1     |          0.000037203 "dacp.c:771" DACP Track Name seen
bad_dg_1     |          0.000016760 "dacp.c:779" DACP Artist Name seen
bad_dg_1     |          0.000015055 "dacp.c:787" DACP Album Name seen
bad_dg_1     |          0.000014556 "dacp.c:795" DACP Genre seen
bad_dg_1     |          0.000077963 "dacp.c:825" DACP Song Time seen: "0" of length 4.
bad_dg_1     |          0.000246222 "dbus-service.c:226" Build metadata
bad_dg_1     |          0.000361685 "mpris-service.c:167" Build metadata

System Information.

Raspberry Pi 4, multiple Shairport Sync instances using Docker

Configuration Information.

4.3.2-dev-60-g9732afb5-dirty-AirPlay2-smi10-alac-OpenSSL-Avahi-ALSA-pa-dummy-stdout-pipe-soxr-convolution-metadata-mqtt-dbus-mpris-sysconfdir:/etc

PulseAudio or PipeWire installed?

How did you install Shairport Sync?

Docker

Check previous issues

LemmoTresto commented 11 months ago

I also get this issue, looks like it's trying to connect to it in the background to show it as one of the available speakers. Just like how the Apple TV and HomePods are visible with 'Control other Speakers & TVs'.

Edit: this also happens sometimes when nothing is playing.

mikebrady commented 11 months ago

Thanks for this post. Yes indeed, this is a new behaviour, and IMHO it is related to the new "Automatic AirPlay" feature of AirPlay -- please see this MacRumors piece.

aaronk6 commented 11 months ago

That could be it. However, those messages keep appearing even when setting “Automatically AirPlay” to “Never” in Settings › General › AirPlay & Handoff. So it seems the handling in iOS 17 generally changed.

Is there anything I can do to help to fix this issue? I don’t have in-depth C knowledge and no understanding of the AirPlay protocol unfortunately, but if there is anything else I can do—such as narrowing it down further, testing certain specific combinations, etc.—I’m here.

mikebrady commented 11 months ago

Yeah, it’s puzzling alright. I don’t have an angle on how to deal with it at the moment, I’m afraid.

stevemurr commented 10 months ago

Hi,

I decided to look into this. On my network I have homepods, a denon and shairport-sync. I attached my phone to the computer ran rvictl -s <phone-uuid> to generate a network interface, then captured the phones traffic using wireshark. I compared the rtsp messages between the denon and shairport-sync. I focused on the difference between the feature hex:

Denon - TXT: ft=0x445F8A00,0x1C340 Shairport - TXT: features=0x405C4A00,0x1C340

Using this awesome documentation, I was able to compare the feature strings. It looks like the only difference was the HasUnifiedAdvertiserInfo bit is flipped on for Denon. When I flip the HasUnifiedAdvertiserInfo bit in shairport, I get this on client connection (using only -v the error message was No Content Plist).

0.000248847 "rtsp.c:1536" Responding with content of length 904  
0.005944702 "rtsp.c:5252" Connection 2: Received an RTSP Packet of type "POST":  
0.000019170 "rtsp.c:5254"   Type: "X-Apple-AbsoluteTime", content: "722553128"  
0.000005661 "rtsp.c:5254"   Type: "X-Apple-HKP", content: "6"  
0.000003643 "rtsp.c:5254"   Type: "X-Apple-Client-Name", content: "iPhone 14 Pro Max"  
0.000003492 "rtsp.c:5254"   Type: "X-Apple-PD", content: "1"  
0.000003165 "rtsp.c:5254"   Type: "Content-Length", content: "37"  
0.000003263 "rtsp.c:5254"   Type: "Content-Type", content: "application/octet-stream"  
0.000003328 "rtsp.c:5254"   Type: "CSeq", content: "1"  
0.000003477 "rtsp.c:5254"   Type: "DACP-ID", content: "1B1221F9052E490A"  
0.000003063 "rtsp.c:5254"   Type: "Active-Remote", content: "2455355829"  
0.000003613 "rtsp.c:5254"   Type: "User-Agent", content: "AirPlay/750.13.1"  
0.000003517 "rtsp.c:5254"   No Content Plist. Content length: 37.  
0.000005684 "rtsp.c:2205" Connection 2: pair-verify Content-Length 37  
0.000520183 "rtsp.c:2241" pair-verify response  
0.000011536 "rtsp.c:2241"   Response Code: 200.  
0.000003868 "rtsp.c:2241"   Type: "CSeq", content: "1"  
0.000003380 "rtsp.c:2241"   Type: "Server", content: "AirTunes/366.0"  
0.000003443 "rtsp.c:2241"   Type: "Content-Type", content: "application/octet-stream"  
0.000003543 "rtsp.c:2241"   No Content Plist. Content length: 140.  
0.000003321 "rtsp.c:5313" Connection 2: RTSP Response:  
0.000003222 "rtsp.c:5314"   Response Code: 200.  
0.000003073 "rtsp.c:5314"   Type: "CSeq", content: "1"  
0.000003520 "rtsp.c:5314"   Type: "Server", content: "AirTunes/366.0"  
0.000003303 "rtsp.c:5314"   Type: "Content-Type", content: "application/octet-stream"  
0.000003538 "rtsp.c:5314"   No Content Plist. Content length: 140.  
0.000005134 "rtsp.c:1536" Responding with content of length 140  
0.046515683 "rtsp.c:5252" Connection 2: Received an RTSP Packet of type "POST":  
0.000034468 "rtsp.c:5254"   Type: "X-Apple-AbsoluteTime", content: "722553128"  
0.000005648 "rtsp.c:5254"   Type: "X-Apple-HKP", content: "4"  
0.000003906 "rtsp.c:5254"   Type: "X-Apple-Client-Name", content: "iPhone 14 Pro Max"  
0.000005144 "rtsp.c:5254"   Type: "Content-Length", content: "9"  
0.000010559 "rtsp.c:5254"   Type: "Content-Type", content: "application/x-apple-binary-plist"  
0.000008831 "rtsp.c:5254"   Type: "CSeq", content: "2"  
0.000006738 "rtsp.c:5254"   Type: "DACP-ID", content: "1B1221F9052E490A"  
0.000006415 "rtsp.c:5254"   Type: "Active-Remote", content: "2455355829"  
0.000006551 "rtsp.c:5254"   Type: "User-Agent", content: "AirPlay/750.13.1"  
0.000007912 "rtsp.c:5254"   No Content Plist. Content length: 9.  
0.000009065 "rtsp.c:2249" Connection 2: handle_pair-setup Content-Length 9  
0.006672357 "rtsp.c:2287" pair-setup response  
0.000007971 "rtsp.c:2287"   Response Code: 200.  
0.000001821 "rtsp.c:2287"   Type: "CSeq", content: "2"  
0.000007490 "rtsp.c:2287"   Type: "Server", content: "AirTunes/366.0"  
0.000001479 "rtsp.c:2287"   Type: "Content-Type", content: "application/octet-stream"  
0.000001684 "rtsp.c:2287"   No Content Plist. Content length: 409.  
0.000001723 "rtsp.c:5313" Connection 2: RTSP Response:  
0.000001264 "rtsp.c:5314"   Response Code: 200.  
0.000001189 "rtsp.c:5314"   Type: "CSeq", content: "2"  
0.000001150 "rtsp.c:5314"   Type: "Server", content: "AirTunes/366.0"  
0.000001166 "rtsp.c:5314"   Type: "Content-Type", content: "application/octet-stream"  
0.000001263 "rtsp.c:5314"   No Content Plist. Content length: 409.  
0.000002362 "rtsp.c:1536" Responding with content of length 409  
0.042485998 "rtsp.c:5252" Connection 2: Received an RTSP Packet of type "POST":  
0.000033536 "rtsp.c:5254"   Type: "X-Apple-AbsoluteTime", content: "722553128"  
0.000005421 "rtsp.c:5254"   Type: "X-Apple-HKP", content: "4"  
0.000003878 "rtsp.c:5254"   Type: "X-Apple-Client-Name", content: "iPhone 14 Pro Max"  
0.000003459 "rtsp.c:5254"   Type: "Content-Length", content: "457"  
0.000003875 "rtsp.c:5254"   Type: "Content-Type", content: "application/x-apple-binary-plist"  
0.000003705 "rtsp.c:5254"   Type: "CSeq", content: "3"  
0.000003638 "rtsp.c:5254"   Type: "DACP-ID", content: "1B1221F9052E490A"  
0.000003698 "rtsp.c:5254"   Type: "Active-Remote", content: "2455355829"  
0.000003433 "rtsp.c:5254"   Type: "User-Agent", content: "AirPlay/750.13.1"  
0.000003928 "rtsp.c:5254"   No Content Plist. Content length: 457.  
0.000007056 "rtsp.c:2249" Connection 2: handle_pair-setup Content-Length 457  
0.012046191 "rtsp.c:2287" pair-setup response  
0.000013102 "rtsp.c:2287"   Response Code: 200.  
0.000003956 "rtsp.c:2287"   Type: "CSeq", content: "3"  
0.000003130 "rtsp.c:2287"   Type: "Server", content: "AirTunes/366.0"  
0.000003431 "rtsp.c:2287"   Type: "Content-Type", content: "application/octet-stream"  
0.000003743 "rtsp.c:2287"   No Content Plist. Content length: 69.  
0.000003476 "rtsp.c:5313" Connection 2: RTSP Response:  
0.000003082 "rtsp.c:5314"   Response Code: 200.  
0.000004431 "rtsp.c:5314"   Type: "CSeq", content: "3"  
0.000006788 "rtsp.c:5314"   Type: "Server", content: "AirTunes/366.0"  
0.000006387 "rtsp.c:5314"   Type: "Content-Type", content: "application/octet-stream"  
0.000006554 "rtsp.c:5314"   No Content Plist. Content length: 69.  
0.000008616 "rtsp.c:1536" Responding with content of length 69  
0.014536483 "rtsp.c:5252" Connection 2: Received an RTSP Packet of type "POST":  
0.000031469 "rtsp.c:5254"   Type: "Content-Length", content: "33"  
0.000004987 "rtsp.c:5254"   Type: "Content-Type", content: "application/octet-stream"  
0.000003651 "rtsp.c:5254"   Type: "CSeq", content: "4"  
0.000005241 "rtsp.c:5254"   Type: "DACP-ID", content: "1B1221F9052E490A"  
0.000007743 "rtsp.c:5254"   Type: "Active-Remote", content: "2455355829"  
0.000007149 "rtsp.c:5254"   Type: "User-Agent", content: "AirPlay/750.13.1"  
0.000007347 "rtsp.c:5254"   No Content Plist. Content length: 33.  
0.000009516 "rtsp.c:2576" Connection 2: Unhandled POST /auth-setup Content-Length 33  
0.000044648 "rtsp.c:2578" POST request  
0.000007576 "rtsp.c:2578"   Type: "Content-Length", content: "33"  
0.000006749 "rtsp.c:2578"   Type: "Content-Type", content: "application/octet-stream"  
0.000006428 "rtsp.c:2578"   Type: "CSeq", content: "4"  
0.000007476 "rtsp.c:2578"   Type: "DACP-ID", content: "1B1221F9052E490A"  
0.000007499 "rtsp.c:2578"   Type: "Active-Remote", content: "2455355829"  
0.000007807 "rtsp.c:2578"   Type: "User-Agent", content: "AirPlay/750.13.1"  
0.000005651 "rtsp.c:2578"   No Content Plist. Content length: 33.  
0.000007271 "rtsp.c:5313" Connection 2: RTSP Response:  
0.000007116 "rtsp.c:5314"   Response Code: 200.  
0.000006858 "rtsp.c:5314"   Type: "CSeq", content: "4"  
0.000006480 "rtsp.c:5314"   Type: "Server", content: "AirTunes/366.0"  
0.000007416 "rtsp.c:5314"   No Content Plist. Content length: 0.  
0.014039267 "rtsp.c:1335" Connection 2: Connection closed by client.

The auth-setup page on the airplay site describes the steps to support HasUnifiedAdvertiserInfo. I wanted to give you a ping to get your thoughts before I dig into the auth steps to support this.

LemmoTresto commented 10 months ago

This is great, maybe this could also help with the homekit integration not showing what it is playing when someone else is playing it.

mikebrady commented 10 months ago

Thanks for the post, and thanks for the rvictl hint! Basically any progress that could be made on this front would be most welcome. The documentation on that site is indeed super.

Unfortunately, however, it looks as though HasUnifiedAdvertiserInfo enables a protocol that requires the device to have an Apple-approved IC -- the MFi chip, which seems to supply some kind of authentication information. Without it, we seem to be at a dead end. I'd love to be wrong about that!

MrMuetze commented 10 months ago

It seems for me this happens regularly when disconnecting from my raspberry pi and then shairport-sync crashes. I have used this setup together with my HomePod a lot in these situations. I also then get the message in my Apple TV as well. If I can help out with more tests or anything else just let me know. :)

mikebrady commented 10 months ago

It seems for me this happens regularly when disconnecting from my raspberry pi and then shairport-sync crashes. I have used this setup together with my HomePod a lot in these situations. I also then get the message in my Apple TV as well. If I can help out with more tests or anything else just let me know. :)

Thanks. If you could work out how to reproduce that crash, it would be useful!

MrMuetze commented 10 months ago

Ah when investigating this I had to realize that my crash is probably unrelated to the "Unable to connect" message. Might be more of a output_device_error_19 situation. I'll keep an eye on it though and see if it keeps happening after I hopefully improve the other situation. 😅

mikebrady commented 10 months ago

Ah when investigating this I had to realize that my crash is probably unrelated to the "Unable to connect" message. Might be more of a output_device_error_19 situation. I'll keep an eye on it though and see if it keeps happening after I hopefully improve the other situation. 😅

Thanks!

stevemurr commented 10 months ago

@mikebrady - As of this morning, I am no longer seeing this issue. I'm able to connect to an active session from all of my devices however volume, track position and play/pause are non-functional for devices who connect to an active session. However, next track is functional for devices connecting to an active session. If I leave all devices connected to the session they update song information correctly. Is anyone else seeing this behavior?

Note: If I add the speaker to the home app I get the same behavior as before - speaker adds but shows "no response" after approx. 1 minute.

aaronk6 commented 9 months ago

@stevemurr @mikebrady I noticed that the openairplay guys have an experimental implementation of an AirPlay 2 receiver in Python here: https://github.com/openairplay/airplay2-receiver

I got it working and saw that the “Unable to Connect” issue does not occur when sending audio to this receiver and opening the AirPlay device list on another device. So it looks like they’re doing something right. 🙂

I guess from here, we could compare the RTSP messages and see what the differences are. @mikebrady, do you think this is a reasonable approach? If so, I’m happy to dive in.

By the way, I also took a look at the features that each receiver is announcing:

So shareport-sync announces all the features that openairplay announces, plus:

(per https://openairplay.github.io/airplay-spec/features.html)

So HasUnifiedAdvertiserInfo is probably not the culprit here.

aaronk6 commented 9 months ago

I made an interesting discovery today. It looks to me as if version 4.3 is not affected by the bug. I tried various versions, but only with version 4.3, the “Unable to Connect” message woudn’t appear.

I ran the following steps for each version:

  1. Connect to shairport-sync with Apple Music on the Mac
  2. Start playback in Apple Music on the Mac
  3. Open AirPlay device view on an iPhone
  4. Wait 30 seconds to see if the “Unable to Connect” message appears (it usually appears immediately, but just to be sure)

Result:

SPS Version Behavior on iOS 17.2.1
latest (4.3.2) “Unable to connect” message
4.3.1 “Unable to connect” message
4.3 ✅ (“Unable to connect” didn’t show up)
4.2 “Unable to connect” message
4.1.1 Unreliable playback + “Unable to connect” message

I tested with:

sudo docker run --net host --device /dev/snd mikebrady/shairport-sync:$VERSION -a shairport-test-$VERSION -vv

(Where $VERSION is the respective version shown in the table above.)

I went over the table 3 times and got reproducible results.

@stevemurr Would you mind trying version 4.3 on your end to confirm my findings?

@mikebrady Any idea what this might be? I remember noticing the problem after you fixed the session interruption crashes in #1723. This coincided with the release of iOS 17 which could have led us on the wrong track.

herdingdata commented 9 months ago

Hello. I'm experiencing this issue too! Let me know if I can help with any troubleshooting info. I'm not running shairport-sync in a docker container, it's just installed direct to my pi. Are there any installation steps to switching version?

It's happening when I'm airplaying from an ipad (ipados 17.0.3) to my raspberry pi (shairport sync 4.3.2). The error itself appears on an apple tv on the same network (tvos 17.2). I've also seen it on the apple tv when airplaying from another macbook to the same pi - the macbook was just updated to sonoma 14.0 but it was occurring whilst said macbook was on ventura 13.x, though I believe tvOS was already 17.2 in all instances.

aaronk6 commented 9 months ago

Hi @herdingdata! Did you build from source using this guide? If so, you can check out a specific version like this while in the source repo folder:

$ git checkout 4.3

And then redo the usual steps to build and install.

Verify if it succeeded using:

$ shairport-sync -V
mikebrady commented 8 months ago

Many thanks @aaronk6 and @herdingdata for your discoveries and comments. This "cannot connect" problem seems to be related to extra remote control protocols that, unfortunately, we don't seem to know too much about. The protocols also seem to be changing quite rapidly between different version of iOS and homePodOS. We have experimented with using different combinations of feature flags, but it's really hard to make out anything definitive. The version table produced by @aaronk6 is very useful, thanks, and we will review it. Separately, IRL, I'll be away from my computers until the end of January.

aaronk6 commented 8 months ago

Hi @mikebrady, thanks for checking in! For the time being, I’ve downgraded to version 4.3 to work around the issue. Enjoy your time away from the computers! I’m happy to test any changes once you’re back. I’ve just updated my post above to indicate that these tests were performed on iOS 17.2.1. If helpful, I can re-run those tests on other iOS versions, too.

stevemurr commented 8 months ago

Hi @aaronk6 - I installed 4.3 and have confirmed that I no longer see the "Unable to Connect" messages.

There is a side effect of this version for me.

4.3.2

(Person A, Device A) - starts playback (Person A, Device B) - no "Unable to Connect", can connect to a running session through the control center. (Person B, Device A) - sees "Unable to Connect". Can see the running session, but the block will just say "tap to connect" and if the user taps this, the unable to connect dialogue is shown.

4.3

(Person A, Device A) - starts playback (Person A, Device B) - no "Unable to Connect", is unable to connect to a running session through control center. (Person B, Device A) - no "Unable to Connect". The running session is not visible in the control center.

Assumptions

My intuition for HasUnifiedAdvertiserInfo came from the Denon receiver on my network sent the HasUnifiedAdvertiserInfo bit and did not show unable to connect and was controllable through the control center from any person on the network.

I assumed Unable to Connect error is being shown when the device fails this auth handshake. I further assume that this auth handshake became mandatory in iOS 17 which also provides an explanation for homekit integration issues.

@mikebrady mentioned that to enable HasUnifiedAdvertiserInfo would possibly require a hardware chip for authentication to succeed. I think the hardware chip is required for mass market products.

However, there might be a workaround with the HomekitADK. I use shelly switches and flash them with this firmware to make them native homekit devices. This firmware generates the auth parts, but just notifies the user that the device is unverified.

Here is a snippet from that project, that shows the mfi token auth process.

static struct HAPPlatformMFiTokenAuth s_mfi_auth;
  HAPPlatformMFiTokenAuthOptions mfi_opts = {};
  HAPPlatformMFiTokenAuthCreate(&s_mfi_auth, &mfi_opts);
  HAPPlatform platform = {
      .keyValueStore = &s_kvs,
      .accessorySetup = &s_accessory_setup,
      .setupDisplay = nullptr,
      .setupNFC = nullptr,
      .ip =
          {
              .tcpStreamManager = &s_tcpm,
              .serviceDiscovery = &s_service_discovery,
          },
      .ble =
          {
              .blePeripheralManager = nullptr,
          },
      .authentication =
          {
              .mfiHWAuth = nullptr,
              .mfiTokenAuth = &s_mfi_auth,
          },
  };

@aaronk6 - thanks for joining in on this! Let me know what you think of the above.

github-actions[bot] commented 6 months ago

This issue has been inactive for 28 days so will be closed 7 days from now. To prevent this, please remove the "stale" label or post a comment.

aaronk6 commented 6 months ago

@stevemurr I didn’t find the time yet to have a detailed look at your findings and get back to you. I promise to do that soon!

@mikebrady In the meantime, can you reopen the issue? I’m really hoping that we find a solution here because I’m stuck on version 4.3 because of this.

aaronk6 commented 1 week ago

I’ve revisited this with shairport-sync 4.3.4 and iOS 18.0 and it seems the error is gone. I will monitor this carefully over the coming days, but my steps to reproduce from above don’t lead to the error anymore:

@stevemurr Would you mind trying this on your end? Apologies for not getting back earlier!