Begin work to enable lastmodified/latest behavior

This generalizes the http_get method so that options such as headers can
be passed, and the get method does not itself overwrite a target file.