* Reworks some workflows to run a script instead
Advantages are:
- Only one set of tests needs maintenance.
- Local results match workflows, no surprises.
- Reduced reliance on GitHub actions.
Fixes#50, #168, #169, #171, #507
* Adds macos to the test matrix
* New key wrapping API
Allows key wrapping to be different between persistent and server-side
storage.
To accomplish this, the PrivateKey now always stores the fully
reconstructed key, and has different methods to serialize it for the
respective use case.
* Cleans up legacy credential parsing
This is a backwards incompatible change. This PR already introduces
backwards incompatible new credential parsing, and therefore we can also
remove all other legacy parsing.
* Correct credential minimum size
* wider public interface to allow custom PrivateKey construction
We accidentally lost this check in #516. I refactored some of the
filters for better style.
The actual difference in logic is just one line in CTAP1 authenticate,
everything else is style, a test and the order in which we convert and
filter the credentials:
```
let credential_source = filter_listed_credential(credential_source, false)
.ok_or(Ctap1StatusCode::SW_WRONG_DATA)?;
```
* Adds a compile flag for AuthenticatorConfig
The command can be disabled for authenticators that don't want users to
change their configuration.
* adds tool for calling Config
* std now implies config_command
* removes obsolete comment
This move changes the Env trait: It removes all functionality that is
used only in vendor commands (`FirmwareProtection`, `UpgradeStorage`)
and adds a function to call when parsing CBOR commands.
The abstraction necessary to test these commands is instead realized
through compile flags. The mock upgrade storage is active when compiled
for std for example.
* Replaces the Rng256 with RngCore from rand_core
The old trait was designed with our software crypto in mind. We should
use a more standard API going forward.
- Removes libraries/rng256/
- Ports libraries/crypto/ to rand_core
- Moves the used RNG trait to api/
* Use StdRng directy in TestEnv
* Removes redundant entries from Cargo.toml
This also fixes a compilation problem we have in debug mode with LTO
enabled.
* fix output-path triple dash
* Add crate arbitrary as ctap's optional dependency, when feature "fuzz"
is activated.
* Derive Arbitrary for all the necessary types in order to generate the
concrete types from random bytes.
* Add a fuzz target that transforms the input to valid format for
MakeCredential.