Skip to content

TAP 6 - Include specification version in metadata - #18

Merged
vladimir-v-diaz merged 6 commits into
masterfrom
tap6
May 19, 2017
Merged

vladimir-v-diaz merged 6 commits into
masterfrom
tap6

Conversation

@vladimir-v-diaz

Copy link
Copy Markdown
Contributor

@vladimir-v-diaz vladimir-v-diaz changed the title TAP 6 - Include specifiation version in metadata TAP 6 - Include specification version in metadata Jan 20, 2017
Comment thread README.md Outdated
* [TAP 5: Setting URLs for roles in the root metadata file](https://github.com/theupdateframework/taps/blob/master/tap5.md)
* [TAP 4: The map file](tap4.md)
* [TAP 5: Setting URLs for roles in the root metadata file](tap5.md)
* [TAP: 6: Include specification version in metadata](tap6.md)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Extra :?

Remove extra `:` in TAP 6 entry.
@ecordell

Copy link
Copy Markdown
Contributor

What types of change to the spec constitute a spec_version change?

What should a client do if it sees fields defined in a spec_version different from the listed spec_version?

What does a client that supports v1 do when it sees a v1.1? Give up, since it doesn't know the security implications of the .1 change?

Does the version being in the signed portion of the metadata adequately mitigate downgrade attacks?

The TAPs currently consider backwards compatibility in terms of clients that support the TAP and clients that don't. In all of those cases, the client makes decisions based on the data it sees, not the stated spec version. The motivating example is not an issue for newer clients, which ignore the deprecated field.

My current thinking is that if a TAP's changes are backwards-compatible, this does not constitute a need for a version change. Most changes can probably be backwards compatible, only those that change "protocol" like order of metadata downloading or types of metadata files would need to break.

Thoughts?

@vladimir-v-diaz

vladimir-v-diaz commented Jan 25, 2017 •

Copy link
Copy Markdown
Contributor Author

What types of change to the spec constitute a spec_version change?

I think any accepted TAP that introduces a backwards incompatibility warrants a change to the specification's major version number. That is, the X in version number X.Y. For example, TAP 3 (multi-role delegations) should require a change to the X. For TAP 7 (Conformance testing), the Y would change and imply that it's a backwards compatible change to the specification.

What should a client do if it sees fields defined in a spec_version different from the listed spec_version?

Are you asking what should a client do if the format of metadata, that's supposedly for a specific spec_version, is not valid? For example, metadata for spec_version: 1.2 requires a terminating field, but the 1.2 metadata downloaded by the client does not include the required terminating field.

I think in this case, the client should reject the metadata as improperly formatted and raise an exception. I think the client should only reject major version numbers that it doesn't support/recognize. Metadata with varied minor version numbers should be safe to parse by the client.

What does a client that supports v1 do when it sees a v1.1? Give up, since it doesn't know the security implications of the .1 change?

See above. It shouldn't give up if it's a minor version change. However, unsupported major version numbers should be rejected and cause an exception.

My current thinking is that if a TAP's changes are backwards-compatible, this does not constitute a need for a version change. Most changes can probably be backwards compatible, only those that change "protocol" like order of metadata downloading or types of metadata files would need to break.

I agree.

Please note that this is only my opinion, and I haven't discussed them with the rest of the team.

@JustinCappos

JustinCappos commented Mar 14, 2017 via email

Copy link
Copy Markdown
Member

@vladimir-v-diaz

Copy link
Copy Markdown
Contributor Author

Okay, I will update the TAP to explain how specification version numbers change when a TAP is implemented.

@awwad

awwad commented Mar 20, 2017

Copy link
Copy Markdown
Contributor

@ecordell

What does a client that supports v1 do when it sees a v1.1? Give up, since it doesn't know the security implications of the .1 change?

That's a good question! If we go with this behavior that @vladimir-v-diaz suggested:

"It shouldn't give up if it's a minor version change. However, unsupported major version numbers should be rejected and cause an exception.")

then we should make sure that we never release a specification version X.Y where interpretation as if it were version X.Z (Z<Y) by a client familiar with X.Z might result in insecure or undesired behavior.

In other words, regardless of whether or not the metadata "format" has changed, if the expected behavior changes in such a way that the meaning of new metadata with the same text has changed, then the major version number for the metadata must be increased, because we cannot allow an old client to misunderstand new metadata.

For example, reversing the default value of terminating (used to be backtracking) from False to True, must result in a change to the specification's major version number so as to prevent old clients from misinterpreting the new metadata (They should reject it instead.).

@vladimir-v-diaz

vladimir-v-diaz commented Mar 20, 2017 •

Copy link
Copy Markdown
Contributor Author

@JustinCappos
A word, or two, might be missing from the quote you provided: "behavior we intend to have outdated (version X.*) clients"

Are you saying that a change to the spec's minor version is only backwards compatible for clients within the same major version? I originally said, "... the Y would change and imply that it's a backwards compatible change to the specification" Are you pointing out that the use of specification at the end of the sentence is unclear?

@vladimir-v-diaz

Copy link
Copy Markdown
Contributor Author

TAPs that have been assigned a TAP number will now be merged into the "master" branch. This does not mean that the merged TAP has been accepted, only that the proposed change (with potential tweaks) is likely to be incorporated into TUF.

We'll likely continue to comment on the pull request after it's been closed, so that we can easily comment on specific lines of the TAP.

@endophage Thanks for submitting TAP 6!

@vladimir-v-diaz
vladimir-v-diaz merged commit 1c8f01c into master May 19, 2017
@vladimir-v-diaz
vladimir-v-diaz deleted the tap6 branch May 19, 2017 15:45
@JustinCappos

JustinCappos commented May 19, 2017 via email

Copy link
Copy Markdown
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants