From 57ffafaa248e66a999952b0a727a9072eb184855 Mon Sep 17 00:00:00 2001 From: kaczmarczyck <43844792+kaczmarczyck@users.noreply.github.com> Date: Fri, 10 Sep 2021 15:19:15 +0200 Subject: [PATCH] Update bugfix with changes from stable (#377) * Add Feitian OpenSK USB Dongle (#257) (#258) Co-authored-by: superskybird Co-authored-by: Geoffrey Co-authored-by: superskybird * Bugfix (#304) * Add Feitian OpenSK USB Dongle (#257) Co-authored-by: superskybird * Fix `config.py` tool according to the new API of fido2 python package (#284) * Fix fido2 API update. Since fido2 0.8.1 the device descriptor moved to NamedTuple, breaking our configuration tool. Code is now updated accordingly and the setup script ensure we're using the correct version for fido2 package. * Make Yapf happy * Fix missing update for fido2 0.9.1 Also split the comment into 2 lines so that the touch is not hidden at the end of the screen. * adds README changes, logo and certificate (#285) Co-authored-by: Geoffrey Co-authored-by: superskybird Co-authored-by: kaczmarczyck <43844792+kaczmarczyck@users.noreply.github.com> * Compare all timestamps in UTC timezone. (#309) * Merge bugfix into stable (#324) * Add Feitian OpenSK USB Dongle (#257) Co-authored-by: superskybird * Fix `config.py` tool according to the new API of fido2 python package (#284) * Fix fido2 API update. Since fido2 0.8.1 the device descriptor moved to NamedTuple, breaking our configuration tool. Code is now updated accordingly and the setup script ensure we're using the correct version for fido2 package. * Make Yapf happy * Fix missing update for fido2 0.9.1 Also split the comment into 2 lines so that the touch is not hidden at the end of the screen. * adds README changes, logo and certificate (#285) * Fix broken parsing. (#317) * Fix broken parsing. By setting the default value before pre-parsing we ensure that the item can't be None. As an extra safety the custom action also checks for None. Co-authored-by: Geoffrey Co-authored-by: superskybird Co-authored-by: kaczmarczyck <43844792+kaczmarczyck@users.noreply.github.com> * Coveralls workflow applied also to stable (#342) * Coveralls (#339) * Add code coverage report as part of the workflows * Remove -Clink-dead-code which seems to be problematic * Manually set features to avoid debug_* failing unit tests. * Update badges * Add libraries directory to trigger code coverage reporting. * Fix coveralls badge not pointing to the branch * Badges to stable branch * adds and links new security policy * Add erase_storage application example (#352) * Fix coveralls workflow (#356) * Return error instead of debug assert (#363) With dirty storage we hit the assert. Returning an error permits to continue to catch if the invariant is broken for normal operation while being able to continue fuzzing with dirty storage. * Remove elf2tab dev-dependency (#366) We don't use it anymore. Not sure when we used to use it. Fixes #364 Co-authored-by: kaczmarczyck <43844792+kaczmarczyck@users.noreply.github.com> * Install Rust tools with stable compiler We only need the frozen nightly for Tock (and maybe the app). * fix python lint with encoding, see commit 7418196 * more encoding Co-authored-by: Jean-Michel Picod Co-authored-by: Geoffrey Co-authored-by: superskybird Co-authored-by: Julien Cretin --- deploy.py | 2 +- fuzz/make_corpus.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/deploy.py b/deploy.py index b51c111..8fbb05b 100755 --- a/deploy.py +++ b/deploy.py @@ -308,7 +308,7 @@ class OpenSKInstaller: def update_rustc_if_needed(self): target_toolchain_fullstring = "stable" - with open("rust-toolchain", "r") as f: + with open("rust-toolchain", "r", encoding="utf-8") as f: target_toolchain_fullstring = f.readline().strip() target_toolchain = target_toolchain_fullstring.split("-", maxsplit=1) if len(target_toolchain) == 1: diff --git a/fuzz/make_corpus.py b/fuzz/make_corpus.py index 11c8575..a6bd9ff 100644 --- a/fuzz/make_corpus.py +++ b/fuzz/make_corpus.py @@ -29,7 +29,7 @@ def make_corpus(corpus_dir, corpus_json): if os.path.isfile(corpus_json) and \ os.path.splitext(corpus_json)[-1] == ".json": - with open(corpus_json) as corpus_file: + with open(corpus_json, encoding="utf-8") as corpus_file: corpus = json.load(corpus_file) else: raise TypeError