使用HTTPS时,我需要/希望使用gzip压缩吗?
问题描述:
使用HTTPS是否已经包含(透明)内容压缩,或者我还需要担心与浏览器协商是否压缩我的Servlet输出?如果HTTPS已经有压缩,是无条件还是需要配置/协商/启用?
Does using HTTPS already include (transparent) content compression or should I still worry about negotiating with the browser whether to compress my Servlet output? If HTTPS already has compression, is it unconditional or does it need to be configured/negotiated/enabled?
答
'启用压缩,虽然它(压缩)在TLS标准中定义,并且如果双方都支持它,可以启用。所以最好不要依赖它,并在HTTP级别请求它。
TLS by default doesn't enable compression, though it (compression) is defined in TLS standard and can be enabled if both parties support it. So it's better to not rely on it and request it on HTTP level.