i am still dying on this one, and my critical user, my fiance'e, is giving me hell over it on my home test environment; even my daytime job, for which i am prototyping, is more patient. :-) i can not get caller-id from a call coming in to the spa3k pstn to asterisk. fwiw, this used to work with older * and spa3k versions, but of course it could be something i did to configs. essentially, if i tell the spa3k to pass callerid to *, the sip session gets rejected by *. since no one seemed to like to see ethereal output, i have posted * sip debug form of the sessions. does anyone have their spa3k and * config working that i could look at? or, if you can shoot the bug, i'll pay you US$100 by paypal or whatever. the spa3k configiuration <http://rip.psg.com/~randy/spa3k.html> sip debug with spa3k config set to PSTN / PSTN-To-VoIP Gateway Setup / PSTN CID For VoIP CID: = NO call accepted ok, but no callerid received by asterisk <http://rip.psg.com/~randy/debug-0.txt> sip debug with spa3k config set to PSTN / PSTN-To-VoIP Gateway Setup / PSTN CID For VoIP CID: = YES call rejected by asterisk <http://rip.psg.com/~randy/debug-1.txt> sip.conf entry [spa3k-in] type=friend ; user fails to register host=dynamic port=5061 auth=md5 secret=dontbesilly qualify=1000 dtmfmode=rfc2833 canreinvite=yes context=ext-in42 extensions.conf for the incoming [ext-in42] exten => _X.,1,NoOp("ext-in42 cid=${CALLERIDNUM}") exten => _X.,2,SetVar(areacode=206) exten => _X.,3,SetVar(mailbox=1) exten => _X.,4,GoTo(ext-common,s,1) [ext-common] exten => s,1,NoOp("ext-common cid=${CALLERIDNUM}") exten => s,2,Background(zz-who-common) exten => i,1,Hangup() exten => t,1,GoTo(ext-common,s,1) include => speeddials include => extensions include => conferences include => applications randy
Matt Riddell
2004-Nov-07 19:55 UTC
[Asterisk-Users] getting callerid from spa3k to asterisk
Randy Bush wrote:> essentially, if i tell the spa3k to pass callerid to *, the sip > session gets rejected by *. since no one seemed to like to see > ethereal output, i have posted * sip debug form of the sessions.You could maybe look at the autocreatepeer option for sip.conf - just a wild guess so YMMV. BTW: Sorry didn't click through to your traces so this might be pointless! :-) Think that's enough disclaimers! -- Cheers, Matt Riddell _______________________________________________ http://www.sineapps.com/news.php (Daily Asterisk News - html) http://www.sineapps.com/rssfeed.php (Daily Asterisk News - rss)
Randy Bush
2004-Nov-08 11:28 UTC
[Asterisk-Users] Re: getting callerid from spa3k to asterisk
> You could maybe look at the autocreatepeer option for sip.confthat level of vulnerability would not seem to be a good approach to solving some sort of sip/config problem :-) the problem is in the sip handshake between the spa3k and *. i have been hoping a sip geek would have a chance to look at it. randy
Jason Williams
2004-Nov-11 06:31 UTC
[Asterisk-Users] Re: getting callerid from spa3k to asterisk
You could try adding the line insecure=very to the relevant section of the sip.conf this would force asterisk to only validate the IP address and not the user name (possibly but it is woth a shot) Jason On Mon, 8 Nov 2004 10:28:03 -0800, Randy Bush <randy@psg.com> wrote:> > You could maybe look at the autocreatepeer option for sip.conf > > that level of vulnerability would not seem to be a good approach > to solving some sort of sip/config problem :-) > > the problem is in the sip handshake between the spa3k and *. i > have been hoping a sip geek would have a chance to look at it. > > randy > > > > _______________________________________________ > Asterisk-Users mailing list > Asterisk-Users@lists.digium.com > http://lists.digium.com/mailman/listinfo/asterisk-users > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users >
ok, with a good pointer from Chris Stenton <jacs@gnome.co.uk>, i found the problem. if i have two sip contexts for my spa3k, on inbound and one outbound, e.g. [spa3k-out] type=peer auth=md5 secret=pfui username=outpass fromuser=outpass host=spa3k.bogus.com port=5061 nat=no canreinvite=yes context=ext-in42 [spa3k-in] type=friend host=dynamic port=5061 auth=md5 secret=pfui qualify=1000 canreinvite=yes context=ext-in42 and the spa3k's PSTN / Subscriber Information / User ID: = spack-in, the incoming connection from spa3k to * is being routed to the spa3k-out context, not the spa3-in context. see appended. i suspect this is a bug in * 1.0.1. so, until the problem is diagnosed, how do i work around it. as the spa3k is registered, i tried to remove the spa3k-out context entirely. callerid now works. yes! but ... if i try to place an outbound call using the spa3k-in context, the call is sent to the spa3k, but it just gives me the pstn's dialtone, and does not dial the number. my spa3k config is in <http://rip.psg.com/~randy/spa3k.html>. so how do i place a call out the spa3k pstn without a separate outbound context? randy --- Sip read: INVITE sip:105@asterisk.bogus.com SIP/2.0 Via: SIP/2.0/UDP 198.180.150.195:5061;branch=z9hG4bK-69580ec1 From: CallerName <sip:2065551212@asterisk.bogus.com>;tag=25aee11517d597a1o1 To: <sip:105@asterisk.bogus.com> Remote-Party-ID: CallerName <sip:2065551212@asterisk.bogus.com>;screen=yes;party=calling Call-ID: 8816a525-dbaa22d1@198.180.150.195 CSeq: 101 INVITE Max-Forwards: 70 Contact: biwa 0431 <sip:spa3k-in@198.180.150.195:5061> Expires: 240 User-Agent: Sipura/SPA3000-2.0.11(GWa) Content-Length: 428 Allow: ACK, BYE, CANCEL, INFO, INVITE, NOTIFY, OPTIONS, REFER Supported: x-sipura Content-Type: application/sdp v=0 o=- 8805171 8805171 IN IP4 198.180.150.195 s=- c=IN IP4 198.180.150.195 t=0 0 m=audio 16396 RTP/AVP 0 2 4 8 18 96 97 98 100 101 a=rtpmap:0 PCMU/8000 a=rtpmap:2 G726-32/8000 a=rtpmap:4 G723/8000 a=rtpmap:8 PCMA/8000 a=rtpmap:18 G729a/8000 a=rtpmap:96 G726-40/8000 a=rtpmap:97 G726-24/8000 a=rtpmap:98 G726-16/8000 a=rtpmap:100 NSE/8000 a=rtpmap:101 telephone-event/8000 a=fmtp:101 0-15 a=ptime:30 a=sendrecv 15 headers, 19 lines Using latest request as basis request Sending to 198.180.150.195 : 5061 (non-NAT) Found RTP audio format 0 Found RTP audio format 2 Found RTP audio format 4 Found RTP audio format 8 Found RTP audio format 18 Found RTP audio format 96 Found RTP audio format 97 Found RTP audio format 98 Found RTP audio format 100 Found RTP audio format 101 Peer audio RTP is at port 198.180.150.195:16396 Found description format PCMU Found description format G726-32 Found description format G723 Found description format PCMA Found description format G729a Found description format G726-40 Found description format G726-24 Found description format G726-16 Found description format NSE Found description format telephone-event Capabilities: us - 0xe(GSM|ULAW|ALAW), peer - audio=0x51d(G723|ULAW|ALAW|G726|G729A|ILBC)/video=0x0(EMPTY), combined - 0xc(ULAW|ALAW) Non-codec capabilities: us - 0x1(G723), peer - 0x1(G723), combined - 0x1(G723) Found peer 'spa3k-out'
Randy Bush
2004-Nov-13 20:11 UTC
[Asterisk-Users] Re: getting callerid from spa3k to asterisk
> if i have two sip contexts for my spa3k, on inbound and > one outbound, e.g. > > [spa3k-in] > type=friend > host=dynamic > port=5061 > auth=md5 > secret=pfui > qualify=1000 > canreinvite=yes > context=ext-in42 > > [spa3k-out] > type=peer > auth=md5 > secret=pfui > username=outpass > fromuser=outpass > host=spa3k.bogus.com > port=5061 > nat=no > canreinvite=yes > context=ext-in42 > > and the spa3k's PSTN / Subscriber Information / User ID: = spack-in, > > the incoming connection from spa3k to * is being routed to the > spa3k-out context, not the spa3-in context. see appended. > > i suspect this is a bug in * 1.0.1.i found the problem, or at least a work-around. if i reverse the order of the above two sip contexts, the incoming call is properly routed to the spa3k-in sip context as opposed to the wrong one, spa3k-out. my guess is that * is traversing a list and taking the first context which has the ip address and port it wants without checking the context name against the name which was received over the wire. so it depends on what order the contexts are inserted in the list. aiiiiiiiiiiiiiiiiiiiiii! randy