On Sun, Sep 10, 2006 at 06:51:30PM -0500, Gary Eck wrote:
> Looking at a Asterisk server which will not be attached to 
> the Internet - and the user will be pretty computer illiterate.
> Has anyone seen a script or some mechanism to set the server time by 
> using an extension, and entering the date/time via the keypad?
> Thanks!

This can be implemented by a call to date (prefferebly with hwclock
--systohc later on). However both of those should run as root.

You can use Read to get the date and time (with fields separated by '#':
separate Reads). And then pass the resulting numbers to a script via
System or AGI. That script will do basic sanity tests and call 
date/hwclock via sudo.

BTW: one of the things you must do is make sure no '*' get from the
number to the sudo-d commands. Read already takes care of the '#'.

-- 
Tzafrir Cohen         sip:[EMAIL PROTECTED]
icq#16849755          iax:[EMAIL PROTECTED]
+972-50-7952406          jabber:[EMAIL PROTECTED]
[EMAIL PROTECTED]     http://www.xorcom.com
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

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

Reply via email to