[asterisk-gui] problem with new incoming calls feature

Dorian Gray astgui at tintar.com
Tue Jan 9 16:55:25 MST 2007


<deletia>

> as you mentioned, I thought of adding a block for the provider and setting its
> context to DID_trunk_n fixes this,
> but this might arise new issues like
> A) When deleting a provider, we have to lookup the blocks that are using
> DID_trunk_n context and delete them
> B) we might have to add one more comment field to distinguish user entries
> from the 'block for the provider'
>     in users.conf, which in my opinion might be unnecessary

yes I agree it would be good to avoid those issues completely.
another possible issue is that the current workaround also registers the user
twice for the protocol, which is probably not good. which is what I still find
the most bizarre --

foo*CLI> iax2 show users
Username  Secret                Authen           Def.Context  A/C Codec Pref
iaxfwd    Key: freeworlddialup  000000000000004  DID_trunk_4  No  Host
...
trunk_4    mysecret             000000000000003  DID_trunk_4  No  Host
trunk_5    mysecret             000000000000003  DID_trunk_5  No  Host
...
...

(where trunk_4 is -gui defined provider for fwd, trunk_5 is my outgoing
provider, and iaxfwd is the default rsa block from iax.conf but I modified its
context to match trunk_4)

the user is registered and shows the correct context; I can see why the
context in iax.conf might *override* the related one in users.conf, but if the
provider is absent from iax.conf it still shows up properly in the console
based on the users.conf settings (e.g. trunk_5 in the above)

but when calls come in it rejects them b/c it can't find "num@" i.e. it is
looking for a context with empty name. which you said you guys have noticed as
well. what I mean to say is that it seems as if -gui is doing the *right*
thing and registering iax user correctly, but somehow asterisk itself is
causing the problem here.


> The way I was planing to fix it was to scrap the 'trunk_n'/'DID_trunk_n'
> naming convention
> and use a user specified [provider_name] in users.conf and point its context
> to [DID_provider_name]
> So when the user deletes the provider we can also delete the associated
> [DID_provider_name]
> (just like it is done now)

this seems to make good sense. altho could still cause problems if
provider_name matches something in iax.conf.

but technically that should not be a problem since using -gui seems to me like
users.conf should basically replace most of iax.conf or sip.conf, i.e.
users.conf should handle stuff like auth method and keynames and whatnot.

which would also get around the potential issues of having e.g. iaxfwd
registered twice, once using rsa key in iax.conf and once using username/pass
in users.conf.


> I guess even this way we might have to add a comment field which will let us
> distinguish a trunk
> from a user in users.conf. As of now the GUI checks if the context starts with
> 'trunk_',
> if yes, it is a trunk other wise it assumes as a user.

in oldschool asterisk mentality I guess a trunk and a user are almost the same
thing lol. e.g. I know the whole user/peer/friend separation confused a lot of
people and still does...

thanks and please keep up the excellent work!!!

cheers
++dg


<deletia>



More information about the asterisk-gui mailing list