cpupower: Replace HTTP links with HTTPS ones
authorAlexander A. Klimov <grandmaster@al2klimov.de>
Mon, 13 Jul 2020 11:05:11 +0000 (13:05 +0200)
committerShuah Khan <skhan@linuxfoundation.org>
Fri, 17 Jul 2020 17:58:04 +0000 (11:58 -0600)
commitfa0866a1d1be8ffa6979bf2127272b7e3d511fcd
tree1157fd9d1d21c3f90ae1e95b46a08dad823aef49
parentcbf25270933742c4a6d8671bba5c79a4e879cff3
cpupower: Replace HTTP links with HTTPS ones

Rationale:
Reduces attack surface on kernel devs opening the links for MITM
as HTTPS traffic is much harder to manipulate.

Deterministic algorithm:
For each file:
  If not .svg:
    For each line:
      If doesn't contain `\bxmlns\b`:
        For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:
  If neither `\bgnu\.org/license`, nor `\bmozilla\.org/MPL\b`:
            If both the HTTP and HTTPS versions
            return 200 OK and serve the same content:
              Replace HTTP with HTTPS.

Signed-off-by: Alexander A. Klimov <grandmaster@al2klimov.de>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/power/cpupower/man/cpupower-monitor.1