How can requests to /elmah.axd be limited to an Umbraco admin user.
It is my understanding that the Umbraco membership and role providers apply to Umbraco Members but not Users — Umbraco user accounts do not appear to have a user name or role (e.g. “Admins”) that could be used in the web.config like this:
<location path="elmah.axd">
<system.web>
<authorization>
<allow roles="Admins" />
<deny users="*" />
</authorization>
</system.web>
</location>
This is a recommended way of securing ELMAH in other ASP.Net applications.
Anyone done this in Umbraco?
I solved the problem by creating an HTTP module to intercept requests to elmah.axd, and authorize only Umbraco administrators to view it. Heres the module code:
…and the web.config: