[asterisk-users] Dialplan / check / tool
Hi, I am wondering, if there is any tool available, which performs a check for suspicious entries in the dialplan. For example a non existing AGI-Script or a double assigned extension ike that: [context] exten = *100*,1,AGI(test_app.pl) ... exten = 190,1,Answer() ... exten = *100*,1,AGI(never_reached.pl) ... A normal dialplan reload command would echo no warning or something similair. Best regards -Thorsten- -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dialplan / check / tool
On Mon, Feb 18, 2013 at 8:11 AM, Thorsten Göllner t...@ovm-group.com wrote: A normal dialplan reload command would echo no warning or something similair. The duplicated extension will cause an error. Something like cannot add extension in line X because it already exists. -- Carlos Alvarez TelEvolve 602-889-3003 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dialplan / check / tool
A normal dialplan reload command would echo no warning or something similair. Normally I would see these being logged to /var/log/asterisk/messages with a stock Asterisk install. Doug -- Ben Franklin quote: Those who would give up Essential Liberty to purchase a little Temporary Safety, deserve neither Liberty nor Safety. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dialplan / check / tool
On Mon, 18 Feb 2013, Thorsten Göllner wrote: I am wondering, if there is any tool available, which performs a check for suspicious entries in the dialplan. For example a non existing AGI-Script... I'm just a 1.2 Luddite, but none that I know of. Please feel free to write one. Here are a few features that would be helpful: ) Parentheses, bracket, brace, quote, and double-quote matching. ) Parse /etc/init.d/asterisk to see if -C is used; parse asterisk.conf to see if astagidir is defined; take note of the username used to start Asterisk. ) Parse extensions.conf for global variables to cover the use case of: exten = *,n, agi(${SOME-VARIABLE}/foo) ) Check the permissions of the AGI's path relative to the username and group that starts Asterisk. Warn if silly permissions like 777 are found. ) If the AGI is an interpreted script (Bash, Perl, PHP, Python, etc.) instead of a compiled executable (C, Fortran, Cobol, assembler, etc.) ensure that the interpreter is present and functional (maybe something like 'interpreter --version'). ) Detect dialplan 'fall-through.' ) Detect 'gaps' in priorities. Note that priorities do not need to be contiguous or even specified in sequential order. ) Have a command line parameter to specify which version of Asterisk to check compliance against. This would be a great 'desk check' before migrating from 1.2 to 11 :) ) Detect global and channel variables defined, but not used. ) Detect global and channel variables used before defined. ) Detect missing goto targets. Feel free to implement a subset of the above for your initial release :) -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000-- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dialplan / check / tool
On Mon, Feb 18, 2013 at 10:54 AM, Steve Edwards asterisk@sedwards.comwrote: ) If the AGI is [...] a compiled executable (C, Fortran, Cobol, assembler, etc.) I'd like to see an AGI written using Fortran or Cobol. -- -Chris Harrington ACSDi Office: 763.559.5800 Mobile Phone: 612.326.4248 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dialplan / check / tool
On 18 Feb 2013, at 17:03, Christopher Harrington wrote: On Mon, Feb 18, 2013 at 10:54 AM, Steve Edwards asterisk@sedwards.com wrote: ) If the AGI is [...] a compiled executable (C, Fortran, Cobol, assembler, etc.) I'd like to see an AGI written using Fortran or Cobol. Don't tempt me ;) S-- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dialplan / check / tool
On Mon, 18 Feb 2013, Steven Howes wrote: On 18 Feb 2013, at 17:03, Christopher Harrington wrote: On Mon, Feb 18, 2013 at 10:54 AM, Steve Edwards asterisk@sedwards.com wrote: ) If the AGI is [...] a compiled executable (C, Fortran, Cobol, assembler, etc.) I'd like to see an AGI written using Fortran or Cobol. Don't tempt me ;) I ate the apple before Eve... program jwb print*, 'verbose Welcome to 1957' read(*,*) end program jwb It violates the AGI protocol (doesn't read the AGI variables) but it does execute correctly. -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000-- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users