Support for adding arbitrary extensions when creating a req/cert

Supporting this feature is fairly straight forward in sign_req() since
the ca command supports the -extfile flag.

For gen_req() support, the config file needs to be re-written to a temp
file and the EXTRA_EXTS env-var data inserted in the right position
since there is no -extfile flag for the req command. This isn't the
cleanest method, but it allows callers to avoid manually editing the
config file themselves.

The intended use for this feature is additional extensions like
subjectAltName that have no easy method to define at runtime.