-
Notifications
You must be signed in to change notification settings - Fork 23
Voicemail: Add option to lock the password (i.e. for shared mailboxes) #31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: release/17.0
Are you sure you want to change the base?
Conversation
If the password is prefix by '-', the password is locked (see https://github.com/asterisk/asterisk/blob/2d7948fa483c8703cf9948811fd67147f4d560d4/configs/samples/voicemail.conf.sample#L330 for details). Bugfix FreePBX/issue-tracker#151
|
@kguptasangoma This is the new pull request without the i18n files. |
|
If this is intended as a security feature, it's very trivial to just remove the dash from the hidden input value. The server-side code should be checking for a leading dash and not allowing updates from UCP in that case. |
miken32
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
str_starts_with($settings['pwd'], '-') seems simpler to read at a glance than the regex, IMO
If the password is prefixed by '-', the password is locked (see https://github.com/asterisk/asterisk/blob/2d7948fa483c8703cf9948811fd67147f4d560d4/configs/samples/voicemail.conf.sample#L330 for details). * Add server-side check in ucp/Voicemail.class.php check for leading '-' in the old password before password is saved * Replaced regex in ucp/views/vmsettings.php by str_starts_with() * Modified regex in functions.inc.php to allow voicemail passwords with leading '-' in admin-panel
If the password is prefixed by '-', the password is locked (see https://github.com/asterisk/asterisk/blob/2d7948fa483c8703cf9948811fd67147f4d560d4/configs/samples/voicemail.conf.sample#L330 for details). * Add server-side check in ucp/Voicemail.class.php check for leading '-' in the old password before password is saved * Replaced regex in ucp/views/vmsettings.php by str_starts_with() * Modified regex in functions.inc.php to allow voicemail passwords with leading '-' in admin-panel Bugfix FreePBX/issue-tracker#151
If the password is prefixed by '-', the password is locked (see https://github.com/asterisk/asterisk/blob/2d7948fa483c8703cf9948811fd67147f4d560d4/configs/samples/voicemail.conf.sample#L330 for details). * Add server-side check in ucp/Voicemail.class.php check for leading '-' in the old password before password is saved * Replaced regex in ucp/views/vmsettings.php by str_starts_with() * Modified regex in functions.inc.php to allow voicemail passwords with leading '-' in admin-panel Bugfix FreePBX/issue-tracker#151
|
@miken32 Thank you for your comments. Added a new PR with your modifications |
* Removed displaying '-' from Voicemail Pin in UCP if password is locked
|
hi @miken32 thanks for your feedback on this PR. Just want to know how does this PR now looks to you? |
|
Much improved
|
If the password is prefix by '-', the password is locked (see https://github.com/asterisk/asterisk/blob/2d7948fa483c8703cf9948811fd67147f4d560d4/configs/samples/voicemail.conf.sample#L330 for details).
Bugfix FreePBX/issue-tracker#151