Report DICE policy errors with the PAYLOAD_CHANGED error code

When a DICE policy error occurs, it indicates that the payload has
changed in an incompatible way. That might mean the version has
downgraded, or more/fewer components are present, etc but the result is
that the VM will not be able to access its previous secrets. This is an
event that the client app needs to notice and handle so it needs to be
exposed better than an UNKNOWN error.

There's already a PAYLOAD_CHANGED that was used when strict version
binding was the only option and no upgrade of VM payloads was allowed.
This has become unused for updatable VMs but feels appropriate to make
use of again when the change to the payload was illegal, as identified
by the DICE policy error.

Bug: 420367677
Test: atest MicrodroidTests
Flag: EXEMPT bugfix
Change-Id: Icc09930277de0911528c5fd4a9c640623553125a
4 files changed
tree: 09a4b07308dd2f3342814b5d21cfb5a3ba16ff3f
  1. android/
  2. build/
  3. docs/
  4. guest/
  5. libs/
  6. microfuchsia/
  7. tests/
  8. .clang-format
  9. .gitignore
  10. Android.bp
  11. dice_for_avf_guest.cddl
  12. OWNERS
  13. PREUPLOAD.cfg
  14. README.md
  15. rustfmt.toml
  16. TEST_MAPPING
README.md

Android Virtualization Framework (AVF)

Android Virtualization Framework (AVF) provides secure and private execution environments for executing code. AVF is ideal for security-oriented use cases that require stronger isolation assurances over those offered by Android’s app sandbox.

Visit our public doc site to learn more about what AVF is, what it is for, and how it is structured. This repository contains source code for userspace components of AVF.

If you want a quick start, see the getting started guideline and follow the steps there.

For in-depth explanations about individual topics and components, visit the following links.

AVF components:

AVF APIs:

How-Tos: