ERROR: the required buffer size (447) exceeds the limit (0)

Topics: Developer Forum, Project Management Forum, User Forum
Oct 25, 2011 at 7:20 PM
Edited Oct 25, 2011 at 7:21 PM

Hi there,

I was running IIRF with the following proxy ruleset on w2k3 with no issues:

RewriteCond    %{HTTP_HOST}    ^www\.uk\.myhost\.com$

RedirectRule ^/blog$         /blog/          [I]

# proxy the directory
ProxyPass   ^/blog/(.*)$    http://blog.myhost.com/uk/$1

Now I'm trying to move my site to w2k8. The same rule with the latest release of IIRF produces the following log output:

Tue Oct 25 19:13:11 -  3216 - EvaluateRules: Rule 279: pattern: ^/blog/(.*)$  subject: /blog/
Tue Oct 25 19:13:11 -  3216 - EvaluateRules: Rule 279: 2 matches
Tue Oct 25 19:13:11 -  3216 - ReplaceServerVariables: alloc 36 bytes
Tue Oct 25 19:13:11 -  3216 - ReplaceServerVariables: in='http://blog.uk.myhost.com/uk/$1' out='http://blog.uk.tdk-lambda.com/uk/$1'
Tue Oct 25 19:13:11 -  3216 - GenerateReplacementString: src='/blog/','(null)' replacePattern='http://blog.uk.myhost.com/uk/$1' vec=[[  0, 6, 6, 6] [] ] counts=2,0
Tue Oct 25 19:13:11 -  3216 - GenerateReplacementString: alloc 35 bytes
Tue Oct 25 19:13:11 -  3216 - GenerateReplacementString: replacing ($1) with ''
Tue Oct 25 19:13:11 -  3216 - ApplyCaseConversion: before 'http://blog.uk.myhost.com/uk/'
Tue Oct 25 19:13:11 -  3216 - ApplyCaseConversion: after  'http://blog.uk.myhost.com/uk/'
Tue Oct 25 19:13:11 -  3216 - ApplyUrlEncoding: in 'http://blog.uk.myhost.com/uk/'
Tue Oct 25 19:13:11 -  3216 - ApplyUrlEncoding: out 'http://blog.uk.myhost.com/uk/'
Tue Oct 25 19:13:11 -  3216 - GenerateReplacementString: result 'http://blog.uk.myhost.com/uk/'
Tue Oct 25 19:13:11 -  3216 - EvaluateRules: Result (length 33): http://blog.uk.myhost.com/uk/
Tue Oct 25 19:13:11 -  3216 - EvaluateRules: returning 999
Tue Oct 25 19:13:11 -  3216 - DoRewrites: Proxy to: 'http://blog.uk.myhost.com/uk/'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'ALL_RAW'
Tue Oct 25 19:13:11 -  3216 - ** ERROR: the required buffer size (447) exceeds the limit (0)
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree - failed (error 24, The program issued a command but the command length is incorrect.)
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 447 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result ''
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'REQUEST_METHOD'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 4 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result 'GET'
Tue Oct 25 19:13:11 -  3216 - IirfProxy_TryRelayEmptyBodyRequest: http://blog.uk.myhost.com/uk/
Tue Oct 25 19:13:11 -  3216 - ParseAllRaw:
Tue Oct 25 19:13:11 -  3216 - ParseAllRaw: found 0 headers
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'REMOTE_ADDR'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 14 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result '192.168.1.1'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'LOCAL_ADDR'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 14 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result '192.168.1.1'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'HTTP_REFERER'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 128 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result ''
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'HTTP_USER_AGENT'
Tue Oct 25 19:13:11 -  3216 - ** ERROR: the required buffer size (138) exceeds the limit (0)
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree - failed (error 24, The program issued a command but the command length is incorrect.)
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 138 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result ''
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'HTTP_ACCEPT'
Tue Oct 25 19:13:11 -  3216 - ** ERROR: the required buffer size (164) exceeds the limit (0)
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree - failed (error 24, The program issued a command but the command length is incorrect.)
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 164 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result ''
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'SERVER_NAME'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 22 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result 'www.uk.myhost.com'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: getting 'REQUEST_METHOD'
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: 4 bytes
Tue Oct 25 19:13:11 -  3216 - GetServerVariable_AutoFree: result 'GET'
Tue Oct 25 19:13:11 -  3216 - ProxyRequest: host(blog.uk.myhost.com)  path+query(/uk/)
Tue Oct 25 19:13:11 -  3216 - GenProxyRequestHeadersString: rh(0x00000000) nh(blog.uk.myhost.com) sn(www.uk.myhost.com) la(192.168.1.1) ra(192.168.1.1) ts(0)
Tue Oct 25 19:13:11 -  3216 - ProxyRequest: WinHttpConnect blog.uk.myhost.com 80
Tue Oct 25 19:13:11 -  3216 - ProxyRequest: WinHttpOpenRequest: GET /uk/
Tue Oct 25 19:13:11 -  3216 - ProxyRequest: WinHttpAddRequestHeaders
Tue Oct 25 19:13:11 -  3216 - IirfProxy_TryRelayEmptyBodyRequest: Error in WinHttpAddRequestHeaders(): 87
Tue Oct 25 19:13:11 -  3216 - DoRewrites: Proxy complete: 0 chunks, 0 bytes'
Tue Oct 25 19:13:11 -  3216 - DoRewrites: Finish. SF_STATUS_REQ_ERROR  LastError=87
Tue Oct 25 19:13:11 -  3216 - HttpFilterProc: SF_NOTIFY_LOG
Tue Oct 25 19:13:11 -  3216 - ReleaseOrExpireVdirConfig: vdir '/LM/W3SVC/2/ROOT' (era=0) (rc=0) (Expired=0) (ptr=0x020A3878)...

I'm running x86 version of IIRF and w2k8. Other redirection rules are working. Any help or a suggestion would be greatly appreciated.

 

Thank you,

Pavel

 

 

 

Oct 27, 2011 at 1:33 AM

Ah, that's a bug in IIRF, in some code I just introduced.

You can solve this in one of two ways:

  • download the new IIRF , v2.1.2.2, which includes the necessary fix
  • introduce a file, IirfConfig.ini, colocated with the IIRF.dll file.  It need not have any content. But you might want to insert a comment (#) stating the reason it exists.

That is an either-or thing. You don't need both.  It's ok to do both, but you need only one of the above.

 

 

 

Oct 27, 2011 at 1:35 AM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Oct 27, 2011 at 10:08 AM

Many thanx for the fix. It looks ok with the updated v2.1.2.2. I'm going to deploy it into production and let you know if any issues.

Nov 2, 2011 at 7:40 PM

Glad to  hear it.