Replace HTTP links with HTTPS ones: DMI/SMBIOS SUPPORT
authorAlexander A. Klimov <grandmaster@al2klimov.de>
Thu, 16 Jul 2020 09:46:24 +0000 (11:46 +0200)
committerJean Delvare <jdelvare@suse.de>
Thu, 16 Jul 2020 09:46:24 +0000 (11:46 +0200)
commita3d13a0a23ea20a83d7148279a0ab68cc9a5962c
treeed5bec37224be326a82d31b1e334c7c5dd2d725c
parent11ba468877bb23f28956a35e896356252d63c983
Replace HTTP links with HTTPS ones: DMI/SMBIOS SUPPORT

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: Jean Delvare <jdelvare@suse.de>
drivers/firmware/dmi_scan.c