What I've done is created a specific page template for that new page type and assign that page type to use that page template by default On the template, I have a repeater which gets that file/attachment and renders it via a redirect. It works and allows users to create page aliases (original request for me). See transformation code below:
<script runat="server">
protected override void OnInit(EventArgs e)
{
if(CMS.PortalEngine.PortalContext.ViewMode == CMS.PortalEngine.ViewModeEnum.LiveSite)
{
string guid = ValidationHelper.GetString(Eval("FileAttachment"), "");
if(!string.IsNullOrEmpty(guid))
{
Response.Redirect(URLHelper.ResolveUrl("/getattachment/" + guid + "/" + ValidationHelper.GetString(Eval("FileLongName"), "file") + ".aspx"));
}
}
}
</script>
Another way might be to create a handler vs. the redirect.