5.9 Password Protection
The web-server/dispatchers/dispatch-passwords module defines a dispatcher constructor that performs HTTP Basic authentication filtering.
| ||||||||||||
| ||||||||||||
password-file : path-string? = "passwords" | ||||||||||||
|
The first returned value is a procedure that refreshes the password file used by the dispatcher.
The dispatcher that is returned does the following: Checks if the request contains Basic authentication credentials, and that they are included in password-file. If they are not, authentication-responder is called with a header that requests credentials. If they are, then next-dispatcher is invoked.
password-file is parsed as:
[path : string-regexp?] |
[pass : string?]) |
...) |
...) |
For example:
'(("secret stuff" "/secret(/.*)?" (bubba "bbq") (Billy "BoB")))