Reorder sanity checks in sign_file...
More consistent error messages