There are several web traffic models in NS. The best one derives from the web caching model, that it is described in the NS Manual, Chapter 33. There is a good traffic analysis paper that used this model
A. Feldman, A. Gilbert, P. Huang, W. Willinger, Dynamics of IP traffic: A study of the role of variability and the impact of control, ACM Sigcomm'99, Cambridge, MA, Aug. 1999.
This implementation uses one-way TCP agents, i.e., connection establishment and connection termination are not simulated. The default agent is TCP/Reno, although it is possible to use any other one-way TCP agent. Read ~ns/tcl/webcache/webtraffic.tcl for more details.
I extended this model to be able to collect response times. You can find my source code in /usr/dirt/src/ns_web_traffic/reno. I developed this code for ns-2.1b6, and it also works for ns-2.1b7(a).
NS distribution includes one example that is relevant for this model, ~ns/tcl/ex/web-traffic.tcl. Note that the way the random variables are initialized (using new parameters) is wrong. You should set those values after the random variable is created.
The scripts I used to calibrate my experiments can be found at /usr/dirt/src/ns_web_traffic/calibration. They provide a good example of how to use NS in general, and how to use the web traffic generation model in particular. The network topology tries to follow the one in DiRT's RED paper (at least in terms of client/server delays.)
Note that I used queue monitoring instead of packet trace post-processing to study throughput (see toolbox.tcl). It is more common to use trace-all and post-processing, since more information about the simulation is collected. However, for large scale simulations, full packet traces use a huge amount of disk space, and all that I/O significantly slows the simulator.
A couple of pretty plots showing my results
I spent a fair amount of time trying to modify the model in order to use FullTcp (i.e., two-way TCP agents that simulate connection establishment and termination). As far as I know, my modified version of the original web traffic model is fully functional. However, FullTcp implementation is still quite buggy, so they result is not satisfactory. During the simulation, many connections go into incorrect states. I started debugging FullTcp, and contributed a few bug fixes (search the mail archive). Unfortunately, I left this project before solving all the problems. You can find my code in (/usr/dirt/src/ns_web_traffic/fulltcp). Good luck!