Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(pii): Fix roundtrip error when PII selector starts with number #982

Merged
merged 6 commits into from
Apr 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@

- Support the `frame.stack_start` field for chained async stack traces in Cocoa SDK v7. ([#981](https://github.com/getsentry/relay/pull/981))

**Bug Fixes**:

- Fix roundtrip error when PII selector starts with number. ([#982](https://github.com/getsentry/relay/pull/982))

**Internal**:

- Update internal representation of distribution metrics. ([#979](https://github.com/getsentry/relay/pull/979))
Expand Down
1 change: 1 addition & 0 deletions py/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

- Add back `breadcrumb.event_id`. ([#977](https://github.com/getsentry/relay/pull/977))
- Add `frame.stack_start` for chained async stack traces. ([#981](https://github.com/getsentry/relay/pull/981))
- Fix roundtrip error when PII selector starts with number. ([#982](https://github.com/getsentry/relay/pull/982))

## 0.8.5

Expand Down
5 changes: 4 additions & 1 deletion relay-general/src/pii/convert.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1354,7 +1354,10 @@ THd+9FBxiHLGXNKhG/FRSyREXEt+NyYIf/0cyByc9tNksat794ddUqnLOg0vwSkv

let pii_config = to_pii_config(&DataScrubbingConfig {
sensitive_fields: vec!["special ,./<>?!@#$%^&*())'gärbage'".to_owned()],
exclude_fields: vec!["do not ,./<>?!@#$%^&*())'ßtrip'".to_owned()],
exclude_fields: vec![
"do not ,./<>?!@#$%^&*())'ßtrip'".to_owned(),
"2abc".to_owned(),
],
..simple_enabled_config()
});

Expand Down
2 changes: 1 addition & 1 deletion relay-general/src/processor/selector.pest
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Or = _{ "||" | "|" }
Not = _{ "~" | "!" }
EscapedQuote = @{ "'" }

UnquotedKey = @{ (ASCII_ALPHANUMERIC | "-" | "_") + }
UnquotedKey = @{ (ASCII_ALPHA | "_") ~ (ASCII_ALPHANUMERIC | "-" | "_") * }
RootUnquotedKey = { SOI ~ UnquotedKey ~ EOI }
QuotedCharacter = @{ ((!"'") ~ ANY) }
QuotedKey = ${ (QuotedCharacter | ("'" ~ EscapedQuote))+ }
Expand Down