Add ability to use protocol/host in filename, and ability to provide stub file root directory.