Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Professional For advanced ASP.NET 1.x coders. Beginning-level questions will be redirected to other forums. NOT for "classic" ASP 3 or the newer ASP.NET 2.0 and 3.5
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 1st, 2005, 07:36 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default ASP.Net Render Problem

Greetings All,
   I hope that someone can help me this problem as it is driving me nutty. I have a Windows Control Library that I have compiled into a .dll that is then embedded into a web form on my server. Now as I was developing this I had no problem with the embedding and rendering of the control, but, one of the last things this control does is write a file to a web directory. I went into IIS and set up Read and Write permissions on the necessary directory and also allowed for Execute Permissions: Scripts and Exectuables. After doing this my control renders as an empty Textarea???

If I go back into IIS and change the execute permissions to Scripts Only the control renders fine?? Does anyone know why this is happening, or how to fix it? If not, is there anyway to programatically bybass the secuirty on the File System so I can write this file? Any help would be greatly appreciated.

"The one language all programmers understand is profanity."
__________________
===============================================
Doug Parsons
Wrox online library: Wrox Books 24 x 7
Did someone here help you? Click on their post!
"Easy is the path to wisdom for those not blinded by themselves."
===============================================
 
Old December 3rd, 2005, 11:05 AM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

Being able to programmatically bypass the security would defeat the whole purpose of it. So the answer to that particular question is no.


(Great signature)

-Peter
 
Old December 3rd, 2005, 01:45 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 453
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via AIM to Ankur_Verma Send a message via MSN to Ankur_Verma
Default

Hi Peter and Doug,
How about sandboxing.
U strong name your control library and allow read write permission to it identified it by its strong name in caspol. Then you can entrust the caller (in this case your web application) from this control library (with a LinkDemand or an Assert), to allow access to the directory in question via the control library code.
This is no hack mind you.
It is a genuine way in which you are 'sandboxing' the file access code in an entrusted library and keeping the application that shouldn’t have higher permissions (your web application in this case) the way it is. U wont have to assign your web app any extra permissions this way.

Regards
Ankur Verma
 
Old December 5th, 2005, 11:27 AM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Thank you for your replies gentlemen. Ankur, thanks for the heads up, I ended up compliling the Control Library and added it to the GAC and everything seems to be working fine; thanks again for your comments!

"The one language all programmers understand is profanity."





Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom HTTP 404 Problem w/ASP to ASP.NET kwilliams ASP.NET 2.0 Professional 7 November 26th, 2007 04:17 PM
Problem Converting C# to VB.NET in ASP.NET kwilliams ASP.NET 2.0 Basics 0 February 9th, 2007 06:22 PM
Problem with Exercise in Beg. asp.net for VB.net! mrfella71 BOOK: Beginning ASP.NET 1.0 1 October 23rd, 2005 12:06 PM
.NET 1.1 version of Render procedure Crispin Horsfield BOOK: ASP.NET Website Programming Problem-Design-Solution 3 November 28th, 2003 02:10 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.