= WEBrick::HTTPAuth::BasicAuth < Object ------------------------------------------------------------------------ = Includes: Authenticator (from /home/chedong/.local/share/rdoc) (from /home/chedong/.local/share/rdoc) ------------------------------------------------------------------------ Basic Authentication for WEBrick Use this class to add basic authentication to a WEBrick servlet. Here is an example of how to set up a BasicAuth: config = { :Realm => 'BasicAuth example realm' } htpasswd = WEBrick::HTTPAuth::Htpasswd.new 'my_password_file', password_hash: :bcrypt htpasswd.set_passwd config[:Realm], 'username', 'password' htpasswd.flush config[:UserDB] = htpasswd basic_auth = WEBrick::HTTPAuth::BasicAuth.new config ------------------------------------------------------------------------ = Class methods: make_passwd new = Instance methods: authenticate challenge logger realm userdb = Attributes: attr_reader logger attr_reader realm attr_reader userdb
Generated by phpman v4.9.26-1-g511901d · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-07-31 09:19 @216.73.217.152
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)