[asterisk-bugs] [JIRA] (ASTERISK-20652) AppVoicemail creates multiple duplicates of the contents of #included users.conf files.

Matt Jordan (JIRA) noreply at issues.asterisk.org
Tue Nov 6 17:12:21 CST 2012


    [ https://issues.asterisk.org/jira/browse/ASTERISK-20652?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=199299#comment-199299 ] 

Matt Jordan commented on ASTERISK-20652:
----------------------------------------

This is not technically a bug, as the behavior is undefined when you use #includes in any configuration file.  its actually a documented limitation of the password modification abilities of {{app_voicemail}}.  From the {{voicemail.conf.sample}} file:

{quote}
; NOTE: Asterisk has to edit this file to change a user's password.  This does
; not currently work with the "#include <file>" directive for Asterisk
; configuration files, nor when using realtime static configuration.
; Do not use them with this configuration file.
{quote}

                
> AppVoicemail creates multiple duplicates of the contents of #included users.conf files.
> ---------------------------------------------------------------------------------------
>
>                 Key: ASTERISK-20652
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-20652
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Applications/app_voicemail
>    Affects Versions: 10.9.0
>         Environment: Linux voipsrv 3.2.0-3-amd64 #1 SMP Mon Jul 23 02:45:17 UTC 2012 x86_64 GNU/Linux
>            Reporter: Craig Hoffman
>            Severity: Minor
>
> In my users.conf file, I've added a "#include users_conf/*.conf" option.  I do this to split off each user into their own file (1000.conf, etc).  It works well given the web app that was written to manage them.  We have ~100 users.
> When a user changes their voicemail PIN via the web app, the file is adjusted, and Asterisk is reloaded.  This works fine.
> However, when a user changes their voicemail PIN via the Comedian Mail prompts (0 and then 5), *each file* in the "users_conf" directory is updated(including a new file called *.conf).  But the update is just an appended version of the new data.  So you end up with a 1000.conf file looking like:
> [1000]
> fullname = Joe Test
> email = none at none.com
> secret = mysecret
> ...
> [1000]
> fullname = Joe Test
> email = none at none.com
> secret = mysecret
> ...
> [1000]
> fullname = Joe Test
> email = none at none.com
> secret = mysecret
> ...
> Each user file hovers around 400 bytes by default.  In just two weeks of operation, some of our files have grown to over 44k.
> AppVoicemail should instead just replace the vmsecret PIN, rather than copying and appending the new data.  
> As a workaround, I have written a python script that just replaces the PIN in the user file for that particular user.  It is called via "externpass".  This works well, and it will be what I use going forward - but I wanted to assist in documenting the bug(?) in case someone else is searching on a similar issue.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira



More information about the asterisk-bugs mailing list