The OnAuthenticate event handler is invoked when the client
has provided authentication credentials as part of the request for a
document or other resource. To implement an event handler, the application
should create a class derived from the CHttpServer class, and
then override this method.
The event handler can call the AuthenticateClient method to
authenticate the client session. If the event handler does not authenticate
the client, the server will perform its default authentication. To reject
the credentials provided by the client, use the SendErrorResponse
method with a result code of 401.