[asterisk-users] vm_change_password shell?

Tzafrir Cohen tzafrir.cohen at xorcom.com
Tue Nov 28 01:41:53 MST 2006


On Mon, Nov 27, 2006 at 11:26:35PM -0800, jezzzz . wrote:
> In Asterisk 1.2.13 in app/app_voicemail.c, line 4700
> ext_pass_cmd is checked to decide whether to use
> vm_change_password or vm_change_password_shell to
> change a user's password for his voicemail account.
> 
> I wonder, what is the difference between
> vm_change_password and vm_change_password_shell - what
> is that shell? The only reference I found on the
> Internet was the following bug report:
> http://bugs.digium.com/view.php?id=7361 , but it's not
> very useful. Anywhere I can find a little more
> information on the difference between these two
> scenarios?

Use the Source, Luke.

http://svn.digium.com/svn/asterisk/branches/1.4/apps/app_voicemail.c

In it, you'll find:

static void vm_change_password_shell(struct ast_vm_user *vmu, char *newpassword)
{
	char buf[255];
	snprintf(buf,255,"%s %s %s %s",ext_pass_cmd,vmu->context,vmu->mailbox,newpassword);
	if (!ast_safe_system(buf))
		ast_copy_string(vmu->password, newpassword, sizeof(vmu->password));
}


ext_pass_cmd is not defined in that function and hence a global, and its 
value is taken from the configuration item "externpass".


The idea is that if the user has a better way of changing the password,
then the externpass script should be used to change the password.

-- 
               Tzafrir Cohen       
icq#16849755                    jabber:tzafrir at jabber.org
+972-50-7952406           mailto:tzafrir.cohen at xorcom.com       
http://www.xorcom.com  iax:guest at local.xorcom.com/tzafrir


More information about the asterisk-users mailing list