See generally:
http://www.summitpost.org/white-mountai ... chapter_17You have lots of options. A lot depends on which trailhead you're talking about, but as a rule you will have little trouble finding ordinary roadside campgrounds within a ten minute drive of your trailhead. The only problem with these is they sometimes fill up on busy weekends.
Some of the most popular trailheads are in state parks, where there is no camping allowed except at the official sites. Most of the others (with important exceptions, like Appalachia) are in the White Mountain National Forest, where camping is not allowed too close to certain trails, bodies of water, and so forth: most notably, you have to be at least 1/4 mile from any trailhead.
Complete WMNF rules here:
http://www.fs.usda.gov/Internet/FSE_DOC ... 363715.pdf (I know it says 2012, but it's the newest.)
Sleeping in your car is reportedly discouraged by the authorities. Peering inside cars checking for sleeping bags is not exactly a top enforcement priority, but at the most crowded trailheads like Appalachia and Lafayette you can expect multiple overnight patrols, so you definitely don't want to be setting up a barbecue or a tent in the parking lot (even if you had room). At both of these trailheads there are legal campsites within spitting distance (the power line cut just up the trail but still outside the WMNF, and Lafayette Campground, respectively).
Leaving your car at the trailhead overnight is not a problem. Many sites require a paid parking pass ($3/day); there's a system of envelopes and deposit boxes at those trailheads, or you can buy in advance for a discount. Break-ins are not totally unknown, so don't leave electronics or cash in your car.