italia / eudi-wallet-it-python

Python toolchain for building an OpenID4VP RP with a SATOSA backend compliant with the Italian Wallet implementation profile
Apache License 2.0
17 stars 13 forks source link

Elliptic curve support #200

Closed salvatorelaiso closed 9 months ago

salvatorelaiso commented 9 months ago

This PR extends JWEHelper class capabilities to handle encryption and decryption with the use of EC Keys. The above functionalities are tested in the corresponding unit tests.

It also adds EC keys based integration test with new files while leaving the RSA integration test intact.

This PR provides a new JWK Schema as per TODO: https://github.com/italia/eudi-wallet-it-python/blob/78c00cba554bd789f70bb98e95c97a29c8fb5dae/pyeudiw/oauth2/dpop/schema.py#L20-L21 The usage of this dynamic schema handling by Pydantic is documented through a simple test added in the file test_jwk, named test_dynamic_schema_validation.

The old schemas are retained for compatibility purpose until migration to this newer schemas.

Closed #102