I can not get security on a website. In the web config Raiz I put the following line:
<authorization>
<deny users="?" />
</authorization>
Then, in the "Account" folder, I have the following web.config
:
<?xml version="1.0"?>
<configuration>
<location path="Register.aspx">
<system.web>
<authorization>
<allow users="*"/>
</authorization>
</system.web>
</location>
<location path="~/Account/Manage.aspx">
<system.web>
<authorization>
<deny users="?"/>
</authorization>
</system.web>
</location>
</configuration>
Just like this post, I can not go to the page Register.aspx
, I miss an error of Persmisos.
*Acceso denegado.
Descripción: Error al obtener acceso a los recursos necesarios para completar esta solicitud. Puede que el servidor no esté configurado para obtener acceso a la dirección URL solicitada.
Mensaje de error 401.2.: No autorizado: error al iniciar sesión debido a la configuración de servidor. Compruebe que tiene permiso para ver este directorio o página con las credenciales que ha suministrado y los métodos de autenticación habilitados en el servidor Web. Póngase en contacto con el administrador del servidor Web para obtener más ayuda.*
If I delete the% main_code% line web.config
enter all the pages correctly, that is, the page is walking, only blocked by this "security".
If I remove the deny users="?"
from the "Account" folder when I want to login it redirects me to the login page, as established by the authentication in the root webconfig.