-
Notifications
You must be signed in to change notification settings - Fork 259
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
Cannot add scope
to registration request
#856
Comments
Why do you think you need to register the For OpenID Dynamic Registration (https://openid.net/specs/openid-connect-registration-1_0.html#ClientMetadata ) scope isn't a supported value. So the default oic.oic.Client does not implement it. OAuth 2.0 does allow it though, but we only implement the OAuth2 registration in the extensions, pyoidc/src/oic/extension/message.py Line 97 in f6c590c
scope as part of the registration.
|
It does not force, but it register with no scope at all.
Actually Additional Client Metadata parameters MAY also be used. Some are defined by other specifications, such as OpenID Connect Session Management 1.0 [OpenID.Session]. Another interesting reading for this topic can be found at OpenID Foundation repository, entitled "Update dynamic client registration spec to reference OAuth2 dynamic client reg". Issue description:
Correct me if I'm wrong, but by specs sending |
Agreed. The spec allows sending any key and value you want. So if you want to register a from oic.oic.message import OIDCMessageFactory, RegistrationRequest, RegistrationResponse, MessageTuple
class MyRegistrationRequest(RegistrationRequest):
# add the fields you want to send
class MyRegistrationResponse(RegistrationResponse):
# add the extra fields you expect the OP to send back
class MyMessageFactory(OIDCMessageFactory):
registration_endpoint = MessageTuple(MyRegistrationRequest, MyRegistrationResponse)
client = Client(client_authn_method=CLIENT_AUTHN_METHOD,
message_factory=MyMessageFactory) See the https://github.com/CZ-NIC/pyoidc/blob/master/src/oic/extension/message.py#L97 for a message type that has the OAuth2 registration fields available. |
thanks, do you think that updating docs / docstring about allowed fields may be helpful? |
Yes, you are welcome to submit a PR with updated docs. |
I would like to add the
scope
param to my dynamic registration request. But I realized thatoic
does not allow it the way I'm trying.scope
param is being ignored.As
register
docstring states:so, example:
And the scope param is not sent in request.
I checked
req.parameters()
, which gets me the following params:It looks like any other param then not any of those, is ignored.
After researching OAuth docs, in RFC7591 Section 1.3 , I found the following:
The text was updated successfully, but these errors were encountered: