-
Notifications
You must be signed in to change notification settings - Fork 30
RDM-4369: Support reserved characters in userId email address #420
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
Ensure `GET` request to `/user-profile/users` endpoint uses a fully encoded URL, to allow reserved characters in the `uid` query parameter.
Switch to using `DefaultUriBuilderFactory` in Spring Boot 2 to encode the request URL, to fix a problem with "double encoding" of query parameters (see spring-projects/spring-framework#20750 (comment)).
Codecov Report
@@ Coverage Diff @@
## master #420 +/- ##
==========================================
+ Coverage 95.28% 95.35% +0.07%
==========================================
Files 295 295
Lines 6676 6672 -4
Branches 389 387 -2
==========================================
+ Hits 6361 6362 +1
+ Misses 315 310 -5
Continue to review full report at Codecov.
|
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.
A comment
src/main/java/uk/gov/hmcts/ccd/data/user/DefaultUserRepository.java
Outdated
Show resolved
Hide resolved
…tring parameter Avoid setting the encoding mode on `restTemplate` because this is an autowired singleton bean, shared across the application. A future ticket will address encoding query string parameters for *all* requests, using `restTemplate`.
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.
👍
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.
👍
Codecov Report
@@ Coverage Diff @@
## master #420 +/- ##
==========================================
+ Coverage 95.28% 95.35% +0.07%
==========================================
Files 295 295
Lines 6676 6681 +5
Branches 389 389
==========================================
+ Hits 6361 6371 +10
+ Misses 315 310 -5
Continue to review full report at Codecov.
|
* master: RDM-4542: Use lowercase email for User Profile retrieval (#452) FR-901 Revert "RDM-3325: White space validation rules applied on text fields (#284)" (#459) RDM-4610: CVE-2019-0232 fix (#458) increased default callback timeout from 15sec to 60 sec Rdm 3897- Retrieve all the case data (#376) RDM-3325: White space validation rules applied on text fields (#284) RDM-4369: Support reserved characters in userId email address (#420) Add externalId index for CMC (#418) Fix OWASP issue (#456) SIDAM Switch
JIRA link (if applicable)
https://tools.hmcts.net/jira/browse/RDM-4369.
Change description
Ensure
GET
request to/user-profile/users
endpoint uses a fully encoded URL, to allow reserved characters in theuid
query parameter.Does this PR introduce a breaking change? (check one with "x")
Note: PR hmcts/ccd-user-profile-api#173 must be merged to
master
before this change; User Profile API needs to be able to decode the encoded email address passed in theuid
query parameter, as a result of this PR.