Hi list,
a couple of weeks ago I discussed my web hosting setup with an SSL proxy se=
rver and Squirrelmail on the users list. Back then Tomas Kuliavas analyzed =
my setup and provided a patch for my problem, but only for the 1.4.x versio=
n of Squirrelmail.
Now I'd like to move on with SM 1.5.x because of some of the new features t=
hat I'd like to use. Here's some detais about my setup:
I was able to install SM 1.4.10a in a regular web hosting enviromnent witho=
ut any problems. To add security to my setup I wanted to use the SSL proxy =
server that is provided by my web hosting company. Unfortunately SM 1.4.10a=
was not able to handle my specific setup and failed during the login stage=
due to incorrectly rewritten URLs.
Here's how I access my website without SSL:
http://www.mydomain.com
And here's how the SSL proxy server comes into play:
https://ssl-proxy.com/mydomain.com
Now, when accessing SM through the ssl proxy with
https://ssl-proxy.com/mydomain.com/squirrelmail
I received the following error message:
"ERROR Unknown user or password incorrect."
The problem became obvious when looking at the generated URLs. Instead of r=
endering:
https://ssl-proxy.com/squirrelmail/src/login.php
SM rendered the following URL:
https://ssl-proxy.com/mydomain.com/squirrelmail/src/login.php
Setting $config_location_base to "https://ssl-proxy.com/mydomain.com/" didn=
't help with my setup.
Tomas Kulivas posted the following patches after analyzing my setup:
> Open SquirrelMail functions/strings.php.
> > Find lines with
> > ----
> > if ( sqgetGlobalVar('PHP_SELF', $php_self, SQ_SERVER) &&
> > !empty($php_self) ) {
> >=20
> > // need to add query string to end of PHP_SELF to match REQUEST_U=
RI
> > //
> > if ( sqgetGlobalVar('QUERY_STRING', $query_string, SQ_SERVER) &&
> > !empty($query_string) ) {
> > $php_self .=3D '?' . $query_string;
> > }
> >=20
> > return $php_self;
> > }
> > ----
> >=20
> > and modify them to
> > ----
> > if ( sqgetGlobalVar('PHP_SELF', $php_self, SQ_SERVER) &&
> > !empty($php_self) ) {
> >=20
> > // need to add query string to end of PHP_SELF to match REQUEST_U=
RI
> > //
> > if ( sqgetGlobalVar('QUERY_STRING', $query_string, SQ_SERVER) &&
> > !empty($query_string) ) {
> > $php_self .=3D '?' . $query_string;
> > }
> >=20
> > if (sqgetGlobalVar('HTTP_X_FORWARDED_SERVER',$proxy,SQ_SERVER) &&
> > $proxy =3D=3D 'ssl-proxy.com') {
> > $php_self =3D '/mydomain.com' . $php_self;
> > }
> >=20
> > return $php_self;
> > }
> > ----
> >=20
> > Then find lines with
> > ----
> > function get_location () {
> >=20
> > global $imap_server_type, $config_location_base;
> > ----
> >=20
> > and modify them to
> > ----
> > function get_location () {
> > global $imap_server_type, $config_location_base;
> > if (sqgetGlobalVar('HTTP_X_FORWARDED_SERVER',$proxy,SQ_SERVER) &&
> > $proxy =3D=3D 'ssl-proxy.com') {
> > $config_location_base=3D'https://ssl-proxy.com/mydomain.com';
> > }
> > ----
> >=20
> > location base must be set to autodetect in SquirrelMail configuration.
> >=20
and...
> > Find lines with
> > ----
> > function get_location () {
> > =20
> > global $imap_server_type, $config_location_base;
> > ----
> > =20
> > and modify them to
> > ----
> > function get_location () {
> > global $imap_server_type, $config_location_base;
> > if (sqgetGlobalVar('HTTP_X_FORWARDED_SERVER',$proxy,SQ_SERVER) &&
> > $proxy =3D=3D 'ssl-proxy.com') {
> > $config_location_base=3D'https://ssl-proxy.com';
> > }
> > ----
Unfortunately these patches are not suitable for the current 1.5.x developm=
ent release of SM. Could someone help in this matter? What changes are need=
ed to SM 1.5.x to support my SSL proxy setup?
Thanks in advance,
Gregor
Viel oder wenig? Schnell oder langsam? Unbegrenzt surfen + telefonieren
ohne Zeit- und Volumenbegrenzung? DAS TOP ANGEBOT F=DCR ALLE NEUEINSTEIGER
Jetzt bei Arcor: g=FCnstig und schnell mit DSL - das All-Inclusive-Paket
f=FCr clevere Doppel-Sparer, nur 34,95 =80 inkl. DSL- und ISDN-Grundgeb=
=FChr!
http://www.arcor.de/rd/emf-dsl-2
|