I changed this fix code in pound 2.4.4 and after maked the binaries but the
proplem persist

This my configuration file

###############################
User            "pound"
Group           "pound"
LogLevel        3
Alive           10


ListenHTTP
        Address 10.234.18.28
        Port    80
        RewriteLocation 1
        #RewriteDestination 1


        Service
                HeadRequire "Host: www.mysite.com.*"

                Session
                    Type Cookie
                    ID   "MYSITESESSIONID"
                    TTL  300
                End

                BackEnd
                     Address 192.168.1.100
                     Port    10000
                End
                BackEnd
                    Address 192.168.1.101
                    Port    10000
                End
                BackEnd
                    Address 192.168.1.102
                    Port    10000
                End
                BackEnd
                    Address 192.168.1.103
                    Port    10000
                End
                BackEnd
                    Address 192.168.1.104
                    Port    10000
                End

        End


End
######################################

when i get a http://www.mysite.com/default where default is a real
directory, pound receive a redirect from backend sending to the client the
port of backend.

for example in a client pc

telnet 10.234.18.28 80
Trying 10.234.18.28...
Connected to 10.234.18.28 (10.234.18.28).
Escape character is '^]'.
GET /default HTTP/1.0
host: www.mysite.com

HTTP/1.1 302 Object Moved
Location: http://www.mysite.com:10000/default/
Server: Microsoft-IIS/5.0
Content-Type: text/html
Content-Length: 173

in Location i think i haven“t to see the port of backend because i use
"RewriteLocation 1" directive

how can i solve this problem?
thanks!



2009/4/13 Emilio Campos <[email protected]>

> A lot of thanks SBR, I solved this problem downgrade version to 2.3.2 but i
> m going to upgrade with this solution
>
> 1k thanks ;)
>
> 2009/4/12 SBR <[email protected]>
>
> > Hi,
> >
> > I've just investigated some similar issues I've been having with pound
> not
> > rewriting the location when my backend appends its port to the correct
> > hostname when doing a redirect. I noticed the following if statement in
> > need_rewrite (svc.c line 742) which seems to have mismatched brackets:
> >
> >        if(memcmp(&be_addr.sin_addr.s_addr, &in_addr.sin_addr.s_addr,
> > sizeof(in_addr.sin_addr.s_addr)) == 0
> >        && (memcmp(&be_addr.sin_port, &in_addr.sin_port,
> > sizeof(in_addr.sin_port) != 0
> >            || strcasecmp(proto, (lstn->ctx == NULL)? "http": "https"))))
> {
> >
> > The second line is missing a closing bracket after the sizeof so the
> second
> > memcmp call is actually:
> >
> > memcmp(&be_addr.sin_port, &in_addr.sin_port, sizeof(in_addr.sin_port) !=
> 0
> > || strcasecmp(proto, (lstn->ctx == NULL)? "http": "https")))
> >
> > Changing this if to the following fixed the port on my redirects:
> >
> >        if(memcmp(&be_addr.sin_addr.s_addr, &in_addr.sin_addr.s_addr,
> > sizeof(in_addr.sin_addr.s_addr)) == 0
> >        && (memcmp(&be_addr.sin_port, &in_addr.sin_port,
> > sizeof(in_addr.sin_port)) != 0
> >            || strcasecmp(proto, (lstn->ctx == NULL)? "http": "https"))) {
> >
> > It looks like there is a similar issue for IPv6 redirects on line 754.
> >
> > Regards,
> > Andrew
> >
> > -----Original Message-----
> > From: Dave Steinberg [mailto:[email protected]]
> > Sent: 20 March 2009 15:04
> > To: [email protected]
> > Subject: Re: [Pound Mailing List] location headers problems
> >
> > >> telnet www.myweb.es 80
> > >> GET /principal/
> > >>
> > >> and I receive location header
> > >> Location /principal/index.php
> > >>
> > >> NO PROBLEM, but if i put
> > >>
> > >> telnet www.myweb.es 80
> > >> GET /principal  (without slash)
> > >>
> > >> Location header receibed:
> > >> Location: http://www.myweb.es:10000/principal/index.php
> > >>
> > >> and the client redirect to
> > http://www.myweb.es:10000/principal/index.php
> > >>
> > >> I think that rewritelocation 1 solve this problem but dont work,
> > >> I compiled pound 2.3.2 with this file configuration and work
> correctly,
> > the
> > >> client dont receive the backend port. Why ?
> > >>
> > >> I readed CHANGELOG for pound 2.4.4:
> > >>              -"fixed redirection problem (missing slash in
> > >> Location/Content-location)"
> >
> > This sounds like a problem with your backend.  Does the same thing
> > happen if you connect directly and issue those same GET commands?
> >
> >
> > --
> > Dave Steinberg
> > http://www.geekisp.com/
> > http://www.steinbergcomputing.com/
> >
> > --
> > To unsubscribe send an email with subject unsubscribe to [email protected].
> > Please contact [email protected] for questions.
> >
> >
> > --
> > To unsubscribe send an email with subject unsubscribe to [email protected].
> > Please contact [email protected] for questions.
> >
>
>
> --
> To unsubscribe send an email with subject unsubscribe to [email protected].
> Please contact [email protected] for questions.
>


--
To unsubscribe send an email with subject unsubscribe to [email protected].
Please contact [email protected] for questions.

Reply via email to