Extended maintenance of Ruby 1.9.3 ended on February 23, 2015. Read more

In Files

  • webrick/httpauth/userdb.rb

Class/Module Index [+]

Quicksearch

WEBrick::HTTPAuth::UserDB

User database mixin for HTTPAuth. This mixin dispatches user record access to the underlying #auth_type for this database.

Attributes

auth_type[RW]

The authentication type.

WEBrick::HTTPAuth::BasicAuth or WEBrick::HTTPAuth::DigestAuth are built-in.

Public Instance Methods

get_passwd(realm, user, reload_db=false) click to toggle source

Retrieves a password in realm for user for the #auth_type of this database. reload_db is a dummy value.

 
               # File webrick/httpauth/userdb.rb, line 47
def get_passwd(realm, user, reload_db=false)
  make_passwd(realm, user, self[user])
end
            
make_passwd(realm, user, pass) click to toggle source

Creates an obscured password in realm with user and password using the #auth_type of this database.

 
               # File webrick/httpauth/userdb.rb, line 31
def make_passwd(realm, user, pass)
  @auth_type::make_passwd(realm, user, pass)
end
            
set_passwd(realm, user, pass) click to toggle source

Sets a password in realm with user and password for the #auth_type of this database.

 
               # File webrick/httpauth/userdb.rb, line 39
def set_passwd(realm, user, pass)
  self[user] = pass
end
            

Commenting is here to help enhance the documentation. For example, code samples, or clarification of the documentation.

If you have questions about Ruby or the documentation, please post to one of the Ruby mailing lists. You will get better, faster, help that way.

If you wish to post a correction of the docs, please do so, but also file bug report so that it can be corrected for the next release. Thank you.

If you want to help improve the Ruby documentation, please visit Documenting-ruby.org.