[asterisk-users] IAX2 failed to authenticate; it uses wrong name

Hans Feringa linux at shelob.nl
Sat Dec 29 02:14:23 CST 2007


I am new to Asterisk and have a question about a problem that really
confuses me.

I am running Asterisk 1.4.15 at site A and 1.4.10 (from ubuntu repository)
Both are NATted.

I set up a IAX2 connection between two asterisk boxes (A and B).
During my tests I used a laptop with zoiper and a username of laptop (on
site B)
with a (IAX2) connection to the remote asterisk box A.

I do not know whether I used the laptop before or after I tested that the
connections between
A and B worked. The laptop had a connection configuration at site A, so I
can use it
where-ever I have a internet connection that allows me to use this kind of
connections (no
proxy only internet connections)

I am sure I made calls between asterisk A and B in both directions.
However when I wanted to
use the connections between the two asterisk boxes for normal phone calls
between the two
sites later on, it worked only one way (from A to B).

I noticed that site A reported:

[Dec 23 21:18:38] NOTICE[23266] chan_iax2.c: Host x.x.x.x failed to
authenticate as laptop

The name 'laptop' was not the name used in the configuration for the
connection between the
two asterisks boxes, but the name of the zoiper configuration.
I had also a IAX2 configuration at site A to Free World Dialup. I ended up
removing every
IAX2 configuration (in one go) except the site B configuration at site A,
and it finally
worked. Since we need to use that connection, I am not at liberty to test
more at the moment.

What I want to know is, does Asterisk somehow cache and re-use IAX2
connection information
from a remote site it once learned, insisting that the name must be that
learned name?
I did not change the configuration parameters for the IAX2 connection
between the two boxes,
and everything works now as expected. So it must be something that was
"learned" along the
way. Once there was no configuration for laptop any more, it started to work!

If it is learned somehow, how do I clear that information.

Another reason could be that IAX2 sometimes takes the expected name from
the first available
registry (laptop in this case) regardless of which connection comes in,
but that would be a bug,
wouldn't it.

On a quite moment I will try to put back the previous IAX2 configuration,
to check if it is
related to having more than one IAX2 connection configured, or to that
single time of
having set up a connection from a different IAX2 device (zoiper) with a
different
configuration behind the same public ip-address.

Thanks,

Hans Feringa







More information about the asterisk-users mailing list