Google Workspace support#161
Conversation
| request.format = :scim | ||
| elsif request.format == :scim | ||
| request.headers['CONTENT_TYPE'] = scim_mime_type | ||
| elsif request.media_type.downcase == 'application/json' && request.user_agent.start_with?('Google') # https://github.com/pond/scimitar/issues/142 |
There was a problem hiding this comment.
We have the same problem, but some of our customers send something else alongside application/json content type, so this update doesn't cover our use case and we still have to workaround on our side.
I think there could be a config option instead to allow setting supported content types explicitly. Additionally, I guess user agent could be left unset, so this will produce an exception like this:
undefined method 'start_with?' for nil
["[...]/3.4.2/lib/ruby/gems/3.4.0/gems/scimitar-2.13.0/app/controllers/scimitar/application_controller.rb:104:in 'Scimitar::ApplicationController#require_scim'"
There was a problem hiding this comment.
@aerodynamik Noted - I hope to have some time to look into this on Friday.
There was a problem hiding this comment.
@aerodynamik via #166, Scimitar 2.14.0 has been released which lets you provide your own sanitizer for inbound requests.
Hopefully, this meets your requirements.
Addresses #142. Thanks for the bug report and suggested resolution, @kwent 😄