1 Feb 02:28
Variable Expansion for Redirect Action and SecDefaultAction Inheritance
Neha Chriss <nchriss <at> gmail.com>
2012-02-01 01:28:17 GMT
2012-02-01 01:28:17 GMT
Hello,
I would like all of my rules to perform the default action of redirecting to a
custom page on our site. This redirect should supply the requests unique_id. I
thought the best method to do this would be using SecDefaultAction:
SecDefaultAction "setenv:unique_id=%{UNIQUE_ID}, \
phase:2,log,redirect:http://www2.site.com/pm/form.asp?i=3&eID=%{unique_id}
My custom rules that have no action specified work just fine this way,
but if a rule is triggered in any of the coremod security rulesets,
unique_id is not set and while a redirect *is* actually executed,
the %{unique_id} variable is sent as a literal string.
How can I force the %{unique_id} variable to expand on every redirect for all
rules? Is there a better way to accomplish this?
------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________ mod-security-users mailing list mod-security-users <at> lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mod-security-users Commercial ModSecurity Rules and Support from Trustwave's SpiderLabs: http://www.modsecurity.org/projects/commercial/rules/ http://www.modsecurity.org/projects/commercial/support/
RSS Feed