   # Authenticate, typically used in a client:
   #
   #     client = esl.createClient()
-  #     client.on 'esl_auth_request', (req,res) ->
-  #       res.auth 'ClueCon', (req,res) ->
+  #     client.on 'esl_auth_request', ->
+  #       @auth 'ClueCon', ->
   #         # Start sending other commands here.
   #     client.connect ...
   #

      else
        event = headers['Content-Type']

    # Build request and response and send them out.
    req = new eslRequest headers,body
    res = new eslResponse socket
    if exports.debug
      util.log util.inspect event:event, req:req, res:res
    socket.emit event, req, res

  # Get things started
  socket.emit 'esl_connect', new eslResponse socket


  # Clean-up at the end of the connection.
  auto_cleanup: ->
    @on 'esl_disconnect_notice', ->
      if exports.debug
        util.log "Received ESL disconnection notice"
      switch @headers['Content-Disposition']
        when 'linger'      then @exit()
        when 'disconnect'  then @end()

#### Connection Listener (socket events handler)
# This is modelled after Node.js' http.js
