FreePBX does not implement point-to-point by default for SIP data on the IPv6 protocol. Which configuration files should be modified to achieve this?

Today, when I dialed an IP phone number, I also checked the data flow of the SIP client.
I found a strange problem, that is, all SIP data flows to my FreePBX server, but the IP phone number I need to call is not in the intranet where my FreePBX server is located, and I and the IP phone number I need to call are both registered on the IPv6 port of SIP-TLS.
This transit behavior adds extra delay to the already unstable SIP transmission. Both ends of the call are on the IPv6 network and can access each other. Is there any way to make the IP phones connected to my own FreePBX server under the IPv6 link directly point-to-point?

Are both locations under the same subnet? Because even doing this with a /127 requires both sides of the P2P to be on the /127. Something like:

2001:db8::2/127
– 2001:db8::2 ← Router A
– 2001:db8::3 ← Router B

Could you please provide a diagram. I read this twice and I’m still not sure what you are trying to say, although I think some of your references should actually be to RTP.

If you are talking about direct media (direct routing of RTP), a number of conditions have to be met, before this is possible. As well as both sides needing to negotiate exactly the same codecs and DTMF mode, not be marked as ineligible for direct media, and having visibility of the other’s media address, you must disable all FreePBX options that require access to the media stream. These include call recording, listening in on channels and whispering to them, and, at least for DTMFMode inband or rfcxxxx, the use of DTMF feature codes, such as parking and call transfer (removing the enabling options from the Dial application options.

You also need to disable SRTP (media encryption), as keys are never negotiated end to end, so Asterisk must decrypt under the key for one leg and re-encrypt under the key for the other leg). I’m not sure if signalling encryption is a blocker, but most people want both.

The two locations are in different /64 IPv6 subnets, but they are routable and can access each other.

That doesn’t mean they can be point to point. You just described how IPv6 functions normally. A true PtoP link will be on the same subnet.

I am not sure how this solves poor network speeds