Re: Apache 2.2 mod_include mis-interpreting back-references

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Dan;

Yes, that silences the errors, thanks!

My question still remains - what changed in Apache that a construct it formerly parsed one way is now treated differently? Or not so much what changed, but why? Why does Apache now "care" what is inside an 'exec cmd' string?

Thanks again, now all I have to do is find all the darn docs to update them...

hugh

Dan Poirier wrote:
hugh williams <hughw@xxxxxxxxxxxxxxxx> writes:

<!--#exec cmd="echo $DOCUMENT_NAME | perl -e 'while (<>)
{s/(\w+)_(\w+)_[_abt]{3}\..*/sprintf \"<b>%s Option %s
Hyperlinks<\/b>\", uc $1,uc $2/e;print;}'" -->

This works fine in both Apache 1.3.33 and 2.2.3; however 2.2.3 also
send the following error warning into the error log:

[Wed Oct 22 14:50:00 2008] [warn] [client xxx.xxx.xxx.xxx] regex
capture $1 refers to no regex in /users/hughw/public_html/spclhand/z
1234_aba_abt.html
[Wed Oct 22 14:50:00 2008] [warn] [client xxx.xxx.xxx.xxx] regex
capture $2 refers to no regex in /users/hughw/public_html/spclhand/z
1234_aba_abt.html

This message is found in mod_include.c, and is not present in the
Apache 1.3 tree.

So, can someone explain to me why the error is triggered? The
include parses perfectly and the correct results are displayed, that
is, Perl handles things fine, but Apache apparently is trying to use
the "$1" and "$2" for its own needs as well as letting Perl have

Have you tried escaping the $ with \?  Maybe something like

<!--#exec cmd="echo $DOCUMENT_NAME | perl -e 'while (<>)
{s/(\w+)_(\w+)_[_abt]{3}\..*/sprintf \"<b>%s Option %s
Hyperlinks<\/b>\", uc \$1,uc \$2/e;print;}'" -->



--
Hugh Williams                  "More men are killed by overwork than the
hugh_williams@xxxxxxxxxxx       importance of the world justifies."
Agilent Technologies                           - Rudyard Kipling
Santa Rosa 4US-R                             "The Phantom Rickshaw", 1888
(707)-577-4941



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux