dennisvang / tufup-example

Example of a self-updating application using tufup.
MIT License
13 stars 8 forks source link

tuf.api.exceptions.DownloadLengthMismatchError: Downloaded x bytes exceeding the maximum allowed length of y #15

Closed dennisvang closed 6 months ago

dennisvang commented 1 year ago
tuf.api.exceptions.DownloadLengthMismatchError: 
Downloaded 21755631 bytes exceeding the maximum allowed length of 21755616

how can we fix this issue? pls help

Originally posted by @mdhuzaifapatel in https://github.com/dennisvang/tufup-example/issues/3#issuecomment-1728942285

dennisvang commented 1 year ago

@mdhuzaifapatel Typically this happens if your file has been modified, somewhere along the line, after adding it to your tuf repository.

It is difficult to help you without more detailed information, as there are many possible causes. It could be due to your own actions, or perhaps your server configuration is causing the issue.

For example, if your server is serving the .tar.gz files with a Content-Encoding: gzip header, the files will be decoded automatically upon download, which is not what you want.

Another possibility is that you are working with stale metadata. During the testing phase, it often helps to start with a clean slate.