aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-hscrypto/src/macros.rs
Commit message (Collapse)AuthorAgeFilesLines
* tor-hscrypto: fix typostcyrus2025-07-231-1/+1
|
* hscrypto: Downgrade a TODO HSS comment.Nick Mathewson2024-01-141-1/+1
| | | | | This is not a blocker; it's just a code movement or duplication issue IIUC.
* Convert to the latest versions of dalek-cryptographyNick Mathewson2023-11-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The main changes that we have to adjust for are as follows: * In x25519-dalek: * `StaticSecret` is now behind a feature. * `StaticSecret::new` is deprecated in favor of `StaticSecret::random_from_rng`. * StaticSecret no longer does its own clamping. * In ed25519-dalek: * `SecretKey` has (in effect) been renamed to `SigningKey`. The name `SecretKey` is now an alias for `[u8; 32]`. * `SigningKey` is effectively a keypair, since it contains a public key as well. * `PublicKey` has been renamed to `VerifyingKey`. * The functions to extract a signing key and verifying key have been renamed as you might expect. * `ExpandedSecretKey` has been moved to `hasmat` and no longer implements `sign`. * `ExpanededSecretKey` now has as its elements a scalar and a hash prefix. * Various functions that took `&[u8]` now take `&[u8; N]`. * We no longer need a wrapper for older versions of rand. There is a single test in tor-keymgr that does not pass. I've marked it as ignore for now, in hopes that @gabi-250 can help me figure it out. This closes #808. There are several changes I want to make before we merge, however. They are marked with TODO DALEK.
* tor-hscrypto: Add a TODO re re-implementation of x25519 keypair genIan Jackson2023-11-231-0/+5
| | | | | | IMO it is quite undesirable to have multiple copies of "gen a secret key and make a keypair out of it". Add a TODO HSS and and a ref to arti#1137 which is related.
* tor-hscrypto: Add a docs TODO re the define_pk_keypair macroIan Jackson2023-11-231-0/+3
|
* tor-hscrypto: Define Keypair conversions for all curve25519 newtypesIan Jackson2023-11-231-0/+16
| | | | | | | | | 1. Move `impl From<SpecificKeypair> for curve25519::StaticKeypair` (which was just a bespoke impl for HsClientDescEncKeypair) into the define_pk_keypair macro, so everything has it. Currently the only other user of the curve25519_pair feature is HsSvcNtorKey. 2. Provide the reverse conversion too.
* tor-hsservice: Add HsClientDescEncKeypair.Gabriela Moldovan2023-09-251-0/+4
|
* hs_ntor: Take our k_hss_ntor keypair explicitly.Nick Mathewson2023-09-201-0/+5
|
* tor-crypto: Fix some derive formattingIan Jackson2023-09-181-1/+1
| | | | This was missing the conventional spaces. Noticed in passing.
* hscrypto: Define a keypair type for HsSvcNtor{,Secret}KeyNick Mathewson2023-09-171-0/+34
| | | | | (Also, extend our macro so that we can wrap other curve25519 keys in this way, if we want.)
* hscrypto: Make several types Readable+WriteableNick Mathewson2023-02-281-0/+11
| | | | Specifically, RendCookie, Subcredential, HsId, and HsBlindId.
* hscrypto: Use derive_more, and derive Deref for public keys.Nick Mathewson2023-01-251-32/+2
|
* Add a note about why we use ExpandedSecretKey for OnionIdSecretKeyNick Mathewson2023-01-241-1/+2
|
* hscrypto: use a macro to define our byte wrappers too.Nick Mathewson2023-01-241-1/+34
|
* hscrypto: Add and use a macro to define all PK types.Nick Mathewson2023-01-241-0/+61