rlee287 / pyautoupdate

An auto-update API for Python programs. ARCHIVED: The update mechanism here contains no guarantees about code integrity. You may want to look at TUF (The Update Framework) instead.
GNU Lesser General Public License v2.1
14 stars 2 forks source link

Secure update mechanism #26

Open rlee287 opened 7 years ago

rlee287 commented 7 years ago

Feature Request

Description of feature:

Rationale for feature:

  1. Without any kind of securing, a MITM attack could easily inject malicious code into an update.
  2. Duplicate files may cause problems and unpredictability. Moreover, symlink attacks could potentially be used to overwrite critical system files.

Possible implementation:

  1. requests can already handle HTTPS properly. This could be mandated. In addition, protocols such as SFTP or SSH could also be used.
  2. Duplicates can be checked for and removed during replacing process (emitting warnings as well)
rlee287 commented 7 years ago

Turning into general checklist for securing the update chain.

rlee287 commented 7 years ago

For point 1: