Skip to content
#

software

Here are 1,749 public repositories matching this topic...

jku
jku commented Aug 20, 2021

tuf/ngclient/updater.py: Updater._persist_metadata():

    with open(os.path.join(self._dir, f"{rolename}.json"), "wb") as f:
        f.write(data)

this is not as safe as it should be (as file could be corrupted midway through). This should work:

  • write content to tempfile
  • use sslib_util.persist_temp_file() to move tempfile to correct filepath

Improve this page

Add a description, image, and links to the software topic page so that developers can more easily learn about it.

Curate this topic

Add this topic to your repo

To associate your repository with the software topic, visit your repo's landing page and select "manage topics."

Learn more