Running with Full Trust

Last post 12-14-2006, 1:18 AM by sherif.elmeteny. 2 replies.
Sort Posts: Previous Next
  •  12-13-2006, 4:39 PM 25102

    Running with Full Trust

     Greetings
     
    I am integrating cutechat with my web application, some parts in my application requires full trust, but I get null reference exceptions when I set <trust level="Full"/> , but the chat functionality runs fine with <trust level="Medium"/>
    I am using version 3.1.0.0. Below is a copy of the error I get and a copy of web.config (with some non relevant app settings keys and connection strings removed).
     
    NullReferenceException: Object reference not set to an instance of an object.]
       CuteSoft.Chat.ChatDataManager.GetConfigs() +66
       CuteSoft.Chat.ChatDataManager.GetConfig(String configname) +17
       CuteSoft.Chat.ChatApiImpl.DoGetConfig(String name) +149
       CuteSoft.Chat.ChatApiImpl.GetConfig(String name) +66
       CuteSoft.Chat.ChatWebUtility.GetUserAdapter() +77
       CuteSoft.Chat.ChatWebUtility.get_CurrentIdentity() +76
       CuteSoft.Chat.ChatWebUtility.get_CurrentIdentityIsAdministrator() +5
       ASP.banner_ascx.Page_Load(Object sender, EventArgs e) in d:\Parliament\CuteChat\banner.ascx:69
       System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15
       System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34
       System.Web.UI.Control.OnLoad(EventArgs e) +99
       System.Web.UI.Control.LoadRecursive() +47
       System.Web.UI.Control.LoadRecursive() +131
       System.Web.UI.Control.LoadRecursive() +131
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1061
     


    <?
    xml version="1.0"?>
    <
    configuration>
    <
    appSettings>
    <
    add key="ConnectionString" value="Server=(local);Database=CuteChat;Integrated Security=true;"/>
    <
    add key="OnlineTimeout" value="300"/>
    </appSettings>
    <system.web>
    <
    compilation defaultLanguage="c#" debug="true" />
    <customErrors mode="Off"/>
    <
    authentication mode="Forms" />
    <
    authorization>
    <
    allow users="*"/>
    </
    authorization>
    <
    trace enabled="true" />
    <
    trust level="Full"/>
    <
    sessionState mode="Off" timeout="20" />
    <
    globalization requestEncoding="utf-8" responseEncoding="utf-8" />
    <
    xhtmlConformance mode="Legacy"/>
    </
    system.web>
    </
    configuration>
  •  12-13-2006, 5:09 PM 25104 in reply to 25102

    Re: Running with Full Trust

    >>but I get null reference exceptions when I set <trust level="Full"/> , but the chat functionality runs fine with <trust level="Medium"/>
     
    It's very strange.
     
    Try remove the following code from your web.config and try again:
     
    <trust level="Full"/>
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  12-14-2006, 1:18 AM 25112 in reply to 25104

    Re: Running with Full Trust

    I did. Same error (the default setting for the machine is full trust)
View as RSS news feed in XML