Skip to content

Commit

Permalink
Merge pull request #43 from CSCfi/fix/crypt4gh-header-check-for-large…
Browse files Browse the repository at this point in the history
…-files

fix bug on header check for large files
  • Loading branch information
teemukataja authored Dec 8, 2023
2 parents 372d954 + fcc7c6c commit 6546461
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sda_uploader/encrypt.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def verify_crypt4gh_header(file: Union[str, Path] = "") -> bool:
"""Verify, that a file has Crypt4GH header."""
print("Verifying file Crypt4GH header.")
with open(file, "rb") as f:
header = f.read()[:8]
header = f.read(8)
if header == b"crypt4gh":
return True
else:
Expand Down

0 comments on commit 6546461

Please sign in to comment.