Changing the /umbraco/ directory to enhance security
Hi everyone,
I have changed the name of my /umbraco/ folder to /login/ so the user can type in www.theirdomain.com/login to bring up the Umbraco back-end. I renamed this folder, then changed the web.config setting
These were the only 2 instances of /umbraco/ in the web.config file.
Now when I go to www.theirdomain.com/login - it loads fine - I log in and everything seems fine.
However, when I right click to bring up the menu - the menu disappears straight away in Firefox. This doesn't happen in IE thought. I went through my entire site and changes all occurences of "/umbraco" or "/login" but this hasn't solved it.
I've worked on a few Umbraco sites where we've had to change the location of the /umbraco/ folder. Dirk's reference to Tim's blog post is great - it will sort out your context-menu issue!
An other thing I found was that if you install any 3rd-party packages, quite a lot of them make the assumption that you have an /umbraco/ folder, and will place images, css, javascripts, etc in there. So you might need to do some manual moving around if you install any packages.
However, the context menu is still disappearing on right click. I have tried this on 2 test sites now and both are having the same issue. Can someone confirm that my syntax above is actually correct? I have added it just before </rewrites> as it states.
Thanks for the reply - I tried the code that you have given me but it still isn't working. Does anyone know of any other JS files that may need their path changing?
Just a quick question but are you mapping all requests through to the ASP.Net ISAPI within IIS? If you don't do this, IIS will handle the JavaScript files and the URL Rewriter will never be notified.
If you've not mapped all URLs through IIS this is how:
1. In IIS goto the website and click on properties 2. Select home directory tab. 3. Click configuration 4. Under wildcard application maps section click insert 5. Then click browse and select file C:\Windows\Microsoft.NET\Framework\v2.0.50727\ aspnet_isapi.dll (make sure you goto your windows folder) 6. Uncheck verify file exists 7. Click apply
Changing the /umbraco/ directory to enhance security
Hi everyone,
I have changed the name of my /umbraco/ folder to /login/ so the user can type in www.theirdomain.com/login to bring up the Umbraco back-end. I renamed this folder, then changed the web.config setting
And also
These were the only 2 instances of /umbraco/ in the web.config file.
Now when I go to www.theirdomain.com/login - it loads fine - I log in and everything seems fine.
However, when I right click to bring up the menu - the menu disappears straight away in Firefox. This doesn't happen in IE thought. I went through my entire site and changes all occurences of "/umbraco" or "/login" but this hasn't solved it.
Has anyone successfully done this before?
Cheers, Garry.
Read this blogpost, it may help you on this issue.
Cheers,
/Dirk
Hi,
You currently cannot change the umbraco-folder since a couple of references are hardcoded to that folder.
If you rename it, a couple of javascript-files can't be found and result in the behaviour you had.
I believe that the future 4.1 does support renaming of the folder.
HTH,
Peter
Hi Garry,
I've worked on a few Umbraco sites where we've had to change the location of the /umbraco/ folder. Dirk's reference to Tim's blog post is great - it will sort out your context-menu issue!
An other thing I found was that if you install any 3rd-party packages, quite a lot of them make the assumption that you have an /umbraco/ folder, and will place images, css, javascripts, etc in there. So you might need to do some manual moving around if you install any packages.
Good luck with it.
Cheers, Lee.
(PS. Good to see a fellow Scouser on the forums)
Hi guys,
Thanks for the replies. I have tried the suggested addition to UrlRewriting.config using the following code
However, the context menu is still disappearing on right click. I have tried this on 2 test sites now and both are having the same issue. Can someone confirm that my syntax above is actually correct? I have added it just before </rewrites> as it states.
Cheers, Garry.
Hi Garry,
Remove the extra hashes ## from the virtualUrl attribute:
I think Tim's example (from his blog post) had them to bring attention to them - they aren't used as part of the virtualUrl path.
Good luck, Lee.
Hi Lee,
Thanks for the reply - I tried the code that you have given me but it still isn't working. Does anyone know of any other JS files that may need their path changing?
Hi Garry,
Just a quick question but are you mapping all requests through to the ASP.Net ISAPI within IIS? If you don't do this, IIS will handle the JavaScript files and the URL Rewriter will never be notified.
If you've not mapped all URLs through IIS this is how:
1. In IIS goto the website and click on properties
2. Select home directory tab.
3. Click configuration
4. Under wildcard application maps section click insert
5. Then click browse and select file C:\Windows\Microsoft.NET\Framework\v2.0.50727\ aspnet_isapi.dll (make sure you goto your windows folder)
6. Uncheck verify file exists
7. Click apply
Tim
In reply to Peter's post in this topic:
Does the current version (4.5.x) of Umbraco support remapping of the umbraco-folder by changing the 2 settings as shown in this topicstart?
I'm curious about this as well. I tried changing it, and all I get is a 404 error.
Preview pages are giving 404 - File or directory not found. it redirects to ipaddress/login/nodeid instead of ipaddress/nodeid. How do I fix this?
is working on a reply...