开发者

Are Apache Environment Variables "request safe"?

开发者 https://www.devze.com 2022-12-28 11:45 出处:网络
I have my Apache web server fronting a Rails application. When a request comes in one of the Apache modules looks at the request and puts information into an Apache environment variable. My question i

I have my Apache web server fronting a Rails application. When a request comes in one of the Apache modules looks at the request and puts information into an Apache environment variable. My question is, is there a chance that one r开发者_Python百科equest can overwrite the environment variable of another request and have things get mixed up in the Rails layer?

Are Apache Environment Variables shared across Apache processes?


It sounds like you're using mod_setenvif, in which case, according to Environment Variables in Apache:

For additional flexibility, the directives provided by mod_setenvif allow environment variables to be set on a per-request basis, conditional on characteristics of particular requests.

It makes no sense to me that variables set in one request could affect another request. Race conditions would be rampant and nothing would work.

0

精彩评论

暂无评论...
验证码 换一张
取 消