Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > temp folder?

Reply
Thread Tools

temp folder?

 
 
Dominick Baier [DevelopMentor]
Guest
Posts: n/a
 
      04-04-2006
hi,

1. you need the temp asp.net folder for the dynamically generated page assemblies
and \windows\temp is used for example for dynamically generated assemblies
from XmlSerializer

2. i think it uses the temp variable of the worker process account for \windows\temp
- the asp.net temp folder can be configured using the <compilation> element
in web.config

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

> Hi, I have two applications work fine in the test environment(win 2003
> server). but after moved to production server(win 2003 too), I need to
> gave c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
> files\ for one and c:\windows\temp for another to run. If I don't, I
> will get error: The current identity \WEB007\Appx_web does not have
> write access to c:\path. and it's from System.Web.HttpException.
>
> The host environment don't allow special settings outside the
> application
> path. so i have three questions here:
> 1. why I need to write right in the system temp folder?
> 2. can I configure so it will point to a temp folder under it
> subfolder?
> 3 is it relate to the application pool settings?
> Please advice.
> Thanks in advance



 
Reply With Quote
 
 
 
 
js
Guest
Posts: n/a
 
      04-04-2006
Hi, I have two applications work fine in the test environment(win 2003
server). but after moved to production server(win 2003 too), I need to gave
c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net files\ for
one and c:\windows\temp for another to run. If I don't, I will get error:
The current identity \WEB007\Appx_web does not have write access to c:\path.
and it's from System.Web.HttpException.

The host environment don't allow special settings outside the application
path. so i have three questions here:
1. why I need to write right in the system temp folder?
2. can I configure so it will point to a temp folder under it subfolder?
3 is it relate to the application pool settings?

Please advice.
Thanks in advance.


 
Reply With Quote
 
 
 
 
js
Guest
Posts: n/a
 
      04-04-2006
Thanks Dominick.

I found compilation section, but don't know to to set it up? Can you please
help? just give me an sample to change to default temp folder other than
system temp.


"Dominick Baier [DevelopMentor]" <(E-Mail Removed)>
wrote in message news:(E-Mail Removed). com...
> hi,
> 1. you need the temp asp.net folder for the dynamically generated page
> assemblies and \windows\temp is used for example for dynamically generated
> assemblies from XmlSerializer
>
> 2. i think it uses the temp variable of the worker process account for
> \windows\temp - the asp.net temp folder can be configured using the
> <compilation> element in web.config
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>
>> Hi, I have two applications work fine in the test environment(win 2003
>> server). but after moved to production server(win 2003 too), I need to
>> gave c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
>> files\ for one and c:\windows\temp for another to run. If I don't, I
>> will get error: The current identity \WEB007\Appx_web does not have
>> write access to c:\path. and it's from System.Web.HttpException.
>>
>> The host environment don't allow special settings outside the
>> application
>> path. so i have three questions here:
>> 1. why I need to write right in the system temp folder?
>> 2. can I configure so it will point to a temp folder under it
>> subfolder?
>> 3 is it relate to the application pool settings?
>> Please advice.
>> Thanks in advance.

>
>



 
Reply With Quote
 
Dominick Baier [DevelopMentor]
Guest
Posts: n/a
 
      04-04-2006
which version?

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

> Thanks Dominick.
>
> I found compilation section, but don't know to to set it up? Can you
> please help? just give me an sample to change to default temp folder
> other than system temp.
>
> "Dominick Baier [DevelopMentor]"
> <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed). com...
>
>> hi,
>> 1. you need the temp asp.net folder for the dynamically generated
>> page
>> assemblies and \windows\temp is used for example for dynamically
>> generated
>> assemblies from XmlSerializer
>> 2. i think it uses the temp variable of the worker process account
>> for \windows\temp - the asp.net temp folder can be configured using
>> the <compilation> element in web.config
>>
>> ---------------------------------------
>> Dominick Baier - DevelopMentor
>> http://www.leastprivilege.com
>>> Hi, I have two applications work fine in the test environment(win
>>> 2003 server). but after moved to production server(win 2003 too), I
>>> need to gave
>>> c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
>>> files\ for one and c:\windows\temp for another to run. If I don't, I
>>> will get error: The current identity \WEB007\Appx_web does not have
>>> write access to c:\path. and it's from System.Web.HttpException.
>>>
>>> The host environment don't allow special settings outside the
>>> application
>>> path. so i have three questions here:
>>> 1. why I need to write right in the system temp folder?
>>> 2. can I configure so it will point to a temp folder under it
>>> subfolder?
>>> 3 is it relate to the application pool settings?
>>> Please advice.
>>> Thanks in advance



 
Reply With Quote
 
js
Guest
Posts: n/a
 
      04-04-2006
I'm using NET 2.0.

Many thanks,



"Dominick Baier [DevelopMentor]" <(E-Mail Removed)>
wrote in message news:(E-Mail Removed). com...
> which version?
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>
>> Thanks Dominick.
>>
>> I found compilation section, but don't know to to set it up? Can you
>> please help? just give me an sample to change to default temp folder
>> other than system temp.
>>
>> "Dominick Baier [DevelopMentor]"
>> <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed). com...
>>
>>> hi,
>>> 1. you need the temp asp.net folder for the dynamically generated
>>> page
>>> assemblies and \windows\temp is used for example for dynamically
>>> generated
>>> assemblies from XmlSerializer
>>> 2. i think it uses the temp variable of the worker process account
>>> for \windows\temp - the asp.net temp folder can be configured using
>>> the <compilation> element in web.config
>>>
>>> ---------------------------------------
>>> Dominick Baier - DevelopMentor
>>> http://www.leastprivilege.com
>>>> Hi, I have two applications work fine in the test environment(win
>>>> 2003 server). but after moved to production server(win 2003 too), I
>>>> need to gave
>>>> c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
>>>> files\ for one and c:\windows\temp for another to run. If I don't, I
>>>> will get error: The current identity \WEB007\Appx_web does not have
>>>> write access to c:\path. and it's from System.Web.HttpException.
>>>>
>>>> The host environment don't allow special settings outside the
>>>> application
>>>> path. so i have three questions here:
>>>> 1. why I need to write right in the system temp folder?
>>>> 2. can I configure so it will point to a temp folder under it
>>>> subfolder?
>>>> 3 is it relate to the application pool settings?
>>>> Please advice.
>>>> Thanks in advance.

>
>



 
Reply With Quote
 
Henning Krause [MVP]
Guest
Posts: n/a
 
      04-04-2006
Hello,

you need to add a "tempDirectory" attribute to the <compilation> tag in you
web.config.

Set the value of this attribute the name of the temporary directory.

Greetings,
Henning Krause

"js" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I'm using NET 2.0.
>
> Many thanks,
>
>
>
> "Dominick Baier [DevelopMentor]" <(E-Mail Removed)>
> wrote in message news:(E-Mail Removed). com...
>> which version?
>>
>> ---------------------------------------
>> Dominick Baier - DevelopMentor
>> http://www.leastprivilege.com
>>
>>> Thanks Dominick.
>>>
>>> I found compilation section, but don't know to to set it up? Can you
>>> please help? just give me an sample to change to default temp folder
>>> other than system temp.
>>>
>>> "Dominick Baier [DevelopMentor]"
>>> <(E-Mail Removed)> wrote in message
>>> news:(E-Mail Removed). com...
>>>
>>>> hi,
>>>> 1. you need the temp asp.net folder for the dynamically generated
>>>> page
>>>> assemblies and \windows\temp is used for example for dynamically
>>>> generated
>>>> assemblies from XmlSerializer
>>>> 2. i think it uses the temp variable of the worker process account
>>>> for \windows\temp - the asp.net temp folder can be configured using
>>>> the <compilation> element in web.config
>>>>
>>>> ---------------------------------------
>>>> Dominick Baier - DevelopMentor
>>>> http://www.leastprivilege.com
>>>>> Hi, I have two applications work fine in the test environment(win
>>>>> 2003 server). but after moved to production server(win 2003 too), I
>>>>> need to gave
>>>>> c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
>>>>> files\ for one and c:\windows\temp for another to run. If I don't, I
>>>>> will get error: The current identity \WEB007\Appx_web does not have
>>>>> write access to c:\path. and it's from System.Web.HttpException.
>>>>>
>>>>> The host environment don't allow special settings outside the
>>>>> application
>>>>> path. so i have three questions here:
>>>>> 1. why I need to write right in the system temp folder?
>>>>> 2. can I configure so it will point to a temp folder under it
>>>>> subfolder?
>>>>> 3 is it relate to the application pool settings?
>>>>> Please advice.
>>>>> Thanks in advance.

>>
>>

>
>



 
Reply With Quote
 
js
Guest
Posts: n/a
 
      04-05-2006
Thanks Henning,

Can it be related path or has to be "c:\myapp\mytemp\?


"Henning Krause [MVP]" <(E-Mail Removed)> wrote in
message news:%(E-Mail Removed)...
> Hello,
>
> you need to add a "tempDirectory" attribute to the <compilation> tag in
> you web.config.
>
> Set the value of this attribute the name of the temporary directory.
>
> Greetings,
> Henning Krause
>
> "js" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> I'm using NET 2.0.
>>
>> Many thanks,
>>
>>
>>
>> "Dominick Baier [DevelopMentor]" <(E-Mail Removed)>
>> wrote in message news:(E-Mail Removed). com...
>>> which version?
>>>
>>> ---------------------------------------
>>> Dominick Baier - DevelopMentor
>>> http://www.leastprivilege.com
>>>
>>>> Thanks Dominick.
>>>>
>>>> I found compilation section, but don't know to to set it up? Can you
>>>> please help? just give me an sample to change to default temp folder
>>>> other than system temp.
>>>>
>>>> "Dominick Baier [DevelopMentor]"
>>>> <(E-Mail Removed)> wrote in message
>>>> news:(E-Mail Removed). com...
>>>>
>>>>> hi,
>>>>> 1. you need the temp asp.net folder for the dynamically generated
>>>>> page
>>>>> assemblies and \windows\temp is used for example for dynamically
>>>>> generated
>>>>> assemblies from XmlSerializer
>>>>> 2. i think it uses the temp variable of the worker process account
>>>>> for \windows\temp - the asp.net temp folder can be configured using
>>>>> the <compilation> element in web.config
>>>>>
>>>>> ---------------------------------------
>>>>> Dominick Baier - DevelopMentor
>>>>> http://www.leastprivilege.com
>>>>>> Hi, I have two applications work fine in the test environment(win
>>>>>> 2003 server). but after moved to production server(win 2003 too), I
>>>>>> need to gave
>>>>>> c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
>>>>>> files\ for one and c:\windows\temp for another to run. If I don't, I
>>>>>> will get error: The current identity \WEB007\Appx_web does not have
>>>>>> write access to c:\path. and it's from System.Web.HttpException.
>>>>>>
>>>>>> The host environment don't allow special settings outside the
>>>>>> application
>>>>>> path. so i have three questions here:
>>>>>> 1. why I need to write right in the system temp folder?
>>>>>> 2. can I configure so it will point to a temp folder under it
>>>>>> subfolder?
>>>>>> 3 is it relate to the application pool settings?
>>>>>> Please advice.
>>>>>> Thanks in advance.
>>>
>>>

>>
>>

>
>



 
Reply With Quote
 
js
Guest
Posts: n/a
 
      04-05-2006
I did, but still have error if I remove everyone from c:\windows\temp\
folder:
Unhandled Error
Error Details
File
Error Unable to generate a temporary class (result=1). error CS2001:
Source file 'C:\WINDOWS\TEMP\omxg26yp.0.cs' could not be found error CS2008:
No inputs specified


How to fix?
Please advice. Thanks.

"Henning Krause [MVP]" <(E-Mail Removed)> wrote in
message news:%(E-Mail Removed)...
> Hello,
>
> you need to add a "tempDirectory" attribute to the <compilation> tag in
> you web.config.
>
> Set the value of this attribute the name of the temporary directory.
>
> Greetings,
> Henning Krause
>
> "js" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> I'm using NET 2.0.
>>
>> Many thanks,
>>
>>
>>
>> "Dominick Baier [DevelopMentor]" <(E-Mail Removed)>
>> wrote in message news:(E-Mail Removed). com...
>>> which version?
>>>
>>> ---------------------------------------
>>> Dominick Baier - DevelopMentor
>>> http://www.leastprivilege.com
>>>
>>>> Thanks Dominick.
>>>>
>>>> I found compilation section, but don't know to to set it up? Can you
>>>> please help? just give me an sample to change to default temp folder
>>>> other than system temp.
>>>>
>>>> "Dominick Baier [DevelopMentor]"
>>>> <(E-Mail Removed)> wrote in message
>>>> news:(E-Mail Removed). com...
>>>>
>>>>> hi,
>>>>> 1. you need the temp asp.net folder for the dynamically generated
>>>>> page
>>>>> assemblies and \windows\temp is used for example for dynamically
>>>>> generated
>>>>> assemblies from XmlSerializer
>>>>> 2. i think it uses the temp variable of the worker process account
>>>>> for \windows\temp - the asp.net temp folder can be configured using
>>>>> the <compilation> element in web.config
>>>>>
>>>>> ---------------------------------------
>>>>> Dominick Baier - DevelopMentor
>>>>> http://www.leastprivilege.com
>>>>>> Hi, I have two applications work fine in the test environment(win
>>>>>> 2003 server). but after moved to production server(win 2003 too), I
>>>>>> need to gave
>>>>>> c:\windows\microsoft.net\frameswork\v2.0.50727\tem porary asp.net
>>>>>> files\ for one and c:\windows\temp for another to run. If I don't, I
>>>>>> will get error: The current identity \WEB007\Appx_web does not have
>>>>>> write access to c:\path. and it's from System.Web.HttpException.
>>>>>>
>>>>>> The host environment don't allow special settings outside the
>>>>>> application
>>>>>> path. so i have three questions here:
>>>>>> 1. why I need to write right in the system temp folder?
>>>>>> 2. can I configure so it will point to a temp folder under it
>>>>>> subfolder?
>>>>>> 3 is it relate to the application pool settings?
>>>>>> Please advice.
>>>>>> Thanks in advance.
>>>
>>>

>>
>>

>
>



 
Reply With Quote
 
hB
Guest
Posts: n/a
 
      04-08-2006
In your configuration file:

<system.diagnostics>
<switches>
<add name="XmlSerialization.Compilation" value="0" />
</switches>
</system.diagnostics>
</configuration>

This would stop XMLSerializer to generated Temporary files.

But What I want to know that Why XMLSerializer is generating files and
running csc?
Also In my desktop application (Thick VBNet DotNet WinForm client) on
my development machine XMLSerializer is creating around 126 temp files
in temp dir, while on other Developer's machine it is not creating any
single temp file, why is that? how can I stop XMLSerializer to not to
generate them the same way as on other developer's machine it is not
generating. (Instead of disabling it from config file)

Also to mention it creates temp files differently everytime I launch my
application, it does not reuse previously built files which were always
there and eating my hdd.

---
hB

 
Reply With Quote
 
hB
Guest
Posts: n/a
 
      04-08-2006
Four you js:
BUG: Error When You Invoke Methods on a Web Service by Using ASP

http://support.microsoft.com/default...B;EN-US;322886

---
hB

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
FAQ 5.36 Why can't I use "C:\temp\foo" in DOS paths? Why doesn't `C:\temp\foo.exe` work? PerlFAQ Server Perl Misc 0 04-26-2011 10:00 AM
How to initialize member reference with temp object and delete the temp object when the destructor is called? PengYu.UT@gmail.com C++ 2 05-09-2005 05:48 PM
firefox- clear temp internet files? Fusion Blast Firefox 8 01-17-2005 05:35 AM
File::Temp: opening the temp. file in "r+" mode? Also "man in the middle" A. Farber Perl Misc 3 03-03-2004 12:42 PM
Temp Internet and temp files now in winnt directory w2k pro Bibble Bobble Computer Support 1 11-27-2003 06:14 PM



Advertisments