If you happen to be running Symfony 2 on a port other than 80 or 443,
the result of Request::getUri() includes the port *twice*. For
example, I use Zend Server CE which defaults to port 10088, so in a
simple test controller I get the following results:

    [Request::getHost()] => sym2.local:10088
    [Request::getHttpHost()] => sym2.local:10088
    [Request::getUri()] => http://sym2.local:10088:10088/register

I'm not sure which method (getHost vs getHttpHost) getUri *should* be
using, but currently it appends the port number to getHost(), which
will always be a duplicate if you're not on 80 or 443. Wouldn't it
make sense to remove the calls to getHost and getPort in favor of a
single call to getHttpHost in getUri?

It's all very confusing, but something's definitely going wrong here.
Any insights?

Greg

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/symfony-devs?hl=en

Reply via email to