Re: [Asterisk-Users] Disa - how it returns on user not dialing anynumbers ?
- Original Message - From: Peter Svensson [EMAIL PROTECTED] To: Asterisk Users Mailing List - Non-Commercial Discussion asterisk-users@lists.digium.com Sent: Monday, June 06, 2005 9:30 AM Subject: Re: [Asterisk-Users] Disa - how it returns on user not dialing anynumbers ? On Mon, 6 Jun 2005, Robert Rozman wrote: I'd like to use DISA properly for my case - I'd like to handle it right, if user when in DISA doesn't dial any number - how does Asterisk return from DISA cmd ? The file app_disa.c is hardwired to hang up the call if too many incorrect passwords are attempted and when no valid extensions has been entered before the digittimeout expires. To change it the block under the reorder: label in app_disa.c is probably the easiest. Instead of playing tones and all that it could set a channel variable based on the k variable which seem to be the main state variable. The dialplan could then handle the various exit cases. Peter Hi, thanks for info... I wanted to add n+101 behaviour if disa doesn't get proper password or extension I'm total newbie and would like to ask some more experienced users whether following change is proper to do that. I've changed in that block : reorder: /*ast_indicate(chan,AST_CONTROL_CONGESTION);*/ /* something is invalid, give em reorder for several seconds */ /*time(rstart); while(time(NULL) rstart + 10) { if (ast_waitfor(chan, -1) 0) break; f = ast_read(chan); if (!f) break; ast_frfree(f); } ast_playtones_stop(chan);*/ LOCAL_USER_REMOVE(u); /* return -1;*/ /* Dodano timeout koda:*/ if (ast_exists_extension(chan, chan-context, chan-exten, chan-priority + 101, chan-callerid)) chan-priority+=100; return 0; } Thanks in advance, regards, Rob. ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] Disa - how it returns on user not dialing anynumbers ?
- Original Message - From: C F [EMAIL PROTECTED] To: Asterisk Users Mailing List - Non-Commercial Discussion asterisk-users@lists.digium.com Sent: Monday, June 06, 2005 1:27 AM Subject: Re: [Asterisk-Users] Disa - how it returns on user not dialing anynumbers ? Try the t extension (stands for timeout). Hi, thanks for advice. But it seems that t extension doesn't get executed. I have it in context from where I call DISA and also in DISA context, but no go After dialing nothing and some time it just gets hungup, no t extension triggering . Any advice ? Thanks in advance, regards, Rob. I have : exten = s,14,DigitTimeout(5) exten = s,15,ResponseTimeout(20) exten = s,16,DBget(temp=USER/${CALLERIDNUM}) exten = s,17,SetAccount(${temp}) exten = s,18,DISA(no-password|from-bri-user-disa) exten = t,1,DBget(temp=DYNAMIC/${CALLERIDNUM}) exten = t,2,DBdel(DYNAMIC/${CALLERIDNUM}) exten = t,3,Dial(Local/[EMAIL PROTECTED]/n) exten = t,102,Goto(from-pstn,s,1) ; [from-bri-user-disa] include = outbound-allroutes-custom include = outrt-001-Mednarodni include = ext-local include = outrt-003-zunanja exten = s,1,NoOp(DISA: Waiting for BRI user to enter number) exten = s,2,DigitTimeout(5) ; Vhodni exten = s,3,ResponseTimeout(20) ; exten = t,1,DBget(temp=DYNAMIC/${CALLERIDNUM}) exten = t,2,DBdel(DYNAMIC/${CALLERIDNUM}) exten = t,3,Dial(Local/[EMAIL PROTECTED]/n) exten = t,102,Goto(from-pstn,s,1) ; On 6/5/05, Robert Rozman [EMAIL PROTECTED] wrote: Hi, I'd like to use DISA properly for my case - I'd like to handle it right, if user when in DISA doesn't dial any number - how does Asterisk return from DISA cmd ? I'd like to dial some default number if user doesn't dial anything or give him some message - but I don't know what gets executed after DISA if nothing is dialed I'm reading this on wiki, but don't understand what following sentence means. Any help ? ... If login is successful, the application parses the dialed number in the specified (or default) context, and returns 0 with the new extension context filled-in and the priority set to 1, so that the PBX may re-apply the routing tables to it and complete the call normally. ... Thanks in advance, regards, Rob. ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] Disa - how it returns on user not dialing anynumbers ?
What is the CLI output? On 6/5/05, Robert Rozman [EMAIL PROTECTED] wrote: - Original Message - From: C F [EMAIL PROTECTED] To: Asterisk Users Mailing List - Non-Commercial Discussion asterisk-users@lists.digium.com Sent: Monday, June 06, 2005 1:27 AM Subject: Re: [Asterisk-Users] Disa - how it returns on user not dialing anynumbers ? Try the t extension (stands for timeout). Hi, thanks for advice. But it seems that t extension doesn't get executed. I have it in context from where I call DISA and also in DISA context, but no go After dialing nothing and some time it just gets hungup, no t extension triggering . Any advice ? Thanks in advance, regards, Rob. I have : exten = s,14,DigitTimeout(5) exten = s,15,ResponseTimeout(20) exten = s,16,DBget(temp=USER/${CALLERIDNUM}) exten = s,17,SetAccount(${temp}) exten = s,18,DISA(no-password|from-bri-user-disa) exten = t,1,DBget(temp=DYNAMIC/${CALLERIDNUM}) exten = t,2,DBdel(DYNAMIC/${CALLERIDNUM}) exten = t,3,Dial(Local/[EMAIL PROTECTED]/n) exten = t,102,Goto(from-pstn,s,1) ; [from-bri-user-disa] include = outbound-allroutes-custom include = outrt-001-Mednarodni include = ext-local include = outrt-003-zunanja exten = s,1,NoOp(DISA: Waiting for BRI user to enter number) exten = s,2,DigitTimeout(5) ; Vhodni exten = s,3,ResponseTimeout(20) ; exten = t,1,DBget(temp=DYNAMIC/${CALLERIDNUM}) exten = t,2,DBdel(DYNAMIC/${CALLERIDNUM}) exten = t,3,Dial(Local/[EMAIL PROTECTED]/n) exten = t,102,Goto(from-pstn,s,1) ; On 6/5/05, Robert Rozman [EMAIL PROTECTED] wrote: Hi, I'd like to use DISA properly for my case - I'd like to handle it right, if user when in DISA doesn't dial any number - how does Asterisk return from DISA cmd ? I'd like to dial some default number if user doesn't dial anything or give him some message - but I don't know what gets executed after DISA if nothing is dialed I'm reading this on wiki, but don't understand what following sentence means. Any help ? ... If login is successful, the application parses the dialed number in the specified (or default) context, and returns 0 with the new extension context filled-in and the priority set to 1, so that the PBX may re-apply the routing tables to it and complete the call normally. ... Thanks in advance, regards, Rob. ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users