Comments (10)
Great question, @jvilimek! TUF actually does not have any semantics for package versions. As far as TUF is concerned, the version of a package is just part of its name and downgrading from "my-package-v2" to "my-package-v1", is just a change of package (i.e. target).
What TUF does care about is the version of the corresponding metadata, so that the client always has a fresh view of the repository, even if that fresh view includes an older package than the previous view.
from taps.
Another improvement (or earlier mitigation of the production issues) would be A/B testing or rolling deployment (10%... 20%... 50% of clients...) or rings (beta/pre-release/early-adopters/slow-ring...).
This sounds very reasonable. Though, I don't think any of this needs a TAP, which is the formal process for specification changes. Instead I would discuss this as part of deployment considerations / best practices. We have an open issue here: theupdateframework/specification#91
from taps.
I do understand now. We need to implement this by ourselves in our client(s). Thanks for your patience with me and for the quick answers!
from taps.
Great question, @jvilimek! TUF actually does not have any semantics for package versions. As far as TUF is concerned, the version of a package is just part of its name and downgrading from "my-package-v2" to "my-package-v1", is just a change of package (i.e. target).
What TUF does care about is the version of the corresponding metadata, so that the client always has a fresh view of the repository, even if that fresh view includes an older package than the previous view.
Thanks for the quick reply! Let me elaborate on this a bit:
What is now the principle the TUF client knows there is a version it needs to install? AFAIK it installs the latest version, right?
This is the current structure of TUF json:
{
"signatures": [...],
"signed": {
"_type": "targets",
"expires": "2024-01-12T14:59:21Z",
"spec_version": "1.0",
"targets": {
"some-namespace/1.0.1019/some-file.zip": {
"hashes": {
"sha512": "4060b38ab...074d30f83cc82"
},
"length": 35673351
},
"some-namespace/1.0.1019/other-file.yaml": {
"hashes": {
"sha512": "fe0403da52...198ec2be92dbb33"
},
"length": 807
},
...
}
}
How about changing this a little bit:
{
"signatures": [],
"signed": {
"_type": "targets",
"expires": "2024-01-12T14:59:21Z",
"spec_version": "2.0",
"targets": {
"some-namespace": {
"current_version": "1.0.1019", // <<<-- this we can change even downwards
"all_versions": [
{
"version": "1.0.1019",
"status": "active", // valid | revoked | not-supported | ...
"some-file.zip": {
"length": 35673351,
"sha512-hash": "4060b38abc...01f83cc82"
},
"other-file.yaml": {
"length": 807,
"sha512-hash": "4060b38abc...30f83cc82"
}
}
]
}
}
}
}
(for backward compatibility, you can keep targets.json
and introduce a new targets2.json
?)
from taps.
Another improvement (or earlier mitigation of the production issues) would be A/B testing or rolling deployment (10%... 20%... 50% of clients...) or rings (beta/pre-release/early-adopters/slow-ring...).
This sounds very reasonable. Though, I don't think any of this needs a TAP, which is the formal process for specification changes. Instead I would discuss this as part of deployment considerations / best practices. We have an open issue here: theupdateframework/specification#91
have you send a correct link? This one navigates to an issue "Secondary literature with detailed rationale and recommendations"?
from taps.
Hey @jvilimek, thanks for reaching out. Firstly, would you please elaborate on your exact issue? Is it about different versions of TUF metadata (according to the specification), and which versions of these metadata or the spec that clients support? For that, you may wish to see TAP 14. Does this help, or are you looking for something else?
from taps.
from taps.
Hey @jvilimek, thanks for reaching out. Firstly, would you please elaborate on your exact issue?
Thanks @trishankatdatadog for the reply. Sure, I will elaborate. By production issue I mean the following:
- we are using TUF for deploying plugins among our clients. This plugin sends some data to our services in the cloud.
- let's say we have deployed version 1.0 to DEV, STG, and to PROD environment (=among all our clients)
- we start deploying (and testing) version 1.1 to DEV, then STG ... no issue is found.
- then we deploy this version to PROD and suddenly our services in the cloud start crashing and/or are overloaded.
- we want to revert the deployment and re-install version 1.0 among our clients (on all environments)
Sure.. you can argue that we should have found the issue in the DEV or STG environment. But no testing process is 100% successful and cases like this just happen.
from taps.
I'll also chime in that Uptane (which is a variant of TUF) has a centralized party that controls what versions of software are pushed out to different clients. So looking there may also answer many of your questions...
Thanks, we will check this for sure!
from taps.
What is now the principle the TUF client knows there is a version it needs to install? AFAIK it installs the latest version, right?
Actually, no. TUF (that is, its metadata format and client workflow specification) simply do not know anything about artifact versions. Currently, a client application using the TUF updater needs to already know what artifact (version) it wants.
You might find this write-up about artifact discovery in TUF interesting: https://docs.google.com/document/d/1rWHAM2qCUtnjWD4lOrGWE2EIDLoA7eSy4-jB66Wgh0o
have you send a correct link? This one navigates to an issue "Secondary literature with detailed rationale and recommendations"?
Oh, I maybe wasn't clear. I was trying to say that your proposal seemed to me like a specific deployment recommendation, and that we have an open issue, which points out how great it would be if we had a collection of specific deployment recommendations as secondary literature to the specification.
from taps.
Related Issues (20)
- TAP process (TAP 1) HOT 7
- Allowing TAPs that are licensed with MIT or Apache 2.0? HOT 12
- TAP process: issue with pre-implementation phase visibility
- master branch protection HOT 6
- Discussion of TAP 15: Succinct hash bin delegations HOT 10
- Discussion of TAP 16: Snapshot Merkle trees HOT 3
- Discussion of TAP 12: Improving keyid flexibility HOT 4
- Discussion of TAP 14: Managing TUF Versions HOT 6
- Discussion of TAP 13: User Selection of the Top-Level Target Files Through Mapping Metadata HOT 1
- Discussion of TAP-17: Remove signature wrapper from TUF spec HOT 3
- POUF1 is out of date
- audit logs for root metadata changes
- Should POUF-1 allow whitespace for prettified output? HOT 2
- Define preferred style for wrapping and enforce with linter
- Discussion of Fulcio TAP (TAP 18) HOT 6
- [TAP 8] Should rotate files be listed in snapshot metadata? HOT 1
- Introduce a status for approved/accepted TAPs that are not intended to make it into the core specification
- TAP request: artifact discovery, index files and targets metadata HOT 1
- TAP 19: should discuss privacy HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from taps.