Asterisk ports


#1

asterisk is supos to be runing on port udp 4569 but which i do a nmap -sU on the box which only nmaps for udp i dont get any 4569 only 111, 123, 668 and 671 what is going on here?

I need to figure out this port stuff so I can open it on my firewall


#2

No idea - you’re doing it, why don’t you tell us what’s going on? It doesn’t make any sense to me.

But why use nmap if you just want to find out what ports are open on the local machine? Try:

netstat -a

Use nmap to find out open ports on remote machines - that’s what it’s meant for.


#3

sorry about the confusion, when I said asterisk I ment IAX2.

I am working on opening us some holes in my firewall so that IAX2 can get through.

In my IAX.conf file it says that

[general]
;bindport=4569                  ; bindport and bindaddr may be specified
;                               ; NOTE: bindport must be specified BEFORE bindaddr

is 4569 which is also what voip-info.org says is the port that needs to be opened up to work.

then my

homer:/etc/asterisk# netstat -a
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State
tcp        0      0 *:674                   *:*                     LISTEN
tcp        0      0 *:sunrpc                *:*                     LISTEN
tcp        0      0 *:sieve                 *:*                     LISTEN
tcp        0      0 *:www                   *:*                     LISTEN
tcp        0      0 *:auth                  *:*                     LISTEN
tcp        0      0 *:ssh                   *:*                     LISTEN
tcp        0      0 localhost.localdom:smtp *:*                     LISTEN
tcp        0      0 homer.homer:ssh         10.10.0.10:45542        ESTABLISHED
udp        0      0 *:668                   *:*
udp        0      0 *:671                   *:*
udp        0      0 *:2727                  *:*
udp        0      0 *:4520                  *:*
udp        0      0 *:sip                   *:*
udp        0      0 *:iax                   *:*
udp        0      0 *:sunrpc                *:*
udp        0      0 homer.homer:ntp         *:*
udp        0      0 localhost.localdoma:ntp *:*
udp        0      0 *:ntp                   *:*
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags       Type       State         I-Node Path
unix  2      [ ACC ]     STREAM     LISTENING     787815   /var/run/asterisk.ctl
unix  7      [ ]         DGRAM                    793      /dev/log
unix  2      [ ACC ]     STREAM     LISTENING     1004     /dev/printer
unix  2      [ ]         DGRAM                    1108
unix  2      [ ]         DGRAM                    1077
unix  2      [ ]         DGRAM                    1051
unix  2      [ ]         DGRAM                    992
unix  2      [ ]         DGRAM                    863

but it also looks like 4520 mihgt be DUNDI, what is going on?