Password To leave a Voicemail?

I need to have a line that many people can call but only a few have the right to leave a voice mail. Is there a way to force the user to enter a password before he/she can leave a VM. Any help would be great.

Thanks!!

you can use the Authenticate application before you send them to voicemail. This way only Authenticated users actually get into the voicemail application.

asterisk*CLI> show application authenticate
asterisk*CLI> 
  -= Info about application 'Authenticate' =- 

[Synopsis]
Authenticate a user

[Description]
  Authenticate(password[|options[|maxdigits]]): This application asks the caller
to enter a given password in order to continue dialplan execution. If the password
begins with the '/' character, it is interpreted as a file which contains a list of
valid passwords, listed 1 password per line in the file.
  When using a database key, the value associated with the key can be anything.
Users have three attempts to authenticate before the channel is hung up. If the
passsword is invalid, the 'j' option is specified, and priority n+101 exists,
dialplan execution will continnue at this location.
  Options:
     a - Set the channels' account code to the password that is entered
     d - Interpret the given path as database key, not a literal file
     j - Support jumping to n+101 if authentication fails
     m - Interpret the given path as a file which contains a list of account
         codes and password hashes delimited with ':', listed one per line in
         the file. When one of the passwords is matched, the channel will have
         its account code set to the corresponding account code in the file.
     r - Remove the database key upon successful entry (valid with 'd' only)
     maxdigits  - maximum acceptable number of digits. Stops reading after
         maxdigits have been entered (without requiring the user to
         press the '#' key).
         Defaults to 0 - no limit - wait for the user press the '#' key.