From 014afa1f18c5773063b3cd64d9c26a4d485da730 Mon Sep 17 00:00:00 2001 From: Thomas Fossati Date: Thu, 22 Aug 2024 17:37:33 +0200 Subject: [PATCH] doc: update end-to-end docs --- end-to-end/end-to-end-docker | 4 ++-- end-to-end/end-to-end-native | 4 ++-- end-to-end/walkthrough.md | 6 +++--- perf/scripts/run-loads.py | 4 ++-- ...sa-p2-refval.cbor => corim-psa-p2-refvalue.cbor} | Bin provisioning/test-harness/req.sh | 7 ++++--- 6 files changed, 13 insertions(+), 12 deletions(-) rename provisioning/test-harness/{corim-psa-p2-refval.cbor => corim-psa-p2-refvalue.cbor} (100%) diff --git a/end-to-end/end-to-end-docker b/end-to-end/end-to-end-docker index 29f4ac05..221a0d98 100755 --- a/end-to-end/end-to-end-docker +++ b/end-to-end/end-to-end-docker @@ -14,11 +14,11 @@ function provision() { case $SCHEME in psa) local corim_file=$THIS_DIR/input/psa-endorsements.cbor - local media_type="application/corim-unsigned+cbor; profile=http://arm.com/psa/iot/1" + local media_type="application/corim-unsigned+cbor; profile=\"http://arm.com/psa/iot/1\"" ;; cca) local corim_file=$THIS_DIR/input/cca-endorsements.cbor - local media_type="application/corim-unsigned+cbor; profile=http://arm.com/cca/ssd/1" + local media_type="application/corim-unsigned+cbor; profile=\"http://arm.com/cca/ssd/1\"" ;; *) echo "ERROR: bad SCHEME: $SCHEME" diff --git a/end-to-end/end-to-end-native b/end-to-end/end-to-end-native index cf8100d7..2555b7eb 100755 --- a/end-to-end/end-to-end-native +++ b/end-to-end/end-to-end-native @@ -32,11 +32,11 @@ function provision() { case $SCHEME in psa) local corim_file=$THIS_DIR/input/psa-endorsements.cbor - local media_type="application/corim-unsigned+cbor; profile=http://arm.com/psa/iot/1" + local media_type="application/corim-unsigned+cbor; profile=\"http://arm.com/psa/iot/1\"" ;; cca) local corim_file=$THIS_DIR/input/cca-endorsements.cbor - local media_type="application/corim-unsigned+cbor; profile=http://arm.com/cca/ssd/1" + local media_type="application/corim-unsigned+cbor; profile=\"http://arm.com/cca/ssd/1\"" ;; *) echo "ERROR: bad SCHEME: $SCHEME" diff --git a/end-to-end/walkthrough.md b/end-to-end/walkthrough.md index b32dc542..0d344e55 100644 --- a/end-to-end/walkthrough.md +++ b/end-to-end/walkthrough.md @@ -378,7 +378,7 @@ The CoRIM file can be submitted to Veraison using the following command: cocli corim submit \ --corim-file=tmp/psa-corim.cbor \ --api-server=http://provisioning-service:8888/endorsement-provisioning/v1/submit \ - "--media-type='application/corim-unsigned+cbor; profile=http://arm.com/psa/iot/1'" + --media-type='application/corim-unsigned+cbor; profile="http://arm.com/psa/iot/1"' ~~~ By dumping the Veraison database with the "veraison stores" command we can see the correctly entered entries: @@ -587,8 +587,8 @@ The result may be something like this: "y": "IBOL-C3BttVivg-lSreASjpkttcsz-1rb7btKLv8EX4" }, "media-types": [ - "application/eat-collection; profile=http://arm.com/CCA-SSD/1.0.0", - "application/eat-cwt; profile=http://arm.com/psa/2.0.0", + "application/eat-collection; profile=\"http://arm.com/CCA-SSD/1.0.0\"", + "application/eat-cwt; profile=\"http://arm.com/psa/2.0.0\"", "application/pem-certificate-chain", "application/vnd.enacttrust.tpm-evidence", "application/vnd.parallaxsecond.key-attestation.cca", diff --git a/perf/scripts/run-loads.py b/perf/scripts/run-loads.py index 9dd60a81..1df9ba1d 100755 --- a/perf/scripts/run-loads.py +++ b/perf/scripts/run-loads.py @@ -38,7 +38,7 @@ def provision(self): self.client.post( "/endorsement-provisioning/v1/submit", headers={ - 'Content-Type': 'application/corim-unsigned+cbor; profile=http://arm.com/psa/iot/1', + 'Content-Type': 'application/corim-unsigned+cbor; profile="http://arm.com/psa/iot/1"', }, data=self.provisioning_data, ) @@ -63,7 +63,7 @@ def on_start(self): requests.post( ProvisioningUser.host + "/endorsement-provisioning/v1/submit", headers={ - 'Content-Type': 'application/corim-unsigned+cbor; profile=http://arm.com/psa/iot/1', + 'Content-Type': 'application/corim-unsigned+cbor; profile="http://arm.com/psa/iot/1"', }, data=provisioning_data, ) diff --git a/provisioning/test-harness/corim-psa-p2-refval.cbor b/provisioning/test-harness/corim-psa-p2-refvalue.cbor similarity index 100% rename from provisioning/test-harness/corim-psa-p2-refval.cbor rename to provisioning/test-harness/corim-psa-p2-refvalue.cbor diff --git a/provisioning/test-harness/req.sh b/provisioning/test-harness/req.sh index 10427744..7fb50d4e 100755 --- a/provisioning/test-harness/req.sh +++ b/provisioning/test-harness/req.sh @@ -13,10 +13,10 @@ CORIM_FILE=corim-${T}-${B}.cbor if [ "${T}" == "psa" ] then - CONTENT_TYPE="Content-Type: application/corim-unsigned+cbor; profile=http://arm.com/psa/iot/1" + CONTENT_TYPE='Content-Type: application/corim-unsigned+cbor; profile="http://arm.com/psa/iot/1"' elif [ "${T}" == "tpm-enacttrust" ]; then - CONTENT_TYPE="Content-Type: application/corim-unsigned+cbor; profile=http://enacttrust.com/veraison/1.0.0" + CONTENT_TYPE='Content-Type: application/corim-unsigned+cbor; profile="http://enacttrust.com/veraison/1.0.0"' elif [ "${T}" == "parsec-tpm" ] then CONTENT_TYPE='Content-Type: application/corim-unsigned+cbor; profile="tag:github.com/parallaxsecond,2023-03-03:tpm"' @@ -26,8 +26,9 @@ else fi curl --include \ + --insecure \ --data-binary "@${CORIM_FILE}" \ --header "${CONTENT_TYPE}" \ --header "Accept: application/vnd.veraison.provisioning-session+json" \ --request POST \ - http://localhost:8888/endorsement-provisioning/v1/submit + https://localhost:8888/endorsement-provisioning/v1/submit