summaryrefslogtreecommitdiff
path: root/crates/tor-llcrypto/src
Commit message (Collapse)AuthorAgeFilesLines
* clippy: deny `mod_module_files`Steven Engler2025-01-061-0/+1
| | | | | | Denies 'mod.rs' files for consistency. https://rust-lang.github.io/rust-clippy/master/index.html#mod_module_files
* add_warnings, *: Allow clippy::needless_lifetimesNick Mathewson2024-12-031-0/+1
| | | | | | | | In 1.83, this warning triggers on many of our crates. We're thinking of fixing them all, but for now, we're going to disable the warning. This is part of #1765.
* Rename "memquota" feature to "memquota-memcost" when it's just HasMemoryCost ↵Ian Jackson2024-10-163-4/+20
| | | | (fmt)
* Rename "memquota" feature to "memquota-memcost" when it's just HasMemoryCostIan Jackson2024-10-163-9/+9
| | | | It's not documented anywhere ATM. I will do that in a followup MR.
* Some HasMemoryCost impls in tor-llcryptoIan Jackson2024-10-023-0/+15
|
* tor-llcrypto: replace simple_asn1 dependency with der_parserMorgan2024-09-282-37/+31
|
* tor_hsservice: add `impl From<&FooPublicKeySpecifier> for ↵Adam Joseph F0B74D717CDE8412A3E0D4D5F29AC8080DA8E1E02024-09-091-0/+6
| | | | | | | | | | | | | FooKeypairSpecifier` instances This adds the following trivial `From` instances: - tor_hsservice: impl From<&HsIdPublicKeySpecifier> for HsIdKeypairSpecifier - tor_hsservice: impl From<&BlindIdPublicKeySpecifier> for BlindIdKeypairSpecifier - tor_hscrypto::pk: impl From<HsBlindIdKeypair> for HsBlindIdKey - tor_llcrypto::pk::ed25519: impl From<ExpandedKeypair> for PublicKey - tor_keymgr::mgr: impl From<TestKey> for TestPublicKey - tor::hscrypto::pk: impl From<HsIdKeypair> for HsIdKey
* keymanip: Make blind_pubkey exist unconditionallyNick Mathewson2024-08-211-4/+4
| | | | | | | | | Now it exists unconditionally so that we can have our assertion for public key consistency happen unconditionally. (Blinding secret keys is not remotely in the critical path, so I'm not concerned about the critical path.) From a suggestion from Gabi on !2341.
* keymanip: Use doc(cfg(...)) in place of "Availability" sectionsNick Mathewson2024-08-211-8/+2
|
* llcrypto: Make `blind_keypair` build without hsv3-client.Nick Mathewson2024-08-211-2/+2
| | | | | | | | | | The `blind_keypair` function should only call `blind_pubkey` when it is present. Also, fix the documentation: blind_keypair is a hsv3-service function, not a hsv3-client function. Closes #1504.
* Re-run maint/add_warning.Nick Mathewson2024-05-061-2/+2
| | | | This commit is automatically generated.
* Run maint/add_warning.Nick Mathewson2024-03-133-0/+3
|
* deny clippy::unchecked_duration_subtractiontrinity-1686a2024-02-291-0/+1
|
* clippy: consequential rustfmtIan Jackson2024-01-021-4/+1
|
* clippy: Use infallible callsIan Jackson2024-01-021-2/+1
| | | | Resolves clippy complaints about needless fallible conversions.
* clippy: Replace many calls to .get(0) with .first()Ian Jackson2024-01-021-4/+4
| | | | | FTR I don't think agree with clippy on this question, but then I often don't.
* llcrypto: make "traits" module present unconditionally.Nick Mathewson2023-12-121-1/+0
| | | | Removes a TODO HSS, since this trait is generally useful.
* Merge branch 'msrv-followup' into 'main'Nick Mathewson2023-12-041-2/+1
|\ | | | | | | | | Followups from MSRV 1.70 upgrade See merge request tpo/core/arti!1785
| * llcrypto: Use up-to-date name for a clippy lint.Nick Mathewson2023-11-301-2/+1
| |
* | Remove semver.md files.Nick Mathewson2023-12-041-3/+0
|/
* Fix a rustdoc error.Nick Mathewson2023-11-291-1/+1
|
* Resolve an unfinished sentenceNick Mathewson2023-11-291-1/+2
|
* grammar fix in commentgabi-2502023-11-291-1/+1
|
* llcrypto: remove a comment suggesting a grand renaming.Nick Mathewson2023-11-291-3/+3
|
* llcrypto: Hide the members of ExpandedKeypair.Nick Mathewson2023-11-291-5/+15
| | | | | With this change, we no longer expose the ExpandedSecretKey unescorted, which makes it harder to misuse the API.
* llcrypto: Undo internal ed25519-dalek renamings in keymanip.rsNick Mathewson2023-11-291-8/+7
|
* llcrypto: Remove redundant re-exports in keymanip.Nick Mathewson2023-11-291-10/+3
| | | | (These types were all already re-exported from pk::ed25519.)
* llcrypto: Remove ExpandedSecretKey export.Nick Mathewson2023-11-292-6/+3
| | | | | | | This type was part of `hazmat`, and was no longer necessary anywhere in our codebase. (It had one remaining user, which was easy enough to remove.) By removing it, we remove the opportunity for using an unescorted ed25519 private key.
* Fix a typo in comment in llcrypto.Nick Mathewson2023-11-291-1/+1
|
* Clarify and downgrade TODO about ReusableSecret.Nick Mathewson2023-11-291-1/+8
|
* Deprecate convert_ed25519_to_curve25519_private as unusedNick Mathewson2023-11-291-0/+5
|
* Remove RngCompatExt.Nick Mathewson2023-11-293-255/+2
| | | | | | | | | | This code was needed with the old version of dalek-cryptography, which wasn't compatible with up-to-date versions of the `rand` crate(s). But now that we've upgraded, we can drop this. (We could have left it around and deprecated it, but we are already making a breaking change to tor-llcrypto by upgrading dalek-cryptography.)
* Convert to the latest versions of dalek-cryptographyNick Mathewson2023-11-294-136/+162
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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: derive the impl of Debug for curve25519::StaticKeypairIan Jackson2023-11-231-10/+4
|
* tor_llcrypto: expose `Shake256Reader`Jim Newsome2023-11-151-1/+1
|
* tor-llcrypto: Implement Clone and Debug for StaticKeypair.Gabriela Moldovan2023-09-251-0/+11
|
* tor-llcrypto: Add a type for x25519 StaticSecret/PublicKey keypairs.Gabriela Moldovan2023-09-251-0/+9
|
* Run maint/add_warning to add lint block everywhereIan Jackson2023-08-234-0/+4
|
* Resolve warnings about ambiguous/redundant doc linksNick Mathewson2023-08-221-2/+2
| | | | | Nightly rustdoc now warns if you have a link that isn't necessary, and if you have a link that might refer to two different things.
* llcrypto: New SimpleMac traitNick Mathewson2023-08-142-0/+19
| | | | | | | | | This will be useful in preference to the regular Mac trait for the places where we need to pass a Mac key around, but we don't need to support incremental operation. Part of arti#993, where we want to expose a MAC object without exposing sensitive data.
* Run add_warnings on all files.Nick Mathewson2023-08-041-2/+2
|
* tor-llcrypto: Add a missing instance of the standard lint blockIan Jackson2023-07-101-0/+10
| | | | This fixes a needless_vec lint on nightly.
* Run maint/add_warning to actually apply new lint allowsIan Jackson2023-07-104-0/+4
|
* Run add_warning to remove `missing_panics_doc` deny.Nick Mathewson2023-07-061-1/+0
| | | | Closes #950.
* llcrypto: Add reference to paper about keypair reuse.Gabriela Moldovan2023-06-271-0/+2
|
* llcrypto: Remove `# Availability` doc sections.Gabriela Moldovan2023-06-271-8/+0
| | | | | | | | | | This removes the `# Availability` section from the `convert_ed25519_to_curve25519_private` and `convert_curve25519_to_ed25519_private` docs. We don't generally have this sort of section anywhere else in the codebase (we use unstable cargo-docs features to make sure items are annotated correctly).
* llcrypto: Add cvt-x25519 feature flag for exporting key conversion functions.Gabriela Moldovan2023-06-272-4/+5
| | | | | | The `convert_curve25519_to_ed25519_private` and `convert_ed25519_to_curve25519_private` functions are now exported by `tor-llcrypto` if the `cvt-25519` feature is enabled.
* llcrypto: Add keymgr feature to semver.mdGabriela Moldovan2023-06-271-0/+1
|
* llcrypto: Add `Panics`, `Availability` docs for ↵Gabriela Moldovan2023-06-271-0/+12
| | | | convert_ed25519_to_curve25519_private.
* llcrypto: Fix clippy lint.Gabriela Moldovan2023-06-271-1/+1
|