Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement TC-DA-1.7 test #21735

Closed
tcarmelveilleux opened this issue Aug 8, 2022 · 0 comments · Fixed by #21775
Closed

Implement TC-DA-1.7 test #21735

tcarmelveilleux opened this issue Aug 8, 2022 · 0 comments · Fixed by #21775
Assignees
Labels

Comments

@tcarmelveilleux
Copy link
Contributor

Problem

TC-DA-1.7 (https://github.com/CHIP-Specifications/chip-test-plans/blob/master/src/deviceattestation.adoc#417-tc-da-17-validate-certificatechainrequest-dut-commissionee) is a very complex test that requires particular procedures not realizable by hand with chip-tool, especially regarding complex data dependencies and value mutations.

Proposed Solution

Implement TC-DA-1.7 with matter_testing_support Python module and associated API updates if needed.

@tcarmelveilleux tcarmelveilleux self-assigned this Aug 8, 2022
tcarmelveilleux added a commit to tcarmelveilleux/connectedhomeip that referenced this issue Aug 10, 2022
- Test TC-DA-1.7 is very error-prone with chip-tool due to
  large amount of complex manual operations on manual log
  extractions of certificate values.

Fixes project-chip#21735

This PR:
- Adds a version of TC-DA-1.7 in Python
- **Touches no C++ SDK code**

Testing done:

- Ran the test as it could be done by an end-user, passed on Linux
  and on ESP32

To run:

- Build all-clusters app Linux:
  - `scripts/examples/gn_build_example.sh examples/all-clusters-app/linux out/debug/standalone chip_config_network_layer_ble=false`
  - In a shell, run: `clear && rm -f kvs1 && out/debug/standalone/chip-all-clusters-app --discriminator 3840 --KVS kvs1`
- Build the Python environment, activate it, then run the test
  - `./scripts/build_python.sh -m platform -i separate`
  - `. ./out/python_env/bin/activate`
  - Run the test: `rm -f admin_storage.json && python src/python_testing/TC_DA_1_7.py -m on-network -d 3840 -p 20202021`
    - Add `--bool-arg allow_sdk_dac:true` to the end of the command line if running against a device that
      has DACs chaining to SDK PAAs (which are forbidden by TC-DA-1.7 step 4 check 2)
woody-apple pushed a commit to tcarmelveilleux/connectedhomeip that referenced this issue Aug 10, 2022
- Test TC-DA-1.7 is very error-prone with chip-tool due to
  large amount of complex manual operations on manual log
  extractions of certificate values.

Fixes project-chip#21735

This PR:
- Adds a version of TC-DA-1.7 in Python
- **Touches no C++ SDK code**

Testing done:

- Ran the test as it could be done by an end-user, passed on Linux
  and on ESP32

To run:

- Build all-clusters app Linux:
  - `scripts/examples/gn_build_example.sh examples/all-clusters-app/linux out/debug/standalone chip_config_network_layer_ble=false`
  - In a shell, run: `clear && rm -f kvs1 && out/debug/standalone/chip-all-clusters-app --discriminator 3840 --KVS kvs1`
- Build the Python environment, activate it, then run the test
  - `./scripts/build_python.sh -m platform -i separate`
  - `. ./out/python_env/bin/activate`
  - Run the test: `rm -f admin_storage.json && python src/python_testing/TC_DA_1_7.py -m on-network -d 3840 -p 20202021`
    - Add `--bool-arg allow_sdk_dac:true` to the end of the command line if running against a device that
      has DACs chaining to SDK PAAs (which are forbidden by TC-DA-1.7 step 4 check 2)
woody-apple pushed a commit that referenced this issue Aug 10, 2022
- Test TC-DA-1.7 is very error-prone with chip-tool due to
  large amount of complex manual operations on manual log
  extractions of certificate values.

Fixes #21735

This PR:
- Adds a version of TC-DA-1.7 in Python
- **Touches no C++ SDK code**

Testing done:

- Ran the test as it could be done by an end-user, passed on Linux
  and on ESP32

To run:

- Build all-clusters app Linux:
  - `scripts/examples/gn_build_example.sh examples/all-clusters-app/linux out/debug/standalone chip_config_network_layer_ble=false`
  - In a shell, run: `clear && rm -f kvs1 && out/debug/standalone/chip-all-clusters-app --discriminator 3840 --KVS kvs1`
- Build the Python environment, activate it, then run the test
  - `./scripts/build_python.sh -m platform -i separate`
  - `. ./out/python_env/bin/activate`
  - Run the test: `rm -f admin_storage.json && python src/python_testing/TC_DA_1_7.py -m on-network -d 3840 -p 20202021`
    - Add `--bool-arg allow_sdk_dac:true` to the end of the command line if running against a device that
      has DACs chaining to SDK PAAs (which are forbidden by TC-DA-1.7 step 4 check 2)
isiu-apple pushed a commit to isiu-apple/connectedhomeip that referenced this issue Sep 16, 2022
- Test TC-DA-1.7 is very error-prone with chip-tool due to
  large amount of complex manual operations on manual log
  extractions of certificate values.

Fixes project-chip#21735

This PR:
- Adds a version of TC-DA-1.7 in Python
- **Touches no C++ SDK code**

Testing done:

- Ran the test as it could be done by an end-user, passed on Linux
  and on ESP32

To run:

- Build all-clusters app Linux:
  - `scripts/examples/gn_build_example.sh examples/all-clusters-app/linux out/debug/standalone chip_config_network_layer_ble=false`
  - In a shell, run: `clear && rm -f kvs1 && out/debug/standalone/chip-all-clusters-app --discriminator 3840 --KVS kvs1`
- Build the Python environment, activate it, then run the test
  - `./scripts/build_python.sh -m platform -i separate`
  - `. ./out/python_env/bin/activate`
  - Run the test: `rm -f admin_storage.json && python src/python_testing/TC_DA_1_7.py -m on-network -d 3840 -p 20202021`
    - Add `--bool-arg allow_sdk_dac:true` to the end of the command line if running against a device that
      has DACs chaining to SDK PAAs (which are forbidden by TC-DA-1.7 step 4 check 2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant