[App_rpt-users] Executing a script - does not work

David McGough kb4fxc at inttek.net
Sat Jan 23 01:42:37 UTC 2016


Steven,

This isn't a topic for this forum....I'll follow up off list.



73, David KB4FXC


On Sat, 23 Jan 2016, Steven Donegan wrote:

> Do not modify root's permissions. If you do you will severely compromise security...
>  Steven Donegan
> KK6IVC General Class FCC License
> FAA PP-ASEL Pilots License
> Silver State Car #86
> www.sscc.us
>  
> 
>       From: David McGough <kb4fxc at inttek.net>
>  To: Stephen - K1LNX <k1lnx at k1lnx.net> 
> Cc: "app_rpt-users at ohnosec.org" <app_rpt-users at ohnosec.org>
>  Sent: Friday, January 22, 2016 5:31 PM
>  Subject: Re: [App_rpt-users] Executing a script - does not work
>    
> 
> Steve,
> 
> Check the permissions on the parent directories:
> 
> ls -lisad /root
> ls -lisad /root/scripts
> 
> ...You need execute permissions for "other" users on each of these 
> directories (like a chmod o+x /root; chmod o+x /root/scripts). Frequently, 
> the root directory will only be mode 0700.
> 
> 73, David KB4FXC
> 
> 
> 
> On Fri, 22 Jan 2016, Stephen - K1LNX wrote:
> 
> > Thanks Steve, followed your example and looks like I needed a space between
> > the DTMF definition, the = sign and the command itself to work properly,
> > and it ran, but I still can't get my script to run in the /root/scripts
> > directory. My scripts don't have to live there, but I was setting it there
> > temporarily for testing.
> > 
> > I'm not sure why this isn't working.
> > 
> > On Fri, Jan 22, 2016 at 7:34 PM, Steve Zingman <szingman at msgstor.com> wrote:
> > 
> > > Stephen,
> > > Here is what I have:
> > >
> > > In rpt.conf:
> > > 966 = cmd,/tmp/ssz.sh
> > >
> > > in /tmp/ssz.sh:
> > > #! /bin/bash
> > > echo "Hello World" >/tmp/ssz.txt
> > >
> > > from the asterisk cli:
> > > *CLI> rpt debug level 0
> > > app_rpt Debugging disabled
> > > *CLI> rpt fun 2152 *966
> > > *CLI> [Jan 22 19:29:53] NOTICE[3303]: app_rpt.c:4008 function_cmd: cmd
> > > param = /tmp/ssz.sh, digitbuf =
> > >
> > > script ran
> > >
> > >
> > > Steve
> > >
> > >
> > >
> > >
> > >
> > > On 01/22/2016 06:22 PM, Stephen - K1LNX wrote:
> > >
> > > I am trying to get a script to execute based on a DTMF sequence and it's
> > > not working for whatever reason.
> > >
> > > I put the following in rpt.conf under the functions stanza:
> > >
> > > [functions2376]
> > >
> > > (default functions removed for readability)
> > >
> > > ; testing script functions
> > >
> > > 123=cmd,/root/scripts/test.sh
> > >
> > > The script is nothing more than a simple shell script for testing right
> > > now, I validated it worked:
> > >
> > > #!/bin/bash
> > >
> > > echo test1234 > test.out
> > >
> > > Permissions are set 777 on it to ensure it's able to be executed by
> > > anything, but when I go to the Asterisk console and execute:
> > >
> > > rpt fun 2376 *123
> > >
> > > The script does not execute. What is it I could be missing here if
> > > anything?
> > >
> > > tnx
> > >
> > > Stephen
> > >
> > > K1LNX
> > >
> > >
> > > _______________________________________________
> > > App_rpt-users mailing listApp_rpt-users at ohnosec.orghttp://ohnosec.org/cgi-bin/mailman/listinfo/app_rpt-users
> > >
> > > To unsubscribe from this list please visit http://ohnosec.org/cgi-bin/mailman/listinfo/app_rpt-users and scroll down to the bottom of the page. Enter your email address and press the "Unsubscribe or edit options button"
> > > You do not need a password to unsubscribe, you can do it via email confirmation. If you have trouble unsubscribing, please send a message to the list detailing the problem.
> > >
> > >
> > > --
> > > "Anything is possible if you don't know what you are talking about."
> > > 1st Law of Logic
> > >
> > >
> > 
> 
> _______________________________________________
> App_rpt-users mailing list
> App_rpt-users at ohnosec.org
> http://ohnosec.org/cgi-bin/mailman/listinfo/app_rpt-users
> 
> To unsubscribe from this list please visit http://ohnosec.org/cgi-bin/mailman/listinfo/app_rpt-users and scroll down to the bottom of the page. Enter your email address and press the "Unsubscribe or edit options button"
> You do not need a password to unsubscribe, you can do it via email confirmation. If you have trouble unsubscribing, please send a message to the list detailing the problem. 
> 
> 
> 




More information about the App_rpt-users mailing list