Since my 1997 is so old it has been smogged 5 times.
There is supposed to be a visual inspection to see if any of the emission equipment has been altered. Only once did I have to pull the engine lid and the guy looked under the car - but that is a long story as he thought we were trying to pull a fast one.
If you get called on altering the emission equipment then you fail the visual, even if you have 100% pure air out of the exhaust pipe.
I use to know the rules but I am rusty. Muffler should not matter since it is after the cat. I forget the rule on headers. I think aftermarket headers have to be CARB approved. A 2.5 does not have the cat in the header like a 2000-2004 does. Also does not have the oxygen sensors in the header.
http://www.arb.ca.gov/msprog/aftermkt/devices/amquery.php