-
Notifications
You must be signed in to change notification settings - Fork 31
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
Term protection algorithm steps do not adequately protect @vocab
#553
Comments
The syntax describes
IIRC, there was a discussion on protected contexts vs protected term definitions, and term definitions were important, as more contexts could be layered on that weren't protected, but the term definitions that were protected would remain. Neither For Also, there would be quite a bit of new description need in the syntax document, as most of the discussion is on protected term definitions. |
Yes, I expected that when EDIT: But new definitions would never work with a "catch all" |
We may have decided that using The This allows you to ignore unknown contexts that follow the context you do know, and still allow you to consume properties from the known contexts (but never the unknown ones). However, if you had a known context that used To give an example:
So, if you want to use I recommend we close this issue because using |
@dlongley I put it in the "Discuss Call" list, but as you're the creator, you can feel free to close the issue. But, I presume there is some change needed to at least the API document to at least note this, if not add more normative text. |
There is at least this call to action. Some sort of note/warning on each of these two terms cautioning about the dangers of assuming they can be used together without confusion. We can certainly add a section in any future best practices content as well, but some sort of syntax spec level warning message seems justifiable. |
EDIT (2024) to provide some context (no pun intended): In the Verifiable Credentials work, an argument to add
@vocab
to the core VC context was made (notably, I recommended against it) which caused this question to come up. Some arguing for it were happy to be able to change the@vocab
value in subsequent contexts as current processors allow and the group moved on. Recently, others have been surprised not necessarily that this can happen, but even that terms that would have been caught by a "catch all"@vocab
can be defined in subsequent contexts. See my comment below on how, when followed to its logical conclusion, it seems that the current behavior is the only possible way for a "catch all" use of the@vocab
feature to work.When
@vocab
is used in an@protected
context, the terms it auto-definesshoulddo not receive the same protection that any other terms receive. Any processor that only checks an@context
value (i.e., a URL w/an immutable context value)shouldcannot be guaranteed to have the same view on the term mappings generated as a processor that, for example, transforms the data to another@context
. This is the value and purpose of@protected
.However,The steps currently expressed in the API spec do not cause@vocab
(and@base
as well, because these are specially-called out keywords for processing) to run through the protection processing code.IMO, this should be considered errata. Any keyword values in anEDIT: IMO, the combination of@protected
context that establish term definitions should receive the same protection that the terms do -- as changing the values of those keywords would change the term definitions, breaking the expected protection and unified processing model.@vocab
and@base
with@protected
do not make sense and would produce results that are even more unexpected than a naive guess at what would happen if they did work together.The text was updated successfully, but these errors were encountered: