Open nigtrifork opened 2 years ago
@tadgh - any chance you will have a look at this?
If I'm being honest I didn't even know you could do that search by absolute patient reference. Since this looks like a regression I'd be happy to fix it if we can find out what regressed it.
If you can get a failing unit test I'd be happy to git bisect the repository to find out what caused the change and why. Sadly I don't have the time to dedicate to writing one myself at the moment.
Describe the bug Given a Patient resource
https://my-server/fhir/Patient/1234
and compartmentPatient/1234
When I search for RelatedPersonGET https://my-server/fhir/RelatedPerson?patient=https://my-server/fhir/Patient/1234
Then the server responds with403 Unauthorized
(Note: URL encoding is omitted for readability)
However, When I search for RelatedPerson
GET https://my-server/fhir/RelatedPerson?patient=Patient/1234
Then the server responds with all RelatedPersons withpatient=https://my-server/fhir/Patient/1234
To Reproduce Steps to reproduce the behavior:
SearchNarrowingInterceptor.java
and add compartmentreturn new AuthorizedList().addCompartment("...")
Expected behavior
GET https://my-server/fhir/RelatedPerson?patient=https://my-server/fhir/Patient/1234
andGET https://my-server/fhir/RelatedPerson?patient=Patient/1234
should be equivalent,Environment (please complete the following information):
Additional context Worked in 5.5.3