quick question about the management of https for the 2 versions of a domain

Discussion in 'Installation/Configuration' started by kameleon1er, Jun 29, 2022.

  1. kameleon1er

    kameleon1er Member

    Hello to all.
    I have a domain hosted by ovh for example.
    domain.com >> type A >> ip.server (ispConfig)
    www.domain.com >> type A >> ip.server (ispConfig)

    In isp, I check SSL / LEncrypt for the domain = OK

    But if I type in a browser "domain.com" without specifying 'http//" or "https//" the version without https loads telling me that the site is not secure.

    However, if I look in the VHOST, there is the "www" version in the alias.

    I must be doing it wrong somewhere...
     
  2. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    I thought all browsers nowadays use httpS if it is available?
    You write about http and https, and then writing www in domain name, they are separate things. You should include www in the https certificate, then that name is also certified. Then in the website settings Redirect tab choose "Rewrite HTTP to HTTPS". With those setups things should start working. If not, then I have not undertood what you were asking and you should word you quetion differently.
     
  3. kameleon1er

    kameleon1er Member

    Yes, you right, you understand perfectly, it's on www and non www version. Thanks, I'm checking :)
     
  4. kameleon1er

    kameleon1er Member

    it works perfectly, thanks @Taleman
     
  5. Jesse Norell

    Jesse Norell ISPConfig Developer Staff Member ISPConfig Developer

    Also enable HSTS header in the https site and then any browsers which are returning to the site (and hence have seen the HSTS header previously) will always bypass http and only use https. There are other useful security headers you can enable, too.
     
    Last edited: Jun 30, 2022
  6. kameleon1er

    kameleon1er Member

    Hi @Jesse Norell I think ispConfig done it for hsts.
    have you a link to explain ? Thanks
     
  7. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Using Internet Search Engines with
    Code:
    HSTS useful security headers
    finds useful articles.
     
    kameleon1er likes this.
  8. kameleon1er

    kameleon1er Member

    :( o…k…
     

Share This Page