Try our conversational search powered by Generative AI!

Can't login to the EPiServer CMS



So I was testing some access rights on my machine untill I started to check the checkboxes for apply subitems? and apply parent something.

Anywyas: This made my account not available to log in again, meaning I cant log in to the CMS. Does anyone have any idea what I can do?

I'm thinking that I need to change some access somewhere but I dont know how!

Im not getting any errors Its just pushes me back to the log in page each time I try to log in.

Using WindowsMembershipProvider in Web.Config as defaultProvider and as roleManager: WindowsRoleProvider as defaultProvider.


Mar 19, 2014 9:16


You could try changing the authorization settings in your site's configuration file. Look for the <location path="path/to/your/ui"> section and change


<authorization><deny users="*">


<authorization><allow users="*">


You may also have to do the same for the location section for the path to your admin mode, should be nearby the UI one (<location path="path/to/your/ui/CMS/admin">). Then it ought to be possible to access the admin mode without actually logging in, and you could see if you can set things right from there.


Hope I understood your problem correctly.



Edited, Mar 19, 2014 9:44

Sometimes I get requests that user cannot log in or doesn't have permission to access certain pages.
Why I do is to create a new admin user and then check permissions in admin mode.

1. Enable SQL Server role and membership provider.
2. Create Backdoor.aspx with the following code:

<%@ Page Language="C#" AutoEventWireup="true" %>
<% var user = Membership.CreateUser("someusernmae", "somerpassword", "someemail");
user.IsApproved = true;
Roles.AddUserToRole("someusername", "Administrators");%>

3. Navigate to yourdomain/backdoor.aspx
4. Enter the admin mode as "someusername" and set correct permissions
5. Remove "someusername" and delete Backdoor.aspx from the system

Hope it helps :)

Mar 19, 2014 10:07

Hello Dejan! 

I tried your version of it but I cant navigate to Backdoor.aspx.

I'm currently in a MVC application but I can still create an Aspx page. But when I try to locate http://localhost:37002/Views/Backdoor.aspx it says: 

The resource cannot be found.

So I can't access the page ._.

Mar 19, 2014 10:29

Hi Alexander,

You can create a page in notepad. It doesn't have to be a part of your solution. And then just upload it to the site root (next to web.config).
It doesn't matter if you're using WebForms of MVC.

And then you should navigate to http://localhost:37002/Backdoor.aspx

Kind regards,

Mar 19, 2014 10:32

Yes ofcourse. I got it working. Or ye I got this error:

Exception Details: System.Configuration.Provider.ProviderException: The role 'Administrators' was not found.

But it do exists in my web.config :s

Mar 19, 2014 10:46

Yes, you have it in web.config but you don't have it in the database.
You can use the following code to display all roles (name this page roles.aspx or something like that):

<%@ Page Language="C#" AutoEventWireup="true" %>
<% foreach (var role in Roles.GetAllRoles()) { %>
<p><%: role %></p>
<% } %>


Mar 19, 2014 10:57

I believe since you are using WindowsMembershipProvider it will be difficult to create users from your code (they are not in the db), you'd need the SQL provider instead (or the Multiplexing one should you still want windows as well).

Is it your local windows administrator account (the one that you use to log on to the server) that you're trying to use? It should automatically be a member of Administrators.

Did you try allowing access to edit/admin mode for all users as above?


Mar 19, 2014 10:59

If you don't see "Administrators" role in the listing, you can modify the Backdoor.aspx by adding:




Roles.AddUserToRole("someusername", "Administrators");


Mar 19, 2014 11:00

Hey Mathias and thank you for your answer.. I thought I answered you but didnt get through.. I tried to change the deny users = "*" to allow instead but nothing happens. and I'm using the Multiplexing on both sides:


<location path="EPiServer/CMS/admin">
<allow roles="WebAdmins, Administrators, Everyone" />
<allow users="*" />


<allow roles="WebEditors, WebAdmins, Administrators, Everyone" />
<allow users="*" />


Alright Dejan I'm gonna see what I find!

Thanks for your answers.

Mar 19, 2014 11:08

So funny thing is that I find the Administrators when doing the foreach.. Ideas? ._.

Mar 19, 2014 11:10

Problem solved: I didn't had to change anything actually.. The problem was that I locked out all of my access from the CMS so I couldnt log in ( Yet I was authenticated) So at the log in page I changed the URL to (localhost:80/episerver < - - this gave me a redirect to the cms but told me to " reload the page" error" etc etc. Finally I got in to the "set acess rights" section and changed the premissions.

Cheers :)

Mar 19, 2014 15:31

Great! Glad that you got it sorted :)


Mar 19, 2014 15:56
This thread is locked and should be used for reference only. Please use the Legacy add-ons forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.