-
Notifications
You must be signed in to change notification settings - Fork 372
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
Update outdated spec and do not restrict on 3PID medium #1039
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
.. Copyright 2017 Kamax.io | ||
.. | ||
.. Licensed under the Apache License, Version 2.0 (the "License"); | ||
.. you may not use this file except in compliance with the License. | ||
.. You may obtain a copy of the License at | ||
.. | ||
.. http://www.apache.org/licenses/LICENSE-2.0 | ||
.. | ||
.. Unless required by applicable law or agreed to in writing, software | ||
.. distributed under the License is distributed on an "AS IS" BASIS, | ||
.. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
.. See the License for the specific language governing permissions and | ||
.. limitations under the License. | ||
|
||
3PID Medium types | ||
----------------- | ||
3PID medium types are identifiers refering to other networks can connect to. | ||
They are always lowercase. | ||
|
||
The following list are the official identifiers for most used networks: | ||
|
||
========== ================== | ||
Medium ID Network | ||
========== ================== | ||
``email`` E-mail | ||
``msisdn`` PSTN Phone numbers | ||
========== ================== | ||
|
||
This list is not exhaustive and arbitrary values can be used throughout the protocol. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. But what would it mean to use a value other than the ones above? How would the IS know how to validate it? I think this should be more like, "More identifiers may be added in future versions of this spec." There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
My intention is to have an open list which is not restricted by values listed in the spec for the following reasons:
So it would mean it's implementation depend. If the server supports it (or only need to store it).
That would depend on the implementation. Either it does, or it doesn't and returns a specific message.
I disagree. This sounds like the list is exhaustive or that other values need to be validated before being used. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK - all valid points. How about we namespace it then? Anything without a '.' character is reserved, as in anything starting That said, this is becoming a material change to the spec which would normally go through discussion, although perhaps we can just point people here and see if folks agree. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As you point out, namespacing would be a material/functional change which I wanted to avoid. This PR approach doesn't break anything, clarifies on msisdn and allows other future types to exists - no downsides. If we want to namespace, it would involve complex changes. That would be best suited for a new approach in the IS altogether, don't you think? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. My suggestion was that we do it in a backwards compatible way, allowing for us to transition from I think both allowing arbitrary values is still a material change to the spec since it rules out namespacing or anything else like this down the line. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There are a couple of things I don't understand in the alternative text above, but I don't want to make this discussion even longer. I really think at this point we should limit the scope of this PR to just adding There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Apologies, the following is a bit off-topic for this PR specifically. @dbkr where should proposals from the community like this go? The matrix If there isn't such a place yet, github PRs against matrix-doc seems like as CONTRIBUTING.rst says the following:
so to follow this, would a PR against the drafts folder be enough? Just There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. CONTRIBUTING.rst spells it out pretty clearly: rather than sprawling PR discussions like this one, the intention is to work through drafts via Google Docs. Github's code review simply doesn't cut it for this, and in practice Google Docs's threaded comment system works really well. The point is that anyone can use Google Docs - it's categorically not just for the core team, and we'll happily add drafts from the community into the shared folders there. Please let's not go back to PRing against matrix-doc/drafts. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
@ara4n just to clarify the point: this PR is about documenting existing behavior of sydent. This PR does not include changes to the current protocol. It follow verbatim the current code. I'll be very happy to work in Google Docs for the next iteration, taking into account what Dave mentioned. This PR was meant to help others in the community understand what is currently happening, and give documented context for the draft I wanted to write. Please let me know what can I do better so PRs documenting the current behavior of implementations are accepted? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It does propose a change to the current protocol - the concept of the identifier being namespaced rather than an arbitrary string literal (or one of a set). I agree that a googledoc proposal for this is probably overkill though. I'd suggest just accepting(!!!) @dbkr's review (the suggestion of "More identifiers may be added in future versions of this spec.") to unblock the PR, and then quickly opening a separate spec issue or PR to propose changing the format to be namespaced. This then unblocks the rest of the perfectly valid stuff in this PR, and gives a chance to discuss the namespacing change properly elsewhere rather than buried in here. @non-Jedi, hopefully this answers your question too. Sorry for missing this - I was travelling at the end of last week. I am unclear on you keep closing the PR rather than actually accept the review and split out the contentious item. The idiom for this in English is 'throwing the baby out with the bathwater...' |
||
|
||
| In case a server is not capable of handing a request due to a 3PID medium type, like | ||
sending a notification, it should return the protocol equivalent of a | ||
``Not Implemented`` status. | ||
| This behaviour can be overwritten at the endpoint specification level. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
.. Copyright 2016 OpenMarket Ltd | ||
.. Copyright 2017 Kamax.io | ||
.. | ||
.. Licensed under the Apache License, Version 2.0 (the "License"); | ||
.. you may not use this file except in compliance with the License. | ||
|
@@ -52,6 +53,8 @@ necessarily provide evidence that they have validated associations, but claim to | |
have done so. Establishing the trustworthiness of an individual identity service | ||
is left as an exercise for the client. | ||
|
||
3PID Medium types are described in the `Appendices`_. | ||
|
||
Privacy | ||
------- | ||
|
||
|
@@ -291,3 +294,5 @@ It will look up ``token`` which was stored in a call to ``store-invite``, and fe | |
} | ||
|
||
.. _`Unpadded Base64`: ../appendices.html#unpadded-base64 | ||
.. _`Appendices`: ../appendices.html#pid-medium-types | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. are you missing a '3' in the link here? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. No this is the correct link. The documentation generator does not put a 3 there for some reason. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fair enough, I thought it might be but wanted to check. |
||
|
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.
See comment below, but I would expect this to be telling me what mediums this versions of the spec is defining the behaviour of.
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.
See my other comments for why the spec should not be a closed list.