You can carry five pounds of dry ice onto an airplane, which is enough to cause breathing problems for those around you if the AC goes out for an extended period of time. Yet 3.2oz of shampoo is not allowed on the plane.
If the AC goes out, and assuming the lines of oxygen masks suddenly stop working? What sort of danger would a big thing of dry ice have in those conditions? People would just put on their O2 masks and the airplane would scrub/release the CO2 from the atmosphere in time. As well, dry ice is CO2, so it would be noticable as everyone gets short of breath, and the big cloud of fog would be a massive tell as well. 3.2 oz of shampoo is an amount not enough for any of the conventionally existing gelled explosive materials to cause significant damage. The limit isn't arbitrary or stupid. http://blog.tsa.gov/2008/02/more-on-liquid-rules-why-we-do-things.html