Set effective permissions during hardcopy creation

Previously, generating a hardcopy wouldn't include the modified problem header
(which lists the pg file path) even though the effective user had permission to
see this information. This was because the hardcopy generation omitted the
value from the environment and this commit adds the missing value.