-
You must be signed in to change notification settings -
[#IOCIT-118] make prevalidate errors more readable #119
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
Conversation
0be029a
to
76ca1f1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Implementation looks fine to me. I'd be more explicit about:
- the kind of data we are loggi 10000 ng to help privacy team to audit our code
- the queries we expect to do on logs once we have such data - and the ones we don't want to be able to do
Both can be achieved by commenting out the code imho
src/utils/saml.ts
Outdated
@@ -81,72 +134,70 @@ export const getPreValidateResponse = ( | |||
"Response" | |||
); | |||
|
|||
const maybeIdpIssuer = getSamlIssuer(doc); | |||
|
|||
const hasStrictValidation = pipe( | |||
O.fromNullable(strictValidationOptions), | |||
O.chain(_ => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please give _
a meaningful name, or @michaeldisaro gets mad
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you think about validationOptions
for that parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sure that it was @BurnedMarshal fault that _
. 🤣
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arcogabbo that's a good name! And _[issuer]
becomes validationOptions[issuer]
that's a lot more readable and meaningful!
src/utils/saml.ts
Outdated
@@ -81,72 +134,70 @@ export const getPreValidateResponse = ( | |||
"Response" | |||
); | |||
|
|||
const maybeIdpIssuer = getSamlIssuer(doc); | |||
|
|||
const hasStrictValidation = pipe( | |||
O.fromNullable(strictValidationOptions), | |||
O.chain(_ => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sure that it was @BurnedMarshal fault that _
. 🤣
src/utils/saml.ts
Outdated
@@ -81,72 +134,70 @@ export const getPreValidateResponse = ( | |||
"Response" | |||
); | |||
|
|||
const maybeIdpIssuer = getSamlIssuer(doc); | |||
|
|||
const hasStrictValidation = pipe( | |||
O.fromNullable(strictValidationOptions), | |||
O.chain(_ => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arcogabbo that's a good name! And _[issuer]
becomes validationOptions[issuer]
that's a lot more readable and meaningful!
Kudos, SonarCloud Quality Gate passed!
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This suggestion can be applied if needed to the next PR
List of Changes
requestId
andidpIssuer
fieldsMotivation and Context
when debugging a login issue, it can be useful to have more data to better understand the problem
How Has This Been Tested?
build and test passed
Screenshots (if appropriate):
Types of changes
Checklist: