Merged in core changes that help ensure client and server get same sha1.