You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2011/05/24 15:21:45 UTC

DO NOT REPLY [Bug 51258] New: new features for mod_substitute

https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

             Bug #: 51258
           Summary: new features for mod_substitute
           Product: Apache httpd-2
           Version: 2.2.17
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: mod_substitute
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: horowity@gmail.com
    Classification: Unclassified


features included:
1. Support for SubstituteCond - ability to apply substitute rule only if the
configured conditions are met.
   The conditions input could be compared to request data, environment
variables and internal Apache notes.
   -- This section is similiar to RewriteCond, and I think it should go to a
common section in the code.

2. Support for SubstituteCheck – ability to perform quick search on the data
and use the results in order to avoid using “expensive” regular expression.

3. Supporting evaluation (at run time) of the searched and replaced patterns
before application (instead of static evaluation in configuration time).
    Evaluation result could be taken from request/response headers, environment
variables and internal Apache notes.

4. Adding some more options:

    a. Skip the replaced text from being processed by following rules.
       -- For this, I used a binary tree, which I didn't find in APR, can you
consider adding such implementation to APR?

    b. Stop applying other rules after specific rule is matched.

    c.    Option not to break the response into lines (and apply the substitute
rules on the whole response).

I know these changes need documentation, which I can provide, just I want to
know if they will accepted into the trunk, before writing it.

I hope you will find these changes helpful, and I'll be glad to hear your
opinion about them.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

--- Comment #6 from Chris <ch...@gmail.com> ---
Thanks Yehezkel,

For anyone else who has this problem - it can be fixed by appending 'e' to the
substitution command.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

--- Comment #4 from horowity@checkpoint.com <ho...@gmail.com> 2011-05-24 18:31:56 UTC ---
Hi

I think that mod_substitute with my new features is doing very good job
(depends on Admin configuration).
I don't see any reason why to dreprecate the existing mod_substitute (taking
into account that new module usually brings new bugs).

Since mod_sed is not exist in "released" version, it is hard for me to use it
in my environement (and I'm quite sure there are many developers with this
problem).

Why not give the user option to choose which module she wants to use?

Regards,

Yehezkel

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

--- Comment #1 from horowity@checkpoint.com <ho...@gmail.com> 2011-05-24 13:24:25 UTC ---
Created attachment 27051
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=27051
Patch + new .h file

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

--- Comment #3 from William A. Rowe Jr. <wr...@apache.org> 2011-05-24 16:42:57 UTC ---
Thank you for your interest, and contribution.

Note that it is very unlikely to be adopted at this time, as httpd 2.3-beta
(soon to be 2.4) deprecated mod_substitute, and introduced mod_sed.

I'd strongly encourage you to review mod_sed and determine if any of the
improvements you propose to mod_substitute remain applicable to mod_sed,
and absolutely offer them as a patch to httpd 2.3.

All this said, httpd is a collaborative environment, and I will leave your
ticket open for others to evaluate.  It's entirely possible you would find
enough httpd committers to entertain the idea of restoring an enhanced
mod_substitute, if mod_sed is not so easily tailored.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

--- Comment #5 from Chris <ch...@gmail.com> ---
I've tried the patch specifically to substitute in environment variables
(%{env:var_name}) but it seems to only allow access to local variables created
by the use of 'define' (${var_name}).

Please could you confirm how your code is to be used in this manner?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

horowity@checkpoint.com <ho...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |marc.stern@approach.be

--- Comment #2 from horowity@checkpoint.com <ho...@gmail.com> 2011-05-24 13:28:11 UTC ---
*** Bug 47220 has been marked as a duplicate of this bug. ***

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

horowity@checkpoint.com <ho...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |PatchAvailable
                 CC|                            |horowity@gmail.com
         Depends on|                            |51231

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

Bug 51258 depends on bug 51231, which changed state.

Bug 51231 Summary: Support running ap_regexec on strings that are not NULL terminated (buckets)
https://issues.apache.org/bugzilla/show_bug.cgi?id=51231

           What    |Old Value                   |New Value
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51258] new features for mod_substitute

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51258

William A. Rowe Jr. <wr...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Blocks|                            |47220

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org