Skip to content

Conversation

ch4r10t33r
Copy link

No description provided.

Comment on lines +26 to +34
1. **Key Derivation Function (KDF)**
- Replaces PBKDF2 with more secure, memory-hard alternatives:
- `argon2id` (preferred)

2. **Authenticated Encryption**
- Encryption must use an AEAD (Authenticated Encryption with Associated Data) scheme:
- `aes-256-gcm`
- or `xchacha20-poly1305`
- MAC (message authentication code) is integrated into the encryption tag, eliminating the need for a separate field
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gballet you have any opinions here?

@RazorClient
Copy link

hey
tamaghna from zeam here
do we know how much the private keys sizes are

here are some ballpark no (there are with the sha hash fn)

  • (SHA3-256, $L=2^{18}$):**

  • $w=4,: ≈ 560 MiB

  • $w=2, : ≈ 1.15 GiB

so the idea would be to store the prf keys and generate the epoch based keys when required
PRF seed (32 B) + $P$ (≈32 B) → ≈ 64 B persistent secret

What have you guys implemented/thought about this ??

Comment on lines +39 to +40
4. **Post-Quantum Declaration**
- Introduces a `quantum_secure: true` flag to explicitly indicate use of post-quantum
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this flag is needed, as the version and primitives we use are enough.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea was to have an explicit flag in the keystore file to indicate that it is quantum_secure. Otherwise, we ought to assume that version above above > 4 is considered quantum secure.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would emphasize that quantum_secure flag doesn't guarantee anything. If one JSON file uses EIP-2335 format but only adding quantum_secure: true, is this "quantum-safe"? Or what if the file satisfies all the requirements but making quantum_secure: false?

IMHO a specification should be clear enough so that implementers shouldn't worry about those edge cases.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would emphasize that quantum_secure flag doesn't guarantee anything. If one JSON file uses EIP-2335 format but only adding quantum_secure: true, is this "quantum-safe"? Or what if the file satisfies all the requirements but making quantum_secure: false?

Ofcourse. You are absolutely correct. Just because we have a flag, it doesn't mean the keystore adheres to the format. I am happy revise the spec to indicate that version=5 means it is quantum_secure.

Comment on lines +67 to +75
{
"properties": {
"memory": { "type": "integer" },
"iterations": { "type": "integer" },
"parallelism": { "type": "integer" },
"salt": { "type": "string", "pattern": "^[a-fA-F0-9]+$" }
},
"required": ["memory", "iterations", "parallelism", "salt"]
},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the benefit for providing this "Full" option? This requires few more bytes without any additional functionality. If the spec is clear enough and well-descriptive, using short option seems fine (and also consistent with existing keystore formats like Web3 secret storage definition and EIP-2335)

The keystore format MUST conform to the following schema:

```json
{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this schema valid? It seems it's different with the examples below.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants