Sitecore - login required

So, for my Sitecore site, I am trying to make the user logged in and cannot use the \ Annoymous extranet account. I read and tried

Implement Sitecore Extranet Login on Website

But I missed something, ASP form authentication has side problems that bring you back to the original page and thus ignore the custom Desktop or Page Editor.

The part where I'm upset is that this logic seems to be already built into SiteCore. For example, if I try to go to http: // site / sitecore / shell , and I am not registered in the core of the site, it redirects me to the login page. So how can I enable this for my entire site.

UPDATE

My security editor looks like this: enter image description hereenter image description here

Even if I remove the protection of the sitecore object and deny access to the main object, I can still get to the site. enter image description here

The webs.config section of my site looks like this:

<sites> <site name="shell" virtualFolder="/sitecore/shell" physicalFolder="/sitecore/shell" rootPath="/sitecore/content" startItem="/home" language="en" database="core" domain="sitecore" loginPage="/sitecore/login" content="master" contentStartItem="/Base" enableWorkflow="true" enableAnalytics="false" analyticsDefinitions="content" xmlControlPage="/sitecore/shell/default.aspx" browserTitle="International" htmlCacheSize="2MB" registryCacheSize="3MB" viewStateCacheSize="200KB" xslCacheSize="5MB" disableBrowserCaching="true" /> <site name="login" virtualFolder="/sitecore/login" physicalFolder="/sitecore/login" enableAnalytics="false" database="core" domain="sitecore" disableXmlControls="true" /> <site name="admin" virtualFolder="/sitecore/admin" physicalFolder="/sitecore/admin" enableAnalytics="false" enableWorkflow="true" domain="sitecore" loginPage="/sitecore/admin/login.aspx" /> <site name="service" virtualFolder="/sitecore/service" physicalFolder="/sitecore/service" /> <site name="modules_shell" virtualFolder="/sitecore modules/shell" physicalFolder="/sitecore modules/shell" rootPath="/sitecore/content" startItem="/home" language="en" database="core" domain="sitecore" content="master" enableAnalytics="false" enableWorkflow="true" /> <site name="modules_website" virtualFolder="/sitecore modules/web" physicalFolder="/sitecore modules/web" rootPath="/sitecore/content" startItem="/home" language="en" database="web" domain="extranet" allowDebug="true" cacheHtml="true" /> <site name="website" virtualFolder="/" physicalFolder="/" rootPath="/sitecore/content" startItem="/Base" database="web" domain="extranet" allowDebug="true" cacheHtml="true" htmlCacheSize="10MB" registryCacheSize="0" viewStateCacheSize="0" xslCacheSize="5MB" filteredItemsCacheSize="2MB" enablePreview="true" enableWebEdit="true" enableDebugger="true" disableClientData="false" loginPage="/sitecore/login/Default.aspx" /> <site name="scheduler" enableAnalytics="false" domain="sitecore" cacheMedia="false" /> <site name="system" enableAnalytics="false" domain="sitecore" /> <site name="publisher" domain="sitecore" enableAnalytics="false" enableWorkflow="true" /> </sites> 

I know who I logged in because I added this to my homepage

 <asp:Label ID="Id" runat="server"><%=HttpContext.Current.User.Identity.Name%></asp:Label> 
+5
source share
2 answers

The solution was to add

 requireLogin="true" 

to website tag "website"

 <site name="website" virtualFolder="/" physicalFolder="/" rootPath="/sitecore/content" startItem="/Base" database="web" domain="extranet" allowDebug="true" cacheHtml="true" htmlCacheSize="10MB" registryCacheSize="0" viewStateCacheSize="0" xslCacheSize="5MB" filteredItemsCacheSize="2MB" enablePreview="true" enableWebEdit="true" enableDebugger="true" disableClientData="false" requireLogin="true" loginPage="/sitecore/login/Default.aspx" /> 
+4
source

In Sitecore Security Editor, deny reading access to the Home element for extranet \ Anonymous and granting access to your specific user / role. Also specify the login page in Web.config to redirect users if an authentication session does not exist.

+1
source

All Articles