[asterisk-users] Requiring a login to a phone
Steve Johnson
stevej456 at gmail.com
Sat Dec 1 18:09:27 CST 2007
Hi List,
We have a remote asterisk SIP phone at the cottage.
I'd like it to have minimal privileges when it first registers with
Asterisk. Ideally it should be in a restricted context. Dialing any
number would intercept the call and tell the person to log on. This
way, if the phone was stolen or someone got into the cottage, we
wouldn't have a bunch of surprise charges on our phone bill... :-)
Once the phone has been authenticated, it should go into a context
with normal privileges. After a couple of days of non-use, it should
auto-logout to the restricted context.
How can I change the sip context of a phone on the fly, based on
authentication login?
Any ideas? Thanks,
Steve
sip.conf:
-------------------------------
; phone at the cottage
[155]
context=restricted-155
...
extensions.conf
------------------------
[restricted-155]
exten _X.,1,NoOp(All Calls filter through this if not logged in on 155]
exten _X.,n,Answer
exten _X.,n,Wait(1)
exten _X.,n,Playback(You must log in to use this phone)
exten _X.,n,Authenticate(65535)
// if the person authenticates sucessfully, change the context of ext 155
// from restricted-155 to sip-phones. (HOW???)
[sip-phones]
; normal sip phone outgoing context
...
More information about the asterisk-users
mailing list