Article delegate-en/4497 of [1-5169] on the server localhost:119
  upper oldest olders older1 this newer1 newers latest
search
[Top/Up] [oldest] - [Older+chunk] - [Newer+chunk] - [newest + Check]
[Reference:<_A4496@delegate-en.ML_>]
Newsgroups: mail-lists.delegate-en

[DeleGate-En] Re: match for X-Request
01 Jul 2009 03:29:12 GMT feedback@delegate.org (Yutaka Sato)
The DeleGate Project


Hi Jens,

In message <_A4496@delegate-en.ML_> on 07/01/09(03:07:29)
you Jens-Erik Hansen <puicqbdyi-6rjyzcjrb43r.ml@ml.delegate.org> wrote:
 |I currently try to match for X-Request or X-Request-Original in an
 |xml-secure stream.
...
 |Now i would like to match for "/xmlrpc/data" but my CFI-script seem to
 |have no effect.

You are right.  Selecting a FTOCL filter over HTTP with CFI's "X-Request"
condition has been disabled since 9.2.3-pre4, in which conditional CFI
for FTOCL was modified to reduce the overhead of CFI, reducing the
needless invocations of CFI process when the condition seems not true,
but without seeing "X-Request" condition... 

I added a workaround to fix it as the enclosed patch in 9.9.4-pre9.
I'm planning to replace the implementation of CFI script interpreter
from a process to a light weight thread thus it will be really fixed in
near future.

Cheers,
Yutaka
--
  9 9   Yutaka Sato <y.sato@delegate.org> http://delegate.org/y.sato/
 ( ~ )  National Institute of Advanced Industrial Science and Technology
_<   >_ 1-1-4 Umezono, Tsukuba, Ibaraki, 305-8568 Japan
Do the more with the less -- B. Fuller


*** ../../dist/src/delegate9.9.4-pre8/src/http.c	Thu Jun 11 10:57:08 2009
--- src/http.c	Wed Jul  1 11:52:48 2009
***************
*** 4681,4686 ****
--- 4681,4692 ----
  		sv1log("ERROR: findCFI(NO HEAD)\n");
  		return "";
  	}
+ 	if( strcasestr(CFIscript,"X-Request") ){
+ 		/* 9.9.4 headers to be put in HTTP_echoRequestHeader() ... */
+ 		Xsprintf(TVStr(headb),"X-Request-User-Agent: %s\r\n",REQ_UA);
+ 		Xsprintf(TVStr(headb),"X-Request-Original: %s",OREQ);
+ 		Xsprintf(TVStr(headb),"X-Request: %s",REQ);
+ 	}
  
  	spec = CFI_searchSpecEnv(Conn,CFIscript,stat,head);
  	if( spec == 0 ){

  admin search upper oldest olders older1 this newer1 newers latest
[Top/Up] [oldest] - [Older+chunk] - [Newer+chunk] - [newest + Check]
@_@V