FIX: detecting corrupt package.json files with missing commas.

Also
- fix parsing bad json with trailing backslashes in strings.
- Corrupt http cookies.