project-chip / matter-test-scripts

Test scripts related to Matter Certification
https://csa-iot.org/
Apache License 2.0
6 stars 3 forks source link

[CERT-TEST-FAILURE] - TC-GRPKEY- 2.2 -Step22 fail #275

Closed mideayanghui closed 1 week ago

mideayanghui commented 1 week ago

Reproduction steps

Use TH Version: TH Fall2023 Sha: 27090a17 to test Step 22 fail. If we send the cmd manually. ./chip-tool groupkeymanagement key-set-write '{"groupKeySetID": 3,"groupKeySecurityPolicy": 0, "epochKey0":"d0d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime0": 1,"epochKey1":"d1d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime1": 18446744073709551613,"epochKey2":"d2d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime2": 18446744073709551614 }' 1 0 in Step 22, it actually return RESOURCE_EXHAUSTED as expected.

Bug prevalence

always

GitHub hash of the SDK that was being used

181b0cb14ff007ec912f2ba6627e05dfb066c008

Platform

other

Platform Version(s)

ASR

Type

Common Cluster Logic

Anything else?

TH Log: TC-GRPKEY-2-2_2024_06_27_11_24_04.log

bzbarsky-apple commented 1 week ago

From the log:

INFO       | 2024-06-27 03:27:31.922996 | [2024-06-27 11:26:00] ubuntu@ubuntu:~/apps$ ./chip-tool groupkeymanagement key-set-write {"groupKeySetID": 3, "groupKeySecurityPolicy": 0, "epochKey0": "hex:d0d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime0": 1, "epochKey1": "hex:d1d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime1": 18446744073709551613, "epochKey2": "hex:d2d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime2": 18446744073709551614} 1 0

That's missing single quotes around the write argument, so then everything gets parsed wrong by the shell and things fail, no?

This does not seem like an SDK issue. Should this actually be filed in https://github.com/CHIP-Specifications/chip-test-scripts/issues ? Because clearly TH is just doing the wrong thing here.

bzbarsky-apple commented 1 week ago

@cjandhyala please see above?

cjandhyala commented 1 week ago

@mideayanghui in step 21 (which is a manual step) did you do keyWrite until the GroupKeyMap attribute contains Max_GrpKey entries , if you don't do that , step 22 will return success but not RESOURCE_EXHAUSTED. pls chk that step from your execution. Since those are manual steps, those are not logged in the log file you attached.

mideayanghui commented 1 week ago

@cjandhyala In the step 21( manual step), I input 3 cmd as below, ./chip-tool groupkeymanagement key-set-write '{"groupKeySetID": 1,"groupKeySecurityPolicy": 0, "epochKey0":"d0d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime0": 1,"epochKey1":"d1d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime1": 18446744073709551613,"epochKey2":"d2d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime2": 18446744073709551614 }' 1 0 ./chip-tool groupkeymanagement key-set-write '{"groupKeySetID": 2,"groupKeySecurityPolicy": 0, "epochKey0":"d0d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime0": 1,"epochKey1":"d1d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime1": 18446744073709551613,"epochKey2":"d2d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime2": 18446744073709551614 }' 1 0 ./chip-tool groupkeymanagement key-set-write '{"groupKeySetID": 3,"groupKeySecurityPolicy": 0, "epochKey0":"d0d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime0": 1,"epochKey1":"d1d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime1": 18446744073709551613,"epochKey2":"d2d1d2d3d4d5d6d7d8d9dadbdcdddedf", "epochStartTime2": 18446744073709551614 }' 1 0 and the cmd 3 has the output General error: 0x89 (RESOURCE_EXHAUSTED)

here's the TH log I retest but the TH reports step 23 fail. TC-GRPKEY-2-2_2024_06_28_09_13_01.log

Ashwinigrl commented 1 week ago

@mideayanghui

Tried to reprodue the issue using the all-clusters-app (sample app) seems the execution ends without any issues

Attached is the screenshot and output log of the TC-GRPKEY-2.2 execution.

Snapshot :

image

Execution Log :

TC-GRPKEY-2.2.log

@cjandhyala FYI

Can you please re-verify and close this issue

mideayanghui commented 1 week ago

@cjandhyala Hey, why the log you provide without "---- Start of Manual Log ---", have you been asked to use chip-tool to send cmd in step 21?

Ashwinigrl commented 1 week ago

@mideayanghui We used th-chip-tool docker to run the manual commands that prompts in middle of the execution.

Attached the log of command that where executed manually : TC-GRPKEY-2.2(User prompt log).txt

mideayanghui commented 1 week ago

@Ashwinigrl Thanks, it works.