All,
I got DotNetNuke to install on 1and1 and get rid of the security error. I won't go into painstaking detail on whatI did it or what combo finally worked but here's the critical piece of info (I think...). Someone else needs to try this in EXACTLY this same order:
1. I created an Sub Directory called DotNetNuke under my home website.
2. I gave the IUSR and Network Service Modify/Write access to the folder
3. I created an Application called DotNetNuke using their webfiles application and pointed it to the DotNuke directory noted in step 1.
4. I ftp'd an install package with the release.config changed to web.config and changed all of the settings noted in the DNN Installation Guide including changing this line belows in the web.config file to point the temp Directory to my physical folder path (I'm not sure if this is really necessary). Change the xxxxx's to your dnn path.
Changed this:
<compilation debug="false" strict="false">
to this:
<compilation debug="false" tempDirectory="E:\kunden\homepages\xx\xxxxxxxx\DotNetNuke\" >
5. After ftp'ing the files, I went through the install. Many failed. Mostly the modules. Be persistant. I believe that the script timeout for the 1and1 host server plays into this. I deleted my tables many times before I finally got a portal created. I then started all over but this time did not transfer any modules in the install\modules folder of the DNN install.
6. I then installed each module one at a time. I Had to fix the Announcements module due to an incorrect parameters error as noted by another post on the forums here that have to do with renaming some sql provider scripts to create the schema from {dboowner}{dbqualifier}sysobjects to dbo.sysobjects. I followed this posts instructions and re-installed the Announcement module.
7. And finally, I kept noticing that the errors were related to trying to read config settings out of the webconfig. It seems that DNN stores an apppath on application start based on the current context request. I believe that the URL Rewriter may be causing a problem here because it is not storing anything in the ApplicationPath variable. So I traced my way through how config settings are read via the source code. It lead me to the
Config.vb
file in the DotNetNuke.Common.Utilities namespace which has this line of code:
Dim
webConfig As System.Configuration.Configuration = WebConfigurationManager.OpenWebConfiguration(Globals.ApplicationPath)
Notice it uses the Globals.ApplicationPath to get the web.config file for this application. I then tracked down the Globals.ApplicationPath set statement of the DNN Source Code and found some interesting code in the
App_Code\Global.asax.vb
So I commented out that code below and HARDCODED my application path to mirror the Application Name I created using webfiles. (see code below). I believe that some requests were setting the ApplicationPath to "" which would cause the dnn application to try and access a configuration at the root of your website, not within your dnn folder. Big NO-NO for the machine.config settings on 1and1 Servers. With 1and1, you can only access files for read/write etc..within your appdomain, not someone elses which is exactly what it thinks you are trying to do accessing something at / instead of /DotNetNuke (in my case).
Private Sub Application_Start(ByVal Sender As Object, ByVal E As EventArgs)
Dim Server As HttpServerUtility = HttpContext.Current.Server
'global variable initialization
ServerName = Server.MachineName
'FrankT Commented out the if then else below and hardcoded my path:
' If HttpContext.Current.Request.ApplicationPath = "/" Then
'ApplicationPath = ""
' Else
'ApplicationPath = HttpContext.Current.Request.ApplicationPath
'End If
ApplicationPath =
"/DotNetNuke"
I've been testing it on and off for about an hour and not one security exception. I think it was no 7 that did the trick. I'm not sure why the HttpContext.Current.Request.ApplicationPath is getting set to the root, but my guess is because most of us have a redirect at the root of our 1and1 site to redirect the user to our dnn sub-folder. I'm not sure the ApplicationPath is being set properly for a 302 redirect??
Anyway, hope this helps someone else. Let me know if this all works. Like I said, I think the key is opening your App_Code\Global.asax.vb file and hardcoding your 1and1 DNN application path. BTW, DO NOT PUT TRAILING / on the Application Path.
Frank T