Active Topics

 


Reply
Thread Tools
Posts: 93 | Thanked: 13 times | Joined on Nov 2010
#1
I have setup Asterisk/localphone with sip on my N900 and only gets outgoing calls

When i get incoming, the phone doesnt ring but i see, the following msg on asterisk CLI

==Using SIP RTP CoS mark 5

Shouldnt be any port forwarding stuff as i tried everything with DMZ on my router.

sip.conf
Code:
[general]
    srvlookup=yes
    register=>xxx:xxx@proxy.localphone.com

[localphone.com]
    type=peer
    disallow=all
    allow=ilbc
    allow=ulaw
    allow=gsm
    dtmfmode=rfc2833
    host=localphone.com
    fromdomain=localphone.com
    insecure=port,invite
    qualify=yes
    fromuser=xxx
    authuser=xxx
    username=xxx
    secret=xxx
    ;canreinvite=no
    
	nat=yes
port=5060
qualify=yes
canreinvite=no
insecure=invite,port
transport=udp

[1001]
    type=friend
    context=phones
    host=dynamic
    nat=yes
    canreinvite=no
    secret=abc
extsnsions.conf
Code:
[globals] 

[general] 
   autofallthrough=yes

[default] 
exten => s,1,Verbose(1|Unrouted call handler) 
exten => s,n,Answer() 
exten => s,n,Wait(1) 
exten => s,n,Playback(tt-weasels) 
exten => s,n,Hangup() 

[outgoing_calls] 
   exten => _X.,1,NoOp()
   exten => _X.,2,Dial(SIP/${EXTEN:1}@localphone.com,20,r)
   exten => _X.,3,Hangup

[phones] 
   include => outgoing_calls
Any idea how to solve this?

Last edited by rosh; 2011-04-19 at 08:26.
 
Posts: 18 | Thanked: 5 times | Joined on Apr 2010
#2
Shouldnt there be a context=default in sip.conf for the sip peer localphone.com?
 
Posts: 93 | Thanked: 13 times | Joined on Nov 2010
#3
Originally Posted by bitwit View Post
Shouldnt there be a context=default in sip.conf for the sip peer localphone.com?
Added, but still no change

anybody?
 
Posts: 13 | Thanked: 6 times | Joined on Apr 2011
#4
Originally Posted by rosh View Post
Added, but still no change

anybody?
Where is your localphone incoming context? See
http://help.localphone.com/voip/devi...phone/asterisk
-m

Edit: Please don't use a numeric only username (you are using 1001). It can be any alphanumeric string. You should mix numbers and letters to deter brute force attacks. Suggest you read the voip tech-chat forum on dslreports.

Last edited by voip_wire; 2011-04-19 at 14:03.
 
Posts: 93 | Thanked: 13 times | Joined on Nov 2010
#5
Originally Posted by voip_wire View Post
Where is your localphone incoming context? See
http://help.localphone.com/voip/devi...phone/asterisk
-m

Edit: Please don't use a numeric only username (you are using 1001). It can be any alphanumeric string. You should mix numbers and letters to deter brute force attacks. Suggest you read the voip tech-chat forum on dslreports.

What should be my sip credential to put the sip client according to localphone code?

http://help.localphone.com/voip/devi...phone/asterisk

Last edited by rosh; 2011-04-19 at 15:12.
 
Posts: 13 | Thanked: 6 times | Joined on Apr 2011
#6
Originally Posted by rosh View Post
What should be my sip credential to put the sip client according to localphone code?

http://help.localphone.com/voip/devi...phone/asterisk
I don't understand your question. At all.

If you want to find out your SIP credentials, the link is on the localphone help page, linked above. Your original problem is that you have not defined routing of localphone incoming calls. The default context, one that you posted, does not go anywhere. Don't change the default context. It should be left as you have it, to minimize the chances of abuse. Define another context, localphone-in, you can name it anything you like really, and make sure that all the calls that reach that context get routed to your local user (1001 in your original example).

You do have a localphone incoming number (DID), don't you?

Why do you want to use asterisk in the first place? Don't setup an asterisk server if you are not fully aware of all the security considerations! You definitely don't need it to connect N900 with (most) VOIP service providers.

-m
 
Posts: 93 | Thanked: 13 times | Joined on Nov 2010
#7
Originally Posted by voip_wire View Post
I don't understand your question. At all.

If you want to find out your SIP credentials, the link is on the localphone help page, linked above. Your original problem is that you have not defined routing of localphone incoming calls. The default context, one that you posted, does not go anywhere. Don't change the default context. It should be left as you have it, to minimize the chances of abuse. Define another context, localphone-in, you can name it anything you like really, and make sure that all the calls that reach that context get routed to your local user (1001 in your original example).

You do have a localphone incoming number (DID), don't you?

Why do you want to use asterisk in the first place? Don't setup an asterisk server if you are not fully aware of all the security considerations! You definitely don't need it to connect N900 with (most) VOIP service providers.

-m
could u please post the additional code i need to put and where.

Actually, the reason im trying to go with asterisk is that, for whatever reason my phone doesnt work properly with native SIP sip integration. Specially at university. Most probably firewall and porting issues.

I know that OpenVPN would help this. But after researchin many hrs, still i couldnt manage to setup a OpenVPN connection.
 
Posts: 93 | Thanked: 13 times | Joined on Nov 2010
#8
Eureka!. I found the issue. It has something wrong with localphone. I tried with voipcheap and works nicely.

Anybody knows how to use stun (or other nat stuff) of voipcheap in asterisk sip.conf to make the connection more stable?
 
Posts: 13 | Thanked: 6 times | Joined on Apr 2011
#9
Originally Posted by rosh View Post
Eureka!. I found the issue. It has something wrong with localphone. I tried with voipcheap and works nicely.

Anybody knows how to use stun (or other nat stuff) of voipcheap in asterisk sip.conf to make the connection more stable?


You have to a bit more specific. What worked?
N900<=>asterisk<=>voipcheap or
N900<=>voipcheap?

You still haven't answered if you have a DID. Localphone calls it an incoming number.

You can set any stun server in N900. Here is how
Code:
1. Go to the relevant sip account in accounts.
2. Advanced Settings
3. Scroll all the way down.
4. Uncheck Auto-detect STUN
5. Set your preferred STUN server (stun.ekiga.net as an example)
6. Leave the STUN port to default (3478)
Stun server setting in asterisk may or may not be available. It depends on the version that you have. AFAIK, it was introduced in asterisk 1.8.

If you cannot get it to work on the N900, I am not sure why you think it will work with asterisk. At the minimum, you have to have a basic understanding of SIP protocol to troubleshoot NAT related issues with asterisk. But then again YMMV.

-m
 
Posts: 93 | Thanked: 13 times | Joined on Nov 2010
#10
Originally Posted by voip_wire View Post


You have to a bit more specific. What worked?
N900<=>asterisk<=>voipcheap or
N900<=>voipcheap?

You still haven't answered if you have a DID. Localphone calls it an incoming number.

You can set any stun server in N900. Here is how
Code:
1. Go to the relevant sip account in accounts.
2. Advanced Settings
3. Scroll all the way down.
4. Uncheck Auto-detect STUN
5. Set your preferred STUN server (stun.ekiga.net as an example)
6. Leave the STUN port to default (3478)
Stun server setting in asterisk may or may not be available. It depends on the version that you have. AFAIK, it was introduced in asterisk 1.8.

If you cannot get it to work on the N900, I am not sure why you think it will work with asterisk. At the minimum, you have to have a basic understanding of SIP protocol to troubleshoot NAT related issues with asterisk. But then again YMMV.

-m
Thanks for your reply.

Voipcheap -> asterisks on N900 - > SIP client on N900 works.
N900 <> voipcheap worked obviously. However was not receiving calls sometimes, specially at university WiFi may be due to NAT and other routing stuff.

Now it is much much stable than before, hardly miss a call.

SInce my asterisk server and SIP client are local (within N900), i dont really need a STUN to connect to asterisk server. Im looking for something when asterisk connects to voipcheap to make the voipcheap <> asterisk connection more stable.

I dont have a direct DID to my voipcheap. I got a number for IPkall to connect to voip cheap. Few more questions:

1. Still Caller ID doesnt work, May be voipcheap doesnt support it? or have a issue with asterisk code?
(fixed this already )

2. Is there anyway to connect googlevoice directly with asterisks to make calls without waiting for incoming call?

Last edited by rosh; 2011-04-21 at 11:57.
 
Reply


 
Forum Jump


All times are GMT. The time now is 02:32.