WebRTC softphone media drops on Sydney edge during ACMA compliance check

Pushed the latest softphone config via Terraform v1.44.2 to mypurecloud.com.au this morning. Console’s showing green, but the WebRTC session tears down exactly when the ACMA recording prompt triggers. Looking at the browser console, the iceConnectionState flips to failed after about 3.2 seconds. SDP negotiation works, but the media path never establishes. Sydney edge latency is sitting around 280ms, which is usually acceptable, but something’s choking on the compliance payload.

Checked the /api/v2/interactions endpoint logs. Returns a 408 Request Timeout right after the recording: true flag gets applied in the Architect flow. Flow version is 18. ACMA mandates that timestamp format must match yyyy-MM-ddTHH:mm:ss+10:00 for AEST, but the softphone SDK v3.8.1 doesn’t seem to handle the offset correctly before sending it upstream. Network traces show the STUN bindings working, then silence. Tried forcing turn:turn.sydney.mypurecloud.com.au in the config, still drops. The raw packet capture shows the BYE message arriving before the first RTP frame even leaves the client buffer.

The ACMA prompt likely triggers a local media restart that clashes with the high-latency Sydney edge. When the recording state changes, the client sends a new SDP offer. If the ice candidates haven’t fully refreshed before the timeout, the connection drops. You’ll need to force a re-negotiation with a longer ICE gathering timeout in your WebRTC config.

Try injecting this into your createPeerConnection options:

const rtcConfig = {
 iceServers: [
 { urls: 'stun:stun.l.google.com:19302' },
 // Add your Genesys TURN server here
 ],
 iceTransportPolicy: 'all',
 bundlePolicy: 'max-bundle',
 rtcpMuxPolicy: 'require'
};

Also, check if the recordingConsent event is firing before the iceConnectionState stabilizes. You might need to pause the media stream briefly during the consent phase. It’s a common gotcha with strict compliance regions. The 3.2s drop matches the default ICE failure timeout. Increasing it slightly or forcing a trickle ICE update usually fixes the handshake.