; 2003-02-16 18:30 GMT  jtodd@loligo.com
;
; This is the sip.conf file for John Todd's Asterisk
;  server.  Asterisk can be found on http://www.asterisk.org/
;
; More recent versions of this file can be found on:
;   http://www.loligo.com/asterisk/
;

;
; SIP Configuration for Asterisk
;
[general]
disallow=gsm
allow=ulaw
port = 5060			; Port to bind to
bindaddr = 0.0.0.0		; Address to bind to
context = from-sip		; Default for incoming calls



; These register statements are to REGISTER my Asterisk server
;  with certain accounts on remote SIP servers.  The inoc-dba,
;  FWD, and iconnect (deltathree) registries work, the one for
;  coloco does not, due to Vocal problems.
;
; These register= statements must be in context [general]
;
; Note that the registry for FWD as of today (2003-02-16) does
;  a bunch of re-registers even after an "ACK" from FWD.  Bug.
;
; Note that registering against (some?) Vocal 1.4 servers fails.  Bug.
;  The server at 10.0.1.33 is a Vocal 1.4 server, thus commented out.
;
; All inbound SIP calls end up in context [from-sip] in extensions.conf
;
register=65000:notmypassword@inoc-dba.pch.net
register=14155551212:6666@sipauth.deltathree.com
register=18438:stillnotmypassword@fwd.pulver.com
;register=2203:reallynotmypassword@10.0.1.33
;tos=lowdelay
;tos=184


; The "iconnect" SIP peer is the outbound leg of the iconnecthere.com
;  SIP gateway service.  Note that the username and password below
;  are different than the "register=" line above.  I don't exactly
;  know why iconnecthere.com does it this way, but that's fine with
;  me.  I only use the "iconnect" peer below to pass outgoing calls
;  to their service.  Inbound calls are handled out of [general]
;
[iconnect]
type=friend
secret=6666
username=78871375
host=sipauth.deltathree.com


; The "fwd" SIP peer is Free World Dialup, run by Jeff Pulver.
;  Personally, I haven't found much use for it since the directory
;  is private, but it's one more SIP gateway to play with.
;
[fwd]
type=friend
secret=stillnotmypassword
username=18438
host=fwd.pulver.com


; The "coloco" SIP peer is a Vocal system at Coloco, Inc. in
;  Laurel, MD.  They are a SIP gateway provider, and I have
;  an account with them for local Maryland SIP dialtone.
;  http://www.coloco.com/
;
; I have had almost no luck getting this to work; there seems
;  to be some problem with the Vocal server they use and the
;  REGISTRY and AUTH routines that doesn't agree with Asterisk.
;  If I take down the firewall at Coloco and go directly to the 
;  router with the PRI interface, it functions correctly, but
;  that obviously is not a good solution.
;
[coloco]
context=coloco
type=friend
username=12345
secret=mysecretpassword
host=10.0.1.33

                                                                       
; INOC-DBA is a terribly useful SIP-only gateway for
;  AS# holders.  If you don't know what an AS# is, and if you
;  don't have one, this config subset won't be useful to you.  
;  Contact Woody for an extension assignment.
;  
[inoc-dba]
type=friend
host=theinocdbaserverhostname.goes.here.com
username=65000
secret=notmypassword
context=inoc-dba


; My SIP phones in the house/office
;
; By my own convention (and to save my sanity) I have given
;  all the ATA-186 devices in my network "extensions" that
;  are numeric.  I picked "2200" to start for historical 
;  laziness.  Again, for my sanity, I also made the usernames
;  on the phone identical to the extension number of the
;  channel.
;
; I distribute IP addresses with a DHCP server to these phones,
;  on the network 204.91.156.0/24  
;
; All the Cisco ATA-186 units I have are on "real" IP addresses,
;  and I haven't experimented with NAT yet.  NAT has been a real
;  PITA with the ATA's, and I don't relish having to make it work.
; 
; Anytime a call is dialed from "2203" or "2204", it will be 
;  parsed by the context [intern] in the extensions.conf file
;
[2203]
type=friend
username=2203
secret=wownotmypassword
host=dynamic
permit=204.91.156.0/24
context=intern
canreinvite=no

[2204]
type=friend
username=2204
secret=w00tnotmypassword
host=dynamic
permit=204.91.156.0/24
context=intern
canreinvite=no

