Force http to https for the admin panel

Discussion in 'Installation/Configuration' started by GarGamel55, Aug 18, 2011.

  1. GarGamel55

    GarGamel55 Member


    I use SSL to connect to the admin panel, it works well. ---> Https://domain.tld:50443 or https://IP:50443

    But if I log into http (without the s), I get a bad request (of course :rolleyes:)

    How can I force the connection via SSL, but only for the panel and not the whole website

    I can do to phpmyadmin and roundcube, but not for the panel

  2. falko

    falko Super Moderator ISPConfig Developer

  3. GarGamel55

    GarGamel55 Member

    Yes, I know this

    I tried this (in ispconfig.vhost)

    <IfModule mod_rewrite.c>
      <IfModule mod_ssl.c>
        <Location />
          RewriteEngine on
          RewriteCond %{HTTPS} !^on$ [NC]
          RewriteCond %{SERVER_PORT}  ^50443$
          RewriteRule . https://%{HTTP_HOST}:50443%{REQUEST_URI}  [L]
    but it doesn't work

    An idea ?
  4. falko

    falko Super Moderator ISPConfig Developer

Share This Page