Verify the header signature when loading a PBP.

Fixes headless tests crashing.
Merge pull request #1560 from unknownbrackets/headless

Verify the header signature when loading a PBP