Yet another "incoming SIP connection from unknown peer" problem

I have a problem with not being able to receive incoming phone calls. To give some background: incoming phone calls work if I set “Allow Anonymous Inbound SIP Calls” to yes. I have an inbound route set with my DID. In addition, I’ve tried clearing all the INCOMING settings, to no avail. And as with some other posts, I have the same issue that Asterisk can’t seem to identify the peer. I’ve been tearing my hair out on this and have searched these forums and couldn’t seem to find an answer that fit my problem. I used the trunk settings provided to me by the SIP provider (Switch2Voip.us). Help would be greatly appreciated! Thank you in advance! Below are my trunk settings and the CLI output:

OUTGOING Settings:
PEER Details:
username=[USERNAME]
type=peer
secret=[PASSWORD]
progressinband=never
port=5060
nat=auto
insecure=very
ignoresdpversion=yes
host=sip.switch2voip.us
dtmfmode=rfc2833
context=from-trunk
canreinvite=no
allow=g729&g711&g723
fromuser=+13053963482

INCOMING Settings:
USER Context: [USERNAME] [I’ve also tried the DID number]
USER Details:
username=[USERNAME]
password=[PASSWORD]
type=user
port=5060
dtmfmode=rfc2833
pogressinband=never
context=from-pstn
allow=g729&g711&g723

And below is the output on the CLI:

== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Executing [[email protected]:1] NoOp(“SIP/66.33.146.52-0000001d”, “Received incoming SIP connection from unknown peer to 13053963482”) in new stack
– Executing [[email protected]:2] Set(“SIP/66.33.146.52-0000001d”, “DID=13053963482”) in new stack
– Executing [[email protected]:3] Goto(“SIP/66.33.146.52-0000001d”, “s,1”) in new stack
– Goto (from-sip-external,s,1)
– Executing [[email protected]:1] GotoIf(“SIP/66.33.146.52-0000001d”, “0?checklang:noanonymous”) in new stack
– Goto (from-sip-external,s,5)
– Executing [[email protected]:5] Set(“SIP/66.33.146.52-0000001d”, “TIMEOUT(absolute)=15”) in new stack
– Channel will hangup at 2014-05-02 16:40:46.381 PDT.
– Executing [[email protected]:6] Log(“SIP/66.33.146.52-0000001d”, "WARNING,“Rejecting unknown SIP connection from 66.33.146.52"”) in new stack
– Executing [[email protected]:7] Answer(“SIP/66.33.146.52-0000001d”, “”) in new stack

0x7f10f00060b0 – Probation passed - setting RTP source address to 66.33.166.133:20064
– Executing [[email protected]:8] Wait(“SIP/66.33.146.52-0000001d”, “2”) in new stack
– Executing [[email protected]:9] Playback(“SIP/66.33.146.52-0000001d”, “ss-noservice”) in new stack
– <SIP/66.33.146.52-0000001d> Playing ‘ss-noservice.ulaw’ (language ‘en’)
– Executing [[email protected]:10] PlayTones(“SIP/66.33.146.52-0000001d”, “congestion”) in new stack
– Executing [[email protected]:11] Congestion(“SIP/66.33.146.52-0000001d”, “5”) in new stack
== Spawn extension (from-sip-external, s, 11) exited non-zero on ‘SIP/66.33.146.52-0000001d’
– Executing [[email protected]:1] Hangup(“SIP/66.33.146.52-0000001d”, “”) in new stack
== Spawn extension (from-sip-external, h, 1) exited non-zero on ‘SIP/66.33.146.52-0000001d’

Are you registering with that provider for inbound calls or do they send it to a known IP (yours)?

I am sorry, but I don’t quite understand the question. I believe I am registered with the provider for inbound calls. I have never supplied them with an ip, domain, etc, so the only IP they probably have pointing to me is the dynamic IP that is supplied to me by my ISP. If I enter the account information directly into X-Lite, everything works without a hitch. I’m not sure if that helps at all?

In your trunk definition is a bit for “Registration String”, do you have one? , if you do you neglected to post it. You have no server defined in your inbound trunk so:

rasterisk -x “sip show registry”

shows what ?

If you don’t know how to converse with your provider, it will be difficult.

Oh yes, now i understand. The “Registration String” is definitely there. Baffling. Below is the output:
Host dnsmgr Username Refresh State Reg.Time
sip.switch2voip.us:5060 N [USERNAME] 105 Registered Fri, 02 May 2014 19:04:53
1 SIP registrations.

Then add

host=sip.switch2voip.us

into your inbound trunk settings.