Hey guys,

  I submitted a bug report to [EMAIL PROTECTED] and it got returned without comment... (maybe it was the wrong place?)  so I guess i'll post it here since I know Joe Schaefer monitors this list :).  Any ideas what's going on here?  Thanks!

ken.

-------------8<---------- Start Bug Report ------------8<----------
1. Problem Description:

Hi.  Thanks for all of your hard work.

I have a problem trying to post a large value in an html field: the field isn't included in the param list.  The text of the html page doing the posting as well as the code
for the handler are below... 

I thought perhaps it is a size limit, but I set the MAX_POST to a large value and it had no effect.  If I use CGI.pm
instead it works just dandy.  When i post the form below to the handler below, i see all the fields except sys_bundle.  It is simply not present.  If I remove
a character and post again, the field will be present.  Add the character and post, it won't.  It doesn't matter about being xml, well-formed or not....  pasting in perl code or whatever
has the same effect. 

So, is there a length limit in apache::request?  Or is it just a weird bug?  I'm not on the dev list, so please cc me in any reply. 

Thanks!

ken.

=-=-=-=-=-
html form text:
=-=--=-=--=
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Box tool test</title>
</head>
<form action="" method="post"/>
sys_action<input name="sys_action" id="sys_action" value="save_box" type="text" size="30"/><br>
sys_name<input name="sys_name" id="sys_name" value="toolbox" type="text" size="30"/><br>
sys_community<input name="sys_community" id="sys_community" value="global" type="text" size="30"/><br>
sys_workcommunity<input name="sys_workcommunity" id="sys_workcommunity" value="testing" type="text" size="30"/><br>
sys_workname<input name="sys_workname" id="sys_workname" value="home" type="text" size="30"/><br>
sys_bundle<br><textarea name="sys_bundle" id="sys_bundle" type="text" cols="80" rows="35">
<gcxBoxes>
            <gcxBox>
                        <elementname>blank</elementname>
                        <boxname>testbox3</boxname><parentboxid>0</parentboxid>
                        <content>testbox3%20</content>
                        <width>100</width>
                        <height>100</height>
                        <left>142px</left>
                        <top>261px</top>
                        <zIndex>0</zIndex>
                        <float></float>
                        <clear>none</clear>
                        <filter></filter>
                        <marginTop></marginTop>
                        <marginRight></marginRight>
                        </borderLeftColor>
                        <borderLeftStyle>dashed</borderLeftStyle>
                        <borderLeftWidth>1</borderLeftWidth>
                        <borderRightColor>#000000</borderRightColor>
                        <borderRightStyle>dashed</borderRightStyle>
                        <borderRightWidth>1</borderRightWidth>
                        <l
>0</backgroundPositionY>
                        <fontFamily>Verdana,Arial,Helvetica,sans-serif</fontFamily>
                        <fontSize>11</fontSize>
                        <color>#000000</color>
                        <fontStyle></fontStyle>
                        <lineHeight></lineHeight>
                        <fontWeight>400</fontWeight>
                        <textTransform>none</textTransform>
                        <fontVariant></fontVariant>
                        <textDecoration>overline</textDecoration>
                        <wordSpacing></wordSpacing>
                        <letterSpacing></letterSpacing>
                        <parentid>656</parentid>
                        <report></report>
                        <boxtype>content</boxtype>
                        <boxid>1347</boxid>
            </gcxBox>
</gcxBoxes>
</textarea><br>
<input type="submit" value="update box"/>
</form>
<body>
</body>
</html>
=-=-=-=-=--==-=-


TestHandler.pm
=-=-=-=-=-=-=-=-
package GCX::Testing::ApacheTest;

  use strict;

  use Apache::Request;
  use Apache::RequestRec ();
  use Apache::RequestIO ();
  #use Apache::Cookie;

  use Apache::Const -compile => qw(OK REDIRECT);
  use GCX::Runtime::Context;

  use GCX::Runtime::Input::Processor;

  use XML::LibXSLT;
  use XML::LibXML;

  #Handles Apache requests that are directed to this module. 
  sub handler {

            my $r = shift;
            
            $r->content_type('text/html');

            my $q = Apache::Request->new($r, POST_MAX => 10048);

            my $buffer = "Ken's Variable Dumper 2<table border=1 width=200>";

            foreach my $varname ($q->param)
            {
                        warn "here we go: $varname " ;
                        $buffer .= "<tr>";
                        my $val = $q->param($varname);
                        $buffer .= "<td>$varname</td><td>$val</td>";
                        $buffer .= "</tr>";

            }

            $buffer .= "</table><hr/>And that's it";

            $r->print($buffer);

        return Apache::OK;

}
1;

=-=-=-=-=-=-
CGI version that works (always get sys_bundle)

package GCX::Testing::CGITest;

  use strict;

  use Apache::Request;
  use Apache::RequestRec ();
  use Apache::RequestIO ();
  #use Apache::Cookie;

  use Apache::Const -compile => qw(OK REDIRECT);
  use GCX::Runtime::Context;

  use GCX::Runtime::Input::Processor;

  use XML::LibXSLT;
  use XML::LibXML;
  use CGI;

  #Handles Apache requests that are directed to this module. 
  sub handler {

            my $r = shift;
            
            $r->content_type('text/html');
            Apache->request($r);

#          my $q = Apache::Request->new($r);

            my $q = CGI->new();  #<--- this line is the only significant difference.

            my $buffer = "Ken's Mod_perl+CGI Variable Dumper <table border=1
width=200>";

            foreach my $varname ( $q->param)
            {
                        warn "here we go: $varname " ;
                        $buffer .= "<tr>";
                        my $val = $q->param($varname);
                        $buffer .= "<td>$varname</td><td>$val</td>";
                        $buffer .= "</tr>";

            }
            $buffer .= "</table><hr/>And that's it";
            $r->print($buffer);

        return Apache::OK;

}
            

  1;



2. Used Components and their Configuration:

*** mod_perl version 1.9914

*** using lib/Apache/BuildConfig.pm
*** Makefile.PL options:
  MP_AP_PREFIX   => /usr/local/apache
  MP_COMPAT_1X   => 1
  MP_GENERATE_XS => 1
  MP_LIBNAME     => mod_perl
  MP_USE_DSO     => 1
  MP_USE_STATIC  => 1


*** /usr/local/apache/bin/httpd -V
Server version: Apache/2.0.49
Server built:   Jun  7 2004 11:55:43
Server's Module Magic Number: 20020903:7
Architecture:   32-bit
Server compiled with....
-D APACHE_MPM_DIR="server/mpm/prefork"
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
-D APR_USE_PROC_PTHREAD_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D HTTPD_ROOT="/usr/local/apache"
-D SUEXEC_BIN="/usr/local/apache/bin/suexec"
-D DEFAULT_PIDLOG="logs/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_LOCKFILE="logs/accept.lock"
-D DEFAULT_ERRORLOG="logs/error_log"
-D AP_TYPES_CONFIG_FILE="conf/mime.types"
-D SERVER_CONFIG_FILE="conf/httpd.conf"


*** /usr/bin/perl -V
Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration:
  Platform:
    osname=linux, osvers=2.4.21-1.1931.2.393.entsmp,
archname=i386-linux-thread-multi
    uname='linux por'
    config_args='-des -Doptimize=-O2 -g -pipe -march=i386 -mcpu=i686
-Dmyhostname=localhost [EMAIL PROTECTED] -Dcc=gcc -Dcf_by=Red
Hat, Inc. -Dinstallprefix=/usr -Dprefix=/usr -Darchname=i386-linux
-Dvendorprefix=/usr -Dsiteprefix=/usr -Dotherlibdirs=/usr/lib/perl5/5.8.0
-Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Dd_dosuid
-Dd_semctl_semun -Di_db -Ui_ndbm -Di_gdbm -Di_shadow -Di_syslog
-Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005
-Uversiononly -Dpager=/usr/bin/less -isr'
    hint=recommended, useposix=true, d_sigaction=define
    usethreads=define use5005threads=undef'
useithreads=define usemultiplicity=
    useperlio= d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=undef use64bitall=un uselongdouble=
    usemymalloc=, bincompat5005=undef
  Compiler:
    cc='gcc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS
-DDEBUGGING -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm',
    optimize='',
    cppflags='-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS - DDEBUGGING
-fno-strict-aliasing -I/usr/local/include -I/usr/include/gdbm'
    ccversion='', gccversion='3.2.3 20030502 (Red Hat Linux 3.2.3-19)',
gccosandvers=''
gccversion='3.2.3 200305'
    intsize=o, longsize=s, ptrsize=l, doublesize=8, byteorder=1234
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
    ivtype='long'
k', ivsize=4'
ivtype, nvtype='double'
o_no', nvsize=, Off_t='', lseeksize=8
    alignbytes=4, prototype=define
  Linker and Libraries:
    ld='gcc'
l', ldflags =' -L/usr/local/lib'
ldflags_use'
    libpth=/usr/local/lib /lib /usr/lib
    libs=-lnsl -lgdbm -ldb -ldl -lm -lpthread -lc -lcrypt -lutil
    perllibs=
    libc=/lib/libc-2.3.2.so, so=so, useshrplib=true, libperl=libper
    gnulibc_version='2.3.2'
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so', d_dlsymun=undef, ccdlflags='-rdynamic
-Wl,-rpath,/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE'
    cccdlflags='-fPIC'
ccdlflags='-rdynamic -Wl,-rpath,/usr/lib/perl5', lddlflags='s
Unicode/Normalize XS/A'


Characteristics of this binary (from libperl):
  Compile-time options: DEBUGGING MULTIPLICITY USE_ITHREADS
USE_LARGE_FILES PERL_IMPLICIT_CONTEXT
  Locally applied patches:
            MAINT18379
  Built under linux
  Compiled at Sep 15 2003 10:03:52
  %ENV:
    PERL_LWP_USE_HTTP_10="1"
  @INC:
    /usr/lib/perl5/5.8.0/i386-linux-thread-multi
    /usr/lib/perl5/5.8.0
    /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi
    /usr/lib/perl5/site_perl/5.8.0
    /usr/lib/perl5/site_perl
    /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi
    /usr/lib/perl5/vendor_perl/5.8.0
    /usr/lib/perl5/vendor_perl
    /usr/lib/perl5/5.8.0/i386-linux-thread-multi
    /usr/lib/perl5/5.8.0
    .

*** Packages of interest status:

Apache::Request: 2.03-dev
CGI            : 3.05
LWP            : 5.65
mod_perl       : 1.9914


3. This is the core dump trace: (if you get a core dump):

  [CORE TRACE COMES HERE]

This report was generated by ./t/REPORT on Thu Jul  8 17:55:20 2004 GMT.

-------------8<---------- End Bug Report --------------8<----------

Note: Complete the rest of the details and post this bug report to
dev <at> perl.apache.org. To subscribe to the list send an empty
email to [EMAIL PROTECTED].



--
Ken Burcham
Ken Burcham Consulting, Inc.
http://www.capemaystation.com

Reply via email to