I really have no idea what could cause the user.config problem other than a typo or file corruption of the user.config file
Maybe try uploading a new user.config but not named user.config, name it my.config before uploading it then set
<appSettings file="my.config">
The only other suggestion I can think of is to re-install the .NET 4 framework, I have seen cases where a particular machine had a funky installation. In fact just recently when I submitted the mojoPortal 2.3.9.4 release to the web app gallery they rejected it and said it failed to run under medium trust. I was not able to get any error under medium trust using the same package and I also tested using the source code under medium trust. Finally they got back to me and said the .net 4 installation on their test machine was funky and after re-installing it it worked fine for them under medium trust. Though the error they were getting was a security error not the same error you are getting.
Best,
Joe