apache: Enable and prioritize HTTP/2 protocol

- Enabling the module automatically sets 'Protocols h2 h2c http/1.1' in shipped
module configuration.

- HTTP/2 is given higher priority over HTTP/1.1 for supported clients.

- Clients not supporting HTTP/2 continue to work with HTTP/1.1.

- Clients work by using APLN extension in TLS to figure out that server supports
HTTP/2 and use it.

- HTTP/2 improves performance.

- Recommended by Mozilla's SSL configurator: https://ssl-config.mozilla.org/.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
Sunil Mohan Adapa 2021-09-01 17:16:38 -07:00 committed by James Valleroy
parent e8c4e732ea
commit 857ab0afe1
No known key found for this signature in database
GPG Key ID: 77C0C75E7B650808
2 changed files with 4 additions and 1 deletions

View File

@ -126,6 +126,9 @@ def subcommand_setup(arguments):
# Disable /server-status page to avoid leaking private info.
webserver.disable('status', kind='module')
# Enable HTTP/2 protocol
webserver.enable('http2', kind='module')
# switch to mod_ssl from mod_gnutls
webserver.disable('gnutls', kind='module')
webserver.enable('ssl', kind='module')

View File

@ -14,7 +14,7 @@ from plinth.modules.firewall.components import Firewall
from plinth.modules.letsencrypt.components import LetsEncrypt
from plinth.utils import format_lazy, is_valid_user_name
version = 8
version = 9
is_essential = True