Re: Security Exception Thrown under .NET 2.0 Medium Trust While Uploading Files/Media

  •  08-17-2006, 2:22 PM

    Re: Security Exception Thrown under .NET 2.0 Medium Trust While Uploading Files/Media

    Jamie,
     
    >>it's just that it seems like a lot of work just to make the file upload work remotely in a situation where and ISP uses UNC.
     
    It needs some configurations. Because the local ASPNET account or NETWork Service account don't have permission to access the remove server by default.
     
    >><security name="FilesGalleryPath">~/documents</security>
     
    The application based file path is supported by CuteEditor as well.

    How to specify the Image gallery path?

    You can easily specify the image gallery path using the following methods:

    1: Edit security policy file.


    The security policy file (default.config, admin.config and guest.config) can be found in the /CuteEditor/Configuration/Security folder. In security policy file you can find the ImageGalleryPath element which contains the image gallery path information within Cute Editor.  By default, it contains the following value:


    <
    security name="ImageGalleryPath">~/uploads</security>
      

    You can modify the ImageGalleryPath element to meet your own requirements.

    For example:

    Use absolute path:

    <security name="ImageGalleryPath">/uploads</security>

     

    Use physical path:

    <security name="ImageGalleryPath">c:\inetpub\wwwroot\uploads</security>

     

    2: Programmatically specify the Image gallery path


    C# Example:

    //use the app-based path 

    Editor1.Setting["security:ImageGalleryPath"]= "~/uploads";
    //use the absolute path 
    Editor1.Setting["security:ImageGalleryPath"]= "/uploads";
    //use the physical path 
    Editor1.Setting["security:ImageGalleryPath"]= @"c:\inetpub\wwwroot\uploads";
    or
    //use the app-based path 

    Editor1.SetSecurityImageGalleryPath= "~/uploads";
    //use the absolute path 
    Editor1.SetSecurityImageGalleryPath= "/uploads";
    //use the physical path 
    Editor1.SetSecurityImageGalleryPath= @"c:\inetpub\wwwroot\uploads";


    VB Example:

    //use the app-based path 

    Editor1.Setting("security:ImageGalleryPath")= "~/uploads"
    //use the absolute path 
    Editor1.Setting("security:ImageGalleryPath")= "/uploads"
    //use the physical path 
    Editor1.Setting("security:ImageGalleryPath")= "c:\inetpub\wwwroot\uploads" 
    or
    //use the app-based path 

    Editor1.SetSecurityImageGalleryPath= "~/uploads"
    //use the absolute path 
    Editor1.SetSecurityImageGalleryPath= "/uploads"
    //use the physical path 
    Editor1.SetSecurityImageGalleryPath= "c:\inetpub\wwwroot\uploads" 
     
     
     
     

    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

    Filed under:
View Complete Thread