代码之家  ›  专栏  ›  技术社区  ›  Jon Dewees

Sharepoint SSL Web.Config访问问题

  •  1
  • Jon Dewees  · 技术社区  · 17 年前

    我得到了一个调用GAC中dll的web部件,它正试图从web.config文件中读取一个节。 这在正常情况下工作正常,但在SSL下失败,表示它无法访问(配置文件的)路径。但是,它位于mosssvc帐户下,该帐户完全控制webconfig文件。

    80 web.config文件和443 web.config文件都具有dll正在查找的相同条目,MOSSVC对这两个配置具有完全控制权。

    我尝试将443上的信任级别提升到完全信任级别,但没有成功。

    编辑:我应该更清楚一点:SSL站点已经创建,并且工作正常,直到GAC程序集中的one方法尝试检查web配置。

    完整的错误消息是:

    Event Type:        Warning
    Event Source:    ASP.NET 2.0.50727.0
    Event Category:                Web Event 
    Event ID:              1310
    Date:                     2/9/2009
    Time:                     1:44:49 PM
    User:                     N/A
    Computer:          XXXXX
    Description:
    Event code: 3008 
    Event message: A configuration error has occurred. 
    Event time: 2/9/2009 1:44:49 PM 
    Event time (UTC): 2/9/2009 9:44:49 PM 
    Event ID: 2d7180cdfbb34acfa6c61f95df12ddde 
    Event sequence: 26 
    Event occurrence: 1 
    Event detail code: 0 
    
    Application information: 
        Application domain: YYYYYYYYYYYYYYYYYYYYYYY
        Trust level: Full 
        Application Virtual Path: / 
        Application Path: C:\Inetpub\wwwroot\wss\VirtualDirectories\8443\ 
        Machine name: XXXXXXXX 
    
    Process information: 
        Process ID: 5168 
        Process name: w3wp.exe 
        Account name: XXXXXXXXX\mosssvc 
    
    Exception information: 
        Exception type: ConfigurationErrorsException 
        Exception message: An error occurred loading a configuration file: Access to the path 'C:\Inetpub\wwwroot\wss\VirtualDirectories\8443\web.config' is denied. (C:\Inetpub\wwwroot\wss\VirtualDirectories\8443\web.config) 
    
    Request information: 
        Request URL: https://XXXXXXX:443/training/Pages/smartregister.aspx?c=383 
        Request path: /training/Pages/smartregister.aspx 
        User host address: 64.34.27.186 
        User:  
        Is authenticated: False 
        Authentication Type:  
        Thread account name: XXXXXXX\mosssvc 
    
    Thread information: 
        Thread ID: 10 
        Thread account name: XXXXXXX\mosssvc 
        Is impersonating: True 
        Stack trace:    at System.Configuration.ConfigurationSchemaErrors.ThrowIfErrors(Boolean ignoreLocal)
       at System.Configuration.BaseConfigurationRecord.ThrowIfParseErrors(ConfigurationSchemaErrors schemaErrors)
       at System.Configuration.Configuration..ctor(String locationSubPath, Type typeConfigHost, Object[] hostInitConfigurationParams)
       at System.Configuration.Internal.InternalConfigConfigurationFactory.System.Configuration.Internal.IInternalConfigConfigurationFactory.Create(Type typeConfigHost, Object[] hostInitConfigurationParams)
       at System.Web.Configuration.WebConfigurationHost.OpenConfiguration(WebLevel webLevel, ConfigurationFileMap fileMap, VirtualPath path, String site, String locationSubPath, String server, String userName, String password, IntPtr tokenHandle)
       at System.Web.Configuration.WebConfigurationManager.OpenWebConfigurationImpl(WebLevel webLevel, ConfigurationFileMap fileMap, String path, String site, String locationSubPath, String server, String userName, String password, IntPtr userToken)
       at System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration(String path)
       at XXXXXXXXX.RegistrationHelper.RegisterStudents(Boolean sendEmail, String Time, String Title, String bFirstName, String bLastName, String bAddress, String bPostalCode, String bCity, String bTelephone, String bCompany, String bEmail, List`1 Registrants, Int32 courseDateID, String pType, String CCNumber_, String NameOnCard, String cExpiry, Double Discount, String DiscountCode, Double CostPerRegistrant, String PurchaseOrder)
       at ASP.SmartEventRegistration.lnkSubmit_Click(Object sender, EventArgs e) in c:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\CONTROLTEMPLATES\SmartEventRegistration\SmartEventRegistration.ascx:line 401
       at System.Web.UI.WebControls.LinkButton.OnClick(EventArgs e)
       at System.Web.UI.WebControls.LinkButton.RaisePostBackEvent(String eventArgument)
       at System.Web.UI.WebControls.LinkButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
       at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
       at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.ProcessRequest()
       at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)
       at System.Web.UI.Page.ProcessRequest(HttpContext context)
       at Microsoft.SharePoint.Publishing.TemplateRedirectionPage.ProcessRequest(HttpContext context)
       at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    
    1 回复  |  直到 17 年前
        1
  •  1
  •   Ric Tokyo    17 年前

    试试这个,form Faranz Kan SharePoint blog 关于如何在MOSS中启用SSL:

    1. 创建一个新的web应用程序。
    2. 在web应用程序上启用SSL。如果 您正在为此使用主机头 (重要事项:确保设置端口 到443,而不是80)。
    3. 创建web应用程序后,重置IIS,然后打开 iismmc。滚动至IIS网站 从中选择正确的SSL证书 可用的证书(请咨询您的 或外部SSL证书,具体取决于 服务器)。重要事项:回家 “目录”选项卡,然后单击“高级”。制作 端口80的正确IP。对于SSL条目, 选择端口443和IP地址。(如果你 在服务器上有多个IP,我 通常在这里选一个 条目)。单击“编辑”按钮进行编辑 SSL条目并检查“需要” “加密”使其更安全。
    4. 现在,继续为该web应用创建您的第一个网站集。苔藓 为您收集并呈现给您 带着一个“https://..“联系 准备好网络应用程序。
      • 这在IIS 6中不起作用。如果您想创建多个MOSS 2007 Web应用程序 启用SSL后,有两种方式 需要SSL web应用程序的多个IP 主目录-->先进的其他的 选项是修改IIS元数据库 允许服务器上有多个SSL web应用程序 你在做什么。