Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

call failed with cause: Code: [488], Cause: Incompatible SDP, Reason: Not Acceptable Here #50

Closed
stuartwk opened this issue Jan 7, 2020 · 11 comments

Comments

@stuartwk
Copy link

stuartwk commented Jan 7, 2020

When trying to make a call, I am getting the error call failed with cause: Code: [488], Cause: Incompatible SDP, Reason: Not Acceptable Here. I emailed my provider, Telnyx, and they responded...

"So a 488 response is generally related to a bad media parameter in your SIP INVITEs SDP body, which our system does not like.
Upon inspection, your SDP is quite big and you can see the pasted version below.
It's hard to tell which one's could be the parameters we don't like but what catches my attention straight away are the candidates.
it appears this SIP Client is listing candidates in IPV6 and I'm pretty sure we don't support this.
The other candidate, that is IPV4, is a private IP address as-well.
If you can remove the IPV6 candidates or change them into public IPV4 addresses, that should do the trick."

Is it possible to force IPV4 use in the config when initiating a call? Thanks!

@stuartwk
Copy link
Author

stuartwk commented Jan 7, 2020

Here's the SDP if that's helpful...

v=0
o=- 127143737164406393 2 IN IP4 127.0.0.1
s=-
t=0 0
a=group:BUNDLE audio
a=msid-semantic: WMS 737E4B7F-FC6A-40F0-B7DD-1D7F6E1CA4B4
m=audio 55041 UDP/TLS/RTP/SAVPF 111 103 104 9 102 0 8 106 105 13 110 112 113 126
c=IN IP4 10.196.59.199
a=rtcp:9 IN IP4 0.0.0.0
a=candidate:3729240026 1 udp 2122262783 240a:5:48d1:b2a2:692a:9e68:8d02:5a58 64116 typ host generation 0 network-id 6 network-cost 900
a=candidate:3140742186 1 udp 2122194687 10.196.59.199 55041 typ host generation 0 network-id 5 network-cost 900
a=candidate:1042328315 1 udp 2122131711 240a:5:48d1:b2a2:1c28:5582:5299:32e9 55042 typ host generation 0 network-id 1 network-cost 50
a=candidate:1042328315 1 udp 2122066175 240a:5:48d1:b2a2:1c28:5582:5299:32e9 55043 typ host generation 0 network-id 2 network-cost 50
a=ice-ufrag:vGwb
a=ice-pwd:somepasswordhere
a=ice-options:trickle renomination
a=fingerprint:sha-256 36:08:E5:33:27:CF:4E:20:35:82:34:AA:07:0A:EB:5E:1F:72:39:21:D3:19:EA:2A:AE:9D:DE:F1:2A:DE:59:66
a=setup:actpass
a=mid:audio
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=extmap:2 http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01
a=sendrecv
a=rtcp-mux
a=rtpmap:111 opus/48000/2
a=rtcp-fb:111 transport-cc
a=fmtp:111 minptime=10;useinbandfec=1
a=rtpmap:103 ISAC/16000
a=rtpmap:104 ISAC/32000
a=rtpmap:9 G722/8000
a=rtpmap:102 ILBC/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:106 CN/32000
a=rtpmap:105 CN/16000
a=rtpmap:13 CN/8000
a=rtpmap:110 telephone-event/48000
a=rtpmap:112 telephone-event/32000
a=rtpmap:113 telephone-event/16000
a=rtpmap:126 telephone-event/8000
a=s

@cloudwebrtc
Copy link
Member

@stuartkuentzel I think you can add 'googIPv6': false to the constraint parameter when createPeerConnection, or manually modify the sdp to remove the ipv6 candidate.

@stuartwk
Copy link
Author

stuartwk commented Jan 9, 2020

@cloudwebrtc thanks for the reply! I'm looking around SIPUAHelper, and I'm not seeing where I would put createPeerConnection. Is this something I would set in the SIPUAHelper? Digging around a bit, I see https://github.com/cloudwebrtc/dart-sip-ua/blob/224d14d0a160a3ec7b8b02434c81459cf49c06df/lib/src/ua.dart#L240 takes options, but in helper.call, it only takes String for target and a bool for voiceOnly. Not sure if I'm on the right track here...

@xal
Copy link

xal commented Jan 30, 2020

@stuartkuentzel You can add constraint at rtc_peer_connection_factory.dart. For example

Future<RTCPeerConnection> createPeerConnection(
    Map<String, dynamic> configuration,
    Map<String, dynamic> constraints) async {
  MethodChannel channel = WebRTC.methodChannel();

  Map<String, dynamic> defaultConstraints = {
    "mandatory": {},
    "optional": [
      {"DtlsSrtpKeyAgreement": true},
    ],
  };

  var selectedConstraints = constraints.length == 0 ? defaultConstraints :
  constraints;

  selectedConstraints["googIPv6"] = false;

  print("selectedConstraints $selectedConstraints");

  final Map<dynamic, dynamic> response = await channel.invokeMethod(
    'createPeerConnection',
    <String, dynamic>{
      'configuration': configuration,
      'constraints': selectedConstraints
    },
  );

  String peerConnectionId = response['peerConnectionId'];
  return new RTCPeerConnection(peerConnectionId, configuration);
}

@ghenry
Copy link
Collaborator

ghenry commented Feb 9, 2020 via email

@ghost
Copy link

ghost commented Feb 19, 2020

@stuartkuentzel were you able to make dart-sip-ua work with Telnyx?
I have a Telnyx account and I am trying to make it work too.

@ghenry
Copy link
Collaborator

ghenry commented Feb 24, 2020 via email

@ghost
Copy link

ghost commented Feb 24, 2020

@ghenry
Hi
Yes tryit works with Telnyx, I just called my iPhone from tryit via Telnyx

tryit webform values:

sip uri: sip:<username>@sip.telnyx.com
websocket uri: wss://sip.telnyx.com:7443
transport: tls or wss
registrar server: sip:sip.telnyx.com
password: *******

@ghost
Copy link

ghost commented Feb 26, 2020

@cloudwebrtc can you test on Telnyx or SignalWire?

@ghenry ghenry closed this as completed May 28, 2020
@ghost
Copy link

ghost commented May 31, 2020

why is it closed? is it fixed?

@NevilleAdrian
Copy link

Hello Please is this fixed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants