[asterisk-dev] i extension does not match on initial context - bug or not?

Dmitry Andrianov dimas at dataart.com
Fri Jan 9 02:41:47 CST 2009


There is NO functionality for catch-all currently exist. Extension can be alphanumeric so just [0-9*+] is not enough.
The closest pattern would be "_." which matches anything at all but the problem with it is that it also matches "special" extensions like h, i, t, s.

Regards,
Dmitry Andrianov

-----Original Message-----
From: asterisk-dev-bounces at lists.digium.com [mailto:asterisk-dev-bounces at lists.digium.com] On Behalf Of Leif Madsen
Sent: Friday, January 09, 2009 3:01 AM
To: Asterisk Developers Mailing List
Subject: Re: [asterisk-dev] i extension does not match on initial context - bug or not?

I would tend to agree here. Plus the fact the functionality to create a
catch-all already exists in current dialplan.

Although I will correct the example below (_[0-9*+].) with the following:

_[0-9*+]!

The ! means match on 0 or more additional characters, which would mean a
single character could match. With the period (.), you would need at
least 2 characters.

Leif Madsen.
http://www.leifmadsen.com
http://www.asteriskdocs.org

Nir Simionovich wrote:
> Hmmmm....
>
> IMHO, I don't believe that a catch all extension is something that
> Asterisk should have, as it is a possible breach of security. Same as
> applies to the ever dreaded _. combo.
>
> If you need something that really goes about and requires you to match
> the special characters in the front, then you can do something like this:
>
> _[0-9*+]. this way, you have a true catch all phrase. However, it is the
> programmers responsibility to verify that the catch all is implemented
> correctly in the dialplan. I would rather have the dialplan exit with a
> disconnect, than to have a default catch all that may introduce a
> security issue.
>
> I know this sounds a little purist, but hey, we do need to cover our
> rear somehow.


_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev



More information about the asterisk-dev mailing list