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

Incorrect location for SCIM resource creation with realm enabled #825

Open
rdv-mpq opened this issue Dec 4, 2024 · 1 comment
Open

Incorrect location for SCIM resource creation with realm enabled #825

rdv-mpq opened this issue Dec 4, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@rdv-mpq
Copy link

rdv-mpq commented Dec 4, 2024

Hello,

When having Realms enabled for the SCIM server the returned location (both in the header and the response body) does not include the Realm id/name. As expected calling that endpoint results in a 404 as accessing resources without the Realm specified should not be possible. I'd expect the location to include the Realm that it was created in.

As an example, the creation of a user on the 01ab2cc4-16f2-4e00-8296-8cd829b4e430 Realm (POST https://localhost:7225/01ab2cc4-16f2-4e00-8296-8cd829b4e430/Users/) results in the following response:

{
	"id": "b6f44d27-04e6-46ab-adc4-8d1adb2817f2",
	"userName": "user_name",
	"name": {
		"formatted": "[first_name] [family_name]",
		"givenName": "[first_name]",
		"middleName": "[middle_name]",
		"familyName": "[family_name]"
	},
	"groups": [],
	"addresses": [],
	"emails": [],
	"phoneNumbers": [],
	"entitlements": [],
	"ims": [],
	"roles": [],
	"photos": [],
	"x509Certificates": [],
	"meta": {
		"resourceType": "User",
		"created": "2024-12-04T13:13:47.8733934Z",
		"lastModified": "2024-12-04T13:13:47.8733937Z",
		"version": 0,
		"location": "https://localhost:7225/Users/b6f44d27-04e6-46ab-adc4-8d1adb2817f2"
	},
	"externalId": "debug_user_id",
	"schemas": [
		"urn:ietf:params:scim:schemas:core:2.0:User"
	]
}

I'd expect the location to be https://localhost:7225/01ab2cc4-16f2-4e00-8296-8cd829b4e430/Users/b6f44d27-04e6-46ab-adc4-8d1adb2817f2.

thabart added a commit that referenced this issue Dec 4, 2024
@simpleidserver simpleidserver self-assigned this Dec 4, 2024
@simpleidserver simpleidserver added the bug Something isn't working label Dec 4, 2024
@simpleidserver simpleidserver moved this to In Progress in Release 5.0.3 Dec 4, 2024
@simpleidserver
Copy link
Owner

The issue has been fixed in the Release503 branch, and the location property should now be set correctly.

4ccd11b

@simpleidserver simpleidserver moved this from In Progress to Done in Release 5.0.3 Dec 4, 2024
@simpleidserver simpleidserver closed this as completed by moving to Done in Release 5.0.3 Dec 4, 2024
@simpleidserver simpleidserver reopened this Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

No branches or pull requests

2 participants