Mypal/netwerk/protocol/http
Fedor 38fd9ff2bb Update MacOS Version detection. 2021-02-04 16:53:09 +02:00
..
ASpdySession.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
ASpdySession.h basic source 2019-03-11 13:26:37 +03:00
AltDataOutputStreamChild.cpp basic source 2019-03-11 13:26:37 +03:00
AltDataOutputStreamChild.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
AltDataOutputStreamParent.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
AltDataOutputStreamParent.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
AlternateServices.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
AlternateServices.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
CacheControlParser.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
CacheControlParser.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
ConnectionDiagnostics.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
Http2Compression.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
Http2Compression.h basic source 2019-03-11 13:26:37 +03:00
Http2HuffmanIncoming.h basic source 2019-03-11 13:26:37 +03:00
Http2HuffmanOutgoing.h basic source 2019-03-11 13:26:37 +03:00
Http2Push.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
Http2Push.h Implement a threadsafe & revised version of http2PushedStream. 2019-09-05 20:08:43 +03:00
Http2Session.cpp [http] Use a copy of nsHttpConnectionInfo. 2021-02-04 16:51:38 +02:00
Http2Session.h basic source 2019-03-11 13:26:37 +03:00
Http2Stream.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
Http2Stream.h Implement a threadsafe & revised version of http2PushedStream. 2019-09-05 20:08:43 +03:00
HttpBaseChannel.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpBaseChannel.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpChannelChild.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpChannelChild.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpChannelParent.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpChannelParent.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpChannelParentListener.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpChannelParentListener.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
HttpInfo.cpp basic source 2019-03-11 13:26:37 +03:00
HttpInfo.h basic source 2019-03-11 13:26:37 +03:00
HttpLog.h basic source 2019-03-11 13:26:37 +03:00
InterceptedChannel.cpp basic source 2019-03-11 13:26:37 +03:00
InterceptedChannel.h basic source 2019-03-11 13:26:37 +03:00
NullHttpChannel.cpp basic source 2019-03-11 13:26:37 +03:00
NullHttpChannel.h basic source 2019-03-11 13:26:37 +03:00
NullHttpTransaction.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
NullHttpTransaction.h basic source 2019-03-11 13:26:37 +03:00
PAltDataOutputStream.ipdl Nuke vim lines. 2021-02-04 16:48:36 +02:00
PHttpChannel.ipdl Nuke vim lines. 2021-02-04 16:48:36 +02:00
PHttpChannelParams.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
PSpdyPush.h basic source 2019-03-11 13:26:37 +03:00
README ooops, some files where missed 2019-03-12 18:31:25 +03:00
TimingStruct.h basic source 2019-03-11 13:26:37 +03:00
TunnelUtils.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
TunnelUtils.h Return proper error if the nss layer encounters an error on the http tunnel. 2019-05-20 09:01:21 +03:00
UserAgentOverrides.jsm Improve SSUAO to provide more accurate OS information. 2020-07-16 02:15:00 +03:00
UserAgentUpdates.jsm Use the Preprocessor instead of AppConstants. 2020-04-03 20:48:21 +03:00
WellKnownOpportunisticUtils.js basic source 2019-03-11 13:26:37 +03:00
WellKnownOpportunisticUtils.manifest basic source 2019-03-11 13:26:37 +03:00
http2_huffman_table.txt basic source 2019-03-11 13:26:37 +03:00
make_incoming_tables.py basic source 2019-03-11 13:26:37 +03:00
make_outgoing_tables.py basic source 2019-03-11 13:26:37 +03:00
moz.build Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsAHttpConnection.h basic source 2019-03-11 13:26:37 +03:00
nsAHttpTransaction.h basic source 2019-03-11 13:26:37 +03:00
nsCORSListenerProxy.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsCORSListenerProxy.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsHttp.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttp.h basic source 2019-03-11 13:26:37 +03:00
nsHttpActivityDistributor.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpActivityDistributor.h basic source 2019-03-11 13:26:37 +03:00
nsHttpAtomList.h basic source 2019-03-11 13:26:37 +03:00
nsHttpAuthCache.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpAuthCache.h basic source 2019-03-11 13:26:37 +03:00
nsHttpAuthManager.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpAuthManager.h basic source 2019-03-11 13:26:37 +03:00
nsHttpBasicAuth.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpBasicAuth.h basic source 2019-03-11 13:26:37 +03:00
nsHttpChannel.cpp De-unify netwerk. 2020-07-16 02:35:57 +03:00
nsHttpChannel.h De-unify netwerk. 2020-07-16 02:35:57 +03:00
nsHttpChannelAuthProvider.cpp Disable auth confirmation prompts by default. 2019-12-25 15:45:23 +03:00
nsHttpChannelAuthProvider.h Disable auth confirmation prompts by default. 2019-12-25 15:45:23 +03:00
nsHttpChunkedDecoder.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpChunkedDecoder.h basic source 2019-03-11 13:26:37 +03:00
nsHttpConnection.cpp Return proper error if the nss layer encounters an error on the http tunnel. 2019-05-20 09:01:21 +03:00
nsHttpConnection.h Close the transaction if PR_Read/PR_Write failed. 2019-05-20 09:01:18 +03:00
nsHttpConnectionInfo.cpp Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsHttpConnectionInfo.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsHttpConnectionMgr.cpp Implement a threadsafe & revised version of http2PushedStream. 2019-09-05 20:08:43 +03:00
nsHttpConnectionMgr.h basic source 2019-03-11 13:26:37 +03:00
nsHttpDigestAuth.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpDigestAuth.h basic source 2019-03-11 13:26:37 +03:00
nsHttpHandler.cpp Update MacOS Version detection. 2021-02-04 16:53:09 +02:00
nsHttpHandler.h Rebuild application version string. 2020-07-16 02:14:19 +03:00
nsHttpHeaderArray.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpHeaderArray.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsHttpNTLMAuth.cpp Handle missing base64 challenge in NegotiateAuth and NTLMAuth. 2020-04-03 20:42:49 +03:00
nsHttpNTLMAuth.h basic source 2019-03-11 13:26:37 +03:00
nsHttpPipeline.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpPipeline.h basic source 2019-03-11 13:26:37 +03:00
nsHttpRequestHead.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpRequestHead.h basic source 2019-03-11 13:26:37 +03:00
nsHttpResponseHead.cpp basic source 2019-03-11 13:26:37 +03:00
nsHttpResponseHead.h basic source 2019-03-11 13:26:37 +03:00
nsHttpTransaction.cpp [http] Use a copy of nsHttpConnectionInfo. 2021-02-04 16:51:38 +02:00
nsHttpTransaction.h Implement a threadsafe & revised version of http2PushedStream. 2019-09-05 20:08:43 +03:00
nsICorsPreflightCallback.h Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsIHttpActivityObserver.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpAuthManager.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpAuthenticableChannel.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpAuthenticator.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpChannel.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpChannelAuthProvider.idl Nuke vim lines. 2021-02-04 16:48:36 +02:00
nsIHttpChannelChild.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpChannelInternal.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpEventSink.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpHeaderVisitor.idl basic source 2019-03-11 13:26:37 +03:00
nsIHttpProtocolHandler.idl basic source 2019-03-11 13:26:37 +03:00
nsIWellKnownOpportunisticUtils.idl basic source 2019-03-11 13:26:37 +03:00

README

                                                        Darin Fisher
                                                        darin@netscape.com
                                                        8/8/2001

                            HTTP DESIGN NOTES


CLASS BREAKDOWN

  nsHttpHandler
    - implements nsIProtocolHandler
    - manages preferences
    - owns the authentication cache
    - holds references to frequently used services

  nsHttpChannel
    - implements nsIHttpChannel
    - talks to the cache
    - initiates http transactions
    - processes http response codes
    - intercepts progress notifications

  nsHttpConnection
    - implements nsIStreamListener & nsIStreamProvider
    - talks to the socket transport service
    - feeds data to its transaction object
    - routes progress notifications

  nsHttpConnectionInfo
    - identifies a connection

  nsHttpTransaction
    - implements nsIRequest
    - encapsulates a http request and response
    - parses incoming data

  nsHttpChunkedDecoder
    - owned by a transaction
    - removes chunked decoding

  nsHttpRequestHead
    - owns a nsHttpHeaderArray
    - knows how to fill a request buffer

  nsHttpResponseHead
    - owns a nsHttpHeaderArray
    - knows how to parse response lines
    - performs common header manipulations/calculations

  nsHttpHeaderArray
    - stores http "<header>:<value>" pairs

  nsHttpAuthCache
    - stores authentication credentials for http auth domains

  nsHttpBasicAuth
    - implements nsIHttpAuthenticator
    - generates BASIC auth credentials from user:pass


ATOMS

  nsHttp:: (header namespace)

  eg. nsHttp::Content_Length


TRANSACTION MODEL

  InitiateTransaction -> ActivateConnection -> AsyncWrite, AsyncRead

  The channel creates transactions, and passes them to the handler via
  InitiateTransaction along with a nsHttpConnectionInfo object
  identifying the requested connection.  The handler either dispatches
  the transaction immediately or queues it up to be dispatched later,
  depending on whether or not the limit on the number of connections
  to the requested server has been reached.  Once the transaction can
  be run, the handler looks for an idle connection or creates a new
  connection, and then (re)activates the connection, assigning it the
  new transaction.

  Once activated the connection ensures that it has a socket transport,
  and then calls AsyncWrite and AsyncRead on the socket transport.  This
  begins the process of talking to the server.  To minimize buffering,
  socket transport thread-proxying is completely disabled (using the flags
  DONT_PROXY_LISTENER | DONT_PROXY_PROVIDER | DONT_PROXY_OBSERVER with
  both AsyncWrite and AsyncRead).  This means that the nsHttpConnection's
  OnStartRequest, OnDataAvailable, OnDataWritable, and OnStopRequest
  methods will execute on the socket transport thread.

  The transaction defines (non-virtual) OnDataReadable, OnDataWritable, and
  OnStopTransaction methods, which the connection calls in response to
  its OnDataAvailable, OnDataWritable, and OnStopRequest methods, respectively.
  The transaction owns a nsStreamListenerProxy created by the channel, which
  it uses to transfer data from the socket thread over to the client's thread.
  To mimize buffering, the transaction implements nsIInputStream, and passes
  itself to the stream listener proxy's OnDataAvailable.  In this way, we
  have effectively wedged the response parsing between the socket and the
  thread proxy's buffer.  When read, the transaction turns around and reads
  from the socket using the buffer passed to it.  The transaction scans the
  buffer for headers, removes them as they are detected, and copies the headers
  into its nsHttpResponseHead object.  The rest of the data remains in the
  buffer, and is proxied over to the client's thread to be handled first by the
  http channel and eventually by the client.

  There are several other major design factors, including:

    - transaction cancelation
    - progress notification
    - SSL tunneling
    - chunked decoding
    - thread safety
    - premature EOF detection and transaction restarting
    - pipelining (not yet implemented)


CACHING

<EOF>