Another MegaCommit®: Implementation of broker handlers.

Also, some minor changes -- protocol change update (LGDOUT → LGDOUT
{OK|FAIL}), some error types added as well as debug_log() statements.