Michael Vogt
51f2f283c1
Merge pull request #11501 from mvo5/less-sanity-2
...
many: replace use of "sanity" with more inclusive naming in comments
2022-03-15 16:02:20 +01:00
Michael Vogt
53e100759f
Merge pull request #11502 from pedronis/disable-authority-delegation
...
asserts: minimal changes to disable authority-delegation before full revert
2022-03-15 15:00:00 +01:00
Samuele Pedroni
331724d76d
asserts: minimal changes to disable authority-delegation before full revert
...
authority-delegation might have been premature, disable until we might
decide for a full revert
2022-03-14 18:47:04 +01:00
Michael Vogt
277eb06412
many: replace use of "sanity" with more inclusive naming
...
This commit replaces the use of "sanity" with more inclusive
naming.
When `sanity` is used in a more general sense either `validity`
or `quick` is used.
2022-03-14 18:22:34 +01:00
Michael Vogt
439f267378
many: replace use of "sanity" for interface implementation checks
...
This commit replaces the use of "sanity" with more inclusive
naming. When `// sanity` is used to check if an interface is
implemented the comment `expected interface is implemented`
is used.
2022-03-14 17:35:33 +01:00
Maciej Borzecki
b1709a9e07
asserts: tweak external keypair manager error to include more info
...
Signed-off-by: Maciej Borzecki <maciej.zenon.borzecki@canonical.com >
2022-03-02 16:49:09 +01:00
Maciej Borzecki
00bb743c35
asserts: simplify keypair manager errors
...
Signed-off-by: Maciej Borzecki <maciej.zenon.borzecki@canonical.com >
2022-03-02 16:14:36 +01:00
Maciej Borzecki
bf89ad6f86
asserts: return an explicit error when key cannot be found
...
Return an explicit error, which can be checked for, when a key with given
ID/name is not found by the keypair manager.
Signed-off-by: Maciej Borzecki <maciej.zenon.borzecki@canonical.com >
2022-03-02 12:01:04 +01:00
Paweł Stołowski
17977aa380
Renamed preseed-sha3-384 to artifact-sha3-384.
2022-02-21 16:15:38 +01:00
Paweł Stołowski
746c6c235e
uc20 -> UC20.
2022-02-21 16:07:50 +01:00
Paweł Stołowski
b1ba7f2c75
Drop the check for brand-id since it must match authority-id (and there
...
needs to be a valid account assertion).
2022-02-21 16:07:50 +01:00
Paweł Stołowski
626b74ea69
Check brand-id, remove AccountID getter, add missing comments.
2022-02-21 16:07:50 +01:00
Paweł Stołowski
3553b89fca
Move ValidateUC20SeedSystemLabel from seed/internal to asserts and
...
rename to IsValidSystemLabel.
2022-02-21 16:07:50 +01:00
Paweł Stołowski
0fe92618b3
Add missing tests, remove account-id, check that authority matches
...
brand.
2022-02-21 16:07:50 +01:00
Paweł Stołowski
13ed0da7ba
Fix gci error.
2022-02-21 16:07:49 +01:00
Paweł Stołowski
537b9b1612
Add preseed assertion type.
2022-02-21 16:07:49 +01:00
Samuele Pedroni
f8d77dabc7
asserts,interfaces/policy: move and prepare DeviceScopeConstraint for reuse
...
Merge pull request #11387 from pedronis/device-scope-constraint
this moves DeviceScopeConstraint to constraint.go and adds a Check method in preparation for reuse of DeviceScopeConstraint for assertion constraints from authority-delegation.
2022-02-15 11:50:39 +01:00
Samuele Pedroni
b8ce8ad908
asserts: add comments about SignatoryID() not being empty when fetching
2022-02-15 11:03:00 +01:00
Samuele Pedroni
cfaf48ef20
asserts,interfaces/policy: introduce DeviceScopeConstraint.Check
...
this is logic extracted from the helpers in interface/policy as now
DeviceScopeConstraint will also be used by assertion constraints for
delegation
2022-02-14 15:21:55 +01:00
Samuele Pedroni
0656be2213
asserts: adapt to new usage of compileDeviceScopeConstraint
...
as used in baseCompileConstraints
it now does its own detection and returns nil for no device-scope
constraints
2022-02-14 15:21:55 +01:00
Samuele Pedroni
52de97d821
asserts: move DeviceScopeConstraint to constraint.go
...
cleanup some things
have dedicated tests
2022-02-14 15:21:55 +01:00
Samuele Pedroni
8b397923cb
asserts: teach Pool about delegation
2022-02-14 15:20:29 +01:00
Samuele Pedroni
d3bc9d65bc
asserts: teach the Fetcher implemention about delegation
...
it should fetch authority-delegation assertions as needed
2022-02-14 15:20:29 +01:00
Samuele Pedroni
d5c752b103
asserts: drop wrong and unnecessary type in fixture headers
2022-02-14 15:20:10 +01:00
Samuele Pedroni
ae292381b7
asserts: first-class support for formatting/encoding signatory-id
...
Merge pull request #11380 from pedronis/signatory-id-support
together with checks for it
2022-02-14 15:19:03 +01:00