Commit Graph

11 Commits

Author SHA1 Message Date
Pol Henarejos
5e377cccaf Added AES encryption/decryption.
However, I could not find any interface (neither opensc nor sc-hsm-embedded).
Needs further testing.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-03-06 01:28:29 +01:00
Pol Henarejos
78bad89415 Private and secret keys are now stored encrypted with DKEK.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-03-04 23:00:59 +01:00
Pol Henarejos
ff06414247 Adding signature computation (unfinished)
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-28 09:43:09 +01:00
Pol Henarejos
4cdb2f93e5 Fix reset pin.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-24 20:37:50 +01:00
Pol Henarejos
16bd415fb9 Adding sanity checks.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-22 18:26:02 +01:00
Pol Henarejos
0ef2ee40ac Adding update_ef command.
Flash is reset when initialize

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-21 16:06:09 +01:00
Pol Henarejos
fe429bf5af Adding signature to public file.
Storing private key in disk.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-21 00:27:53 +01:00
Pol Henarejos
e59c0d08c4 Adding initialization.
- PINs are never stored, neither in flash nor in RAM.
- PINs are stored in flash in doubled salted way.
- PINs are stored in RAM in single salted way.
- SOPIN in RAM (single salted) is used to encrypt/decrypt DKEK.
- PINs in RAM (single salted) are used to encrypt/decrypt private keys related with user/so pins.
- DKEK is only used to export/import data.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-18 13:28:41 +01:00
Pol Henarejos
c8325babb2 Fixed pin reset
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-14 00:29:04 +01:00
Pol Henarejos
86cef892ff Adding PIN reset counter.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-13 18:27:49 +01:00
Pol Henarejos
0017284103 Starting migration from gnuk to own solution.
gnuk/openpgp will be left as another pkcs15 app.
Lots of work has been done in the meanwhile.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
2022-02-13 01:17:14 +01:00