Trixbox: SIP/2.0 489 Bad event Error on incoming calls

hi,
i have this really wierd and annoying error. we have obtained a sip trunk from Siminn Iceland Ltd provider and set it up with trixbox. the trunk can register with the service provider just fine. i can set the trunk as a peer/friend ( type = peer or type = friend and setup incoming context and type = user) i am able to make outbound calls through it. but as soon as i set it up like that all the incoming call is rejected by asterisk and from the console i can see it is a "SIP/2.0 489 Bad event" msg generated by asterisk. if i get rid of all the "type" command from the trunk setup, i can receive calls just as fine. but obviously that stops me from calling outbound through the trunk.
the configuration for receiving making outgoing call is like this:
[siminn]
host=157.157.16.140
username=2000053544990160
secret=somePassword
user=phone
type=friend
register string:
2000053544990160: somePassword@157.157.16.140/2000053544990160
in this configuration if i receive an incoming call, this is what i see on the asterisk console:
trixbox1*CLI>
<--- SIP read from 157.157.16.140:5060 --->
INVITE sip:2000053544990160@202.176.88.148 SIP/2.0
Via: SIP/2.0/UDP 157.157.16.140:5060;branch=z9hG4bK4912b162-8587-5936
Call-Id: CI_430507_2000053544990160@1eaaaaaaa271_404041
From: "" ;tag=157.157.16.140-8587-1495
To:
Max-Forwards: 70
CSeq: 430507 INVITE
Contact:
Content-Length: 0
<------------->
--- (9 headers 0 lines) ---
Sending to 157.157.16.140 : 5060 (no NAT)
Using INVITE request as basis request - CI_430507_2000053544990160@1eaaaaaaa271_404041
Found peer 'simin'
trixbox1*CLI>
<--- Reliably Transmitting (no NAT) to 157.157.16.140:5060 --->
SIP/2.0 407 Proxy Authentication Required
Via: SIP/2.0/UDP 157.157.16.140:5060;branch=z9hG4bK4912b162-8587-5936;received=157.157.16.140
From: "" ;tag=157.157.16.140-8587-1495
To: ;tag=as5c42a171
Call-ID: CI_430507_2000053544990160@1eaaaaaaa271_404041
CSeq: 430507 INVITE
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Supported: replaces
Proxy-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="39194225"
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog 'CI_430507_2000053544990160@1eaaaaaaa271_404041' in 32000 ms (Method: INVITE)
trixbox1*CLI>
<--- SIP read from 157.157.16.140:5060 --->
ACK sip:2000053544990160@202.176.88.148 SIP/2.0
Via: SIP/2.0/UDP 157.157.16.140:5060;branch=z9hG4bK4912b162-8587-5936
Call-Id: CI_430507_2000053544990160@1eaaaaaaa271_404041
From: "" ;tag=157.157.16.140-8587-1495
To: ;tag=as5c42a171
CSeq: 430507 ACK
Content-Length: 0
<------------->
--- (7 headers 0 lines) ---
trixbox1*CLI>
<--- SIP read from 157.157.16.140:5060 --->
NOTIFY sip:2000053544990160@202.176.88.148 SIP/2.0
Via: SIP/2.0/UDP 157.157.16.140:5060;branch=z9hG4bK4912b162-9032-9620
Call-Id: CI_291719_2000053544990160@1eaaaaaaa271_274688
From: sip:2000053544990160@194.144.220.247:1105;tag=157.157.16.140-4294965200-8974
To: sip:2000053544990160@194.144.220.247:1105
Max-Forwards: 70
CSeq: 219 NOTIFY
Contact:
Subscription-State: active
Content-Type: application/simple-message-summary
Event: message-summary
Content-Length: 42
Messages-Waiting: no
Voice-Message: 0/0
<------------->
--- (12 headers 2 lines) ---
trixbox1*CLI>
<--- Transmitting (no NAT) to 157.157.16.140:5060 --->
SIP/2.0 489 Bad event
Via: SIP/2.0/UDP 157.157.16.140:5060;branch=z9hG4bK4912b162-9032-9620;received=157.157.16.140
From: sip:2000053544990160@194.144.220.247:1105;tag=157.157.16.140-4294965200-8974
To: sip:2000053544990160@194.144.220.247:1105;tag=as3b0ed1c9
Call-ID: CI_291719_2000053544990160@1eaaaaaaa271_274688
CSeq: 219 NOTIFY
User-Agent: Asterisk PBX
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Supported: replaces
ontent-Length: 0
but if i change the configuration to the following, i can receive calls, but it will stop me from making outbound calls because no peer is defined:
[siminn]
host=157.157.16.140
username=2000053544990160
secret=somePassword
user=phone
register string:
2000053544990160: somePassword@157.157.16.140/2000053544990160
i have also tried splitting it into two parts (type = peer and type = user). but did not help.
anyone have any idea?
khan
SoftverkproAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

SoftverkproAuthor Commented:
hi,
sorry the question looks a bit malformed here. i have also asked for solution in trixbox forum. if you have trouble reading iit here, please check out the same problem here:

http://trixbox.org/forums/trixbox-forums/trunks/sip-2-0-489-bad-event-error-incoming-calls
0
michofreihaCommented:
Did you check the codec of the Inbound call and if your trixbox supports such codec, even if the extension support it?

Regards
0
SoftverkproAuthor Commented:
Fixed : the error was from malformed authentication . i removed the authentication part from the  configuration and it works:

[siminn]
host=157.157.16.140
user=phone
type=friend
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
IP Telephony

From novice to tech pro — start learning today.