summaryrefslogtreecommitdiff
path: root/crates/safelog
Commit message (Collapse)AuthorAgeFilesLines
* Bump patchlevel on crates with non-breaking changesNick Mathewson2023-03-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For these crates, the changes are nontrivial, so we _do_ bump the versions on which their dependent crates depend. Fortunately, since they are all pre-1.0, we don't need to distinguish semver-additions from other changes. (Except for arti, which _is_ post-1.0, but gets a patchlevel bump anyway.) These are unstable crates with breaking changes: ``` tor-hscrypto tor-hsclient ``` These have new or extended APIs: ``` safelog tor-bytes tor-cell tor-linkspec tor-llcrypto tor-proto tor-cert arti-client ``` These have new unstable APIs or features: ``` tor-netdoc tor-circmgr (also broke some unstable APIs) arti (is post-1.0) ``` These have bugfixes only: ``` caret tor-dirmgr ```
* arti-client: Include redacted HsId in ObtainHsCircuit errorIan Jackson2023-03-231-1/+1
| | | | | As per https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1071/diffs?commit_id=580fe1118dbbbfa086d11b28e3e26d7c91afe21c#fbd7ab2d6d0a5b515697d4f9f99a42ebd508aa4b_153_165
* safelog: impl From<T> for Redacted<T>Ian Jackson2023-03-232-0/+2
| | | | I think this is uncontroversial; we already have it for Sensitive.
* Remove semver.md files now that 1.1.1 is tagged.Nick Mathewson2023-02-011-2/+0
|
* Bump the patch version of every crate that had API additionsNick Mathewson2023-02-011-1/+1
| | | | | | These crates had API or behavior changes that may affect downstream crates. Fortunately, they're all version 0.x, and don't need minor bumps for this.
* Allow clippy::unchecked_duration_subtraction in testsNick Mathewson2023-01-273-0/+3
| | | | | This panics on error, and we're fine with a panic on misbehavior in tests.
* Disable clippy::unlinlined-format-argsNick Mathewson2023-01-271-0/+1
| | | | | | | | This warning kind of snuck up on us! (See #748) For now, let's disable it. (I've cleaned it up in a couple of examples, since those are meant to be more idiomatic and user-facing.) Closes #748.
* upgrade to latest serial_testNick Mathewson2023-01-201-1/+1
|
* Merge branch 'test-lints' into 'main'eta2023-01-063-0/+24
|\ | | | | | | | | Add test lint blocks to all "mod test" See merge request tpo/core/arti!937
| * test lint blocks: Add many many automaticallyIan Jackson2022-12-123-0/+24
| | | | | | | | | | This is precisely the result of running the rune in maint/adhoc-add-lint-blocks.
* | doc: consistent summary line for the READMEsEmil Engler2022-12-201-1/+1
| | | | | | | | | | This commit introduces a consistency to the summary line of all README.md files in each and every crate.
* | Rename Sensitive::into_inner() from ::unwrap()Ian Jackson2022-12-122-5/+21
|/ | | | | | | | | | By analogy with similar methods on Mutex, Cell, BufReader, etc. etc. Discussed here https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/890#note_2856885 Make it a method, as per https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/928
* safelog: tests for accessors.Nick Mathewson2022-12-061-0/+2
|
* safelog: tests for BoxSensitive.Nick Mathewson2022-12-061-0/+17
|
* safelog: more tests for Redacted.Nick Mathewson2022-12-062-3/+50
|
* Remove semver.md files now that 1.1.0 is released.Nick Mathewson2022-11-301-2/+0
|
* Bump the minor version of every crate.Nick Mathewson2022-11-301-1/+1
| | | | | We made this job easy this time around: by incrementing our MSRV, we have forced ourselves to do at least a minor bump everywhere.
* safelog: Apply #[serial] to test_redacted()Nick Mathewson2022-11-301-0/+1
| | | | Closes #675.
* Fix a logic error in Redacted.Nick Mathewson2022-11-301-4/+13
| | | | | | | Previously it was redacting exactly when safelogging was _disabled_, which obviously isn't correct. Fixes #671. Regression test included.
* safelog: Make MaybeRedacted<T> opaque.Nick Mathewson2022-11-282-22/+10
|
* Add a default debug_redacted impl to save space.Nick Mathewson2022-11-282-29/+3
|
* safelog: Add a MaybeRedacted wrapper too.Nick Mathewson2022-11-281-0/+38
| | | | | This is super helpful for cases where we want to write two nearly identical implementations to format a type.
* safelog: implement Redactable for network addr types.Nick Mathewson2022-11-282-0/+73
|
* safelog: Define a "Redactable" traitNick Mathewson2022-11-282-0/+93
| | | | | | A "redactable" object is one that can be _partially_ scrubbed in sensitive contexts. This can be very helpful for UX, but is not risk-free: see comments.
* safelog: Provide BoxSensitiveIan Jackson2022-11-231-0/+47
|
* safelog: Remove type argument from `impl_display_traits`Ian Jackson2022-11-231-3/+3
| | | | | | We're going to have this same macro implement the same traits for a second type. And its function is specific to `Sensitive`, so have it know that.
* safelog: Provide some more accessorsIan Jackson2022-11-231-0/+15
| | | | | We're about to use `.as_inner()` in a few places, and `.as_ref()` (by analogy with `Option`) seems obviously necessary.
* bump rust-version to 1.60 in every crate.Nick Mathewson2022-11-101-1/+1
|
* Run add_warnings.Nick Mathewson2022-11-031-0/+1
|
* cargo fmt to remove blank linesIan Jackson2022-10-121-1/+0
| | | | | | | Apparently cargo fmt doesn't like these, which my perl rune didn't delete. This commit is precisely the result of `cargo fmt`.
* Replace all README copies in src/lib.rs with includesIan Jackson2022-10-121-69/+1
| | | | | | | | The feature we want is `#[doc = include_str!("README.md")]`, which is stable since 1.54 and our MSRV is now 1.56. This commit is precisely the result of the following Perl rune: perl -i~ -0777 -pe 's{(^//!(?!.*\@\@).*\n)+}{#![doc = include_str!("../README.md")]\n}m' crates/*/src/lib.rs
* README doctests: fix safelogIan Jackson2022-10-121-0/+3
| | | | Add some dummy definitions that support the example.
* Update patch-versions on crates without API changes.Nick Mathewson2022-09-011-1/+1
| | | | | | | Since our last round of releases, these crates have had either trivial changes, or changes that did not affect their APIs. Therefore we are bumping their versions, but not changing which versions of them other crates depend on.
* Upgrade serial_test in preparation for release.Nick Mathewson2022-08-301-1/+1
|
* enable doc_auto_cfg feature on every crate when documenting for docs.rstrinity-1686a2022-08-242-0/+4
|
* Manually bump the patch version on safelog.Nick Mathewson2022-08-011-1/+1
| | | | | The changes on safelog do not affect its APIs or behavior, so there is no need to adjust any dependencies.
* Upgrade to latest phf, serde_with, serial_test.Nick Mathewson2022-07-191-1/+1
|
* Increment versions of crates with trivial changes only.Nick Mathewson2022-06-241-1/+1
| | | | | | "Trivial" here includes stuff like cargo reformatting, comment edits, error message string changes, and clippy warning changes. Crates that depend on these do not need to increment.
* Run maint/add_warning crates/*/src/{lib,main}.rsIan Jackson2022-06-231-0/+3
| | | | Update all lint blocks
* Style fixes to safelog errors.Nick Mathewson2022-06-221-3/+3
|
* Upgrade serial_test dev-dependency to 0.7.0Nick Mathewson2022-06-071-1/+1
|
* lints: Add let_unit_value allow to all cratesIan Jackson2022-05-311-0/+1
| | | | | From running add_warning, with manual picking of the right hunks/lines.
* lints: Add lint block delimiters to every crateIan Jackson2022-05-311-0/+2
| | | | | | This was the result of: maint/add_warning crates/*/src/{lib,main}.rs and then manually curating the results.
* Lexically sort Cargo.toml dependenciesOrhun Parmaksız2022-05-281-1/+1
| | | | | | Utilize cargo-sort: https://github.com/DevinR528/cargo-sort Signed-off-by: Orhun Parmaksız <[email protected]>
* Change safelog version to 0.1.0.Nick Mathewson2022-05-061-1/+1
| | | | | (This is okay because we haven't published it yet, or any crate that uses it.)
* Update README.md files (automated).Nick Mathewson2022-05-061-1/+70
|
* Punctuation fix.eta2022-05-061-1/+1
|
* Implement a safe-logging facility.Nick Mathewson2022-05-065-0/+656
This is a rough first-cut of an API that I think might help us with keeping limited categories of sensitive information out of our logs. I'll refine it based on experiences with using it.