blob: bd1b171364e62fc5724e2066a705cdfd4475235c [file] [log] [blame]
# Copyright (c) 2021 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default
name: 42.1.5. [TC-ACE-1.5] Multi-fabric
PICS:
- MCORE.ROLE.COMMISSIONEE
- APPDEVICE.S
config:
nodeId: 0x12344321
cluster: "Access Control"
endpoint: 0
payload:
type: char_string
defaultValue: "MT:-24J0AFN00KA0648G00"
discriminator:
type: int16u
defaultValue: 3840
waitAfterCommissioning:
type: int16u
defaultValue: 5000
PakeVerifier:
type: octet_string
defaultValue: "hex:b96170aae803346884724fe9a3b287c30330c2a660375d17bb205a8cf1aecb350457f8ab79ee253ab6a8e46bb09e543ae422736de501e3db37d441fe344920d09548e4c18240630c4ff4913c53513839b7c07fcc0627a1b8573a149fcd1fa466cf"
tests:
- label: "Wait for the commissioned device to be retrieved for TH1"
cluster: "DelayCommands"
command: "WaitForCommissionee"
arguments:
values:
- name: "nodeId"
value: nodeId
- label: "TH1 reads the fabric index"
cluster: "Operational Credentials"
command: "readAttribute"
attribute: "CurrentFabricIndex"
response:
saveAs: th1FabricIndex
- label:
"Step 2 & 3: TH1 puts DUT into commissioning mode, TH2 commissions DUT
using admin node ID N2"
verification: |
./chip-tool pairing open-commissioning-window 1 1 400 2000 3841
On TH1(chip-tool) note the manual pairing code for commissioning the TH2
[1684416077.831754][118314:118316] CHIP:CTL: Successfully opened pairing window on the device
[1684416077.831763][118314:118316] CHIP:CTL: Manual pairing code: [36283142515]
[1684416077.831771][118314:118316] CHIP:CTL: SetupQRCode: [MT:-24J0IRV010UJE7ZH10]
[1684416077.831791][118314:118316] CHIP:DMG: ICR moving to [AwaitingDe]
./chip-tool pairing code 2 36283142515 --commissioner-name beta
On TH2 (chip-tool) verify the commissioning completed with success
[1684416247.482777][118352:118354] CHIP:CTL: Successfully finished commissioning step 'Cleanup'
[1684416247.482789][118352:118354] CHIP:TOO: Device commissioning completed with success
[1684416247.482823][118352:118354] CHIP:DMG: ICR moving to [AwaitingDe]
cluster: "LogCommands"
command: "UserPrompt"
PICS: PICS_SKIP_SAMPLE_APP
arguments:
values:
- name: "message"
value: "Enter 'y' after success"
- name: "expectedValue"
value: "y"
- label: "Open Commissioning Window from alpha"
cluster: "Administrator Commissioning"
command: "OpenCommissioningWindow"
timedInteractionTimeoutMs: 10000
PICS: PICS_SDK_CI_ONLY
arguments:
values:
- name: "CommissioningTimeout"
value: 180
- name: "PAKEPasscodeVerifier"
value: PakeVerifier
- name: "Discriminator"
value: discriminator
- name: "Iterations"
value: 1000
- name: "Salt"
value: "SPAKE2P Key Salt"
- label: "Waiting after opening commissioning window"
cluster: "DelayCommands"
command: "WaitForMs"
PICS: PICS_SDK_CI_ONLY
arguments:
values:
- name: "ms"
value: waitAfterCommissioning
- label: "Commission from TH2"
identity: "beta"
cluster: "CommissionerCommands"
command: "PairWithCode"
PICS: PICS_SDK_CI_ONLY
arguments:
values:
- name: "nodeId"
value: nodeId
- name: "payload"
value: payload
- label: "Wait for the commissioned device to be retrieved for TH2"
identity: beta
cluster: "DelayCommands"
command: "WaitForCommissionee"
PICS: PICS_SDK_CI_ONLY
arguments:
values:
- name: "nodeId"
value: nodeId
- label: "TH2 reads the fabric index"
identity: "beta"
PICS: PICS_SDK_CI_ONLY
cluster: "Operational Credentials"
command: "readAttribute"
attribute: "CurrentFabricIndex"
response:
saveAs: th2FabricIndex
#Issue https://github.com/CHIP-Specifications/chip-certification-tool/issues/768
- label: "TH2 reads the fabric index"
verification: |
./chip-tool operationalcredentials read current-fabric-index 2 0 --commissioner-name beta
On TH2 (chip-tool) note the CurrentFabricIndex for the further use
[1684416368.885484][118383:118385] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_003E Attribute 0x0000_0005 DataVersion: 3654336520
[1684416368.885511][118383:118385] CHIP:TOO: CurrentFabricIndex: 2
[1684416368.885577][118383:118385] CHIP:EM: <<< [E:65212i S:18077 M:83303022 (Ack:184536262)] (S) Msg TX to 2:0000000000000002 [C33E] --- Type 0000:10 (SecureChannel:StandaloneAck)
cluster: "LogCommands"
command: "UserPrompt"
PICS: PICS_SKIP_SAMPLE_APP
arguments:
values:
- name: "message"
value: "Enter 'y' after success"
- name: "expectedValue"
value: "y"
- label: "Read the commissioner node ID from the alpha fabric"
identity: "alpha"
cluster: "CommissionerCommands"
command: "GetCommissionerNodeId"
response:
values:
- name: "nodeId"
saveAs: commissionerNodeIdAlpha
- label: "TH1 writes ACL giving view privilege for descriptor cluster"
command: "writeAttribute"
attribute: "ACL"
arguments:
value: [
{
FabricIndex: th1FabricIndex,
Privilege: 5, # administer
AuthMode: 2, # case
Subjects: [commissionerNodeIdAlpha],
Targets:
[{ Cluster: 0x001f, Endpoint: 0, DeviceType: null }],
},
{
FabricIndex: th1FabricIndex,
Privilege: 1, # view
AuthMode: 2, # case
Subjects: null,
Targets:
[{ Cluster: 0x001d, Endpoint: 0, DeviceType: null }],
},
]
- label: "Read the commissioner node ID from the beta fabric"
PICS: PICS_SDK_CI_ONLY
identity: "beta"
cluster: "CommissionerCommands"
command: "GetCommissionerNodeId"
response:
values:
- name: "nodeId"
saveAs: commissionerNodeIdBeta
- label: "TH2 writes ACL giving view privilge for basic cluster"
identity: beta
PICS: PICS_SDK_CI_ONLY
command: "writeAttribute"
attribute: "ACL"
arguments:
value: [
{
FabricIndex: th2FabricIndex,
Privilege: 5, # administer
AuthMode: 2, # case
Subjects: [commissionerNodeIdBeta],
Targets:
[{ Cluster: 0x001f, Endpoint: 0, DeviceType: null }],
},
{
FabricIndex: th2FabricIndex,
Privilege: 1, # view
AuthMode: 2, # case
Subjects: null,
Targets:
[{ Cluster: 0x0028, Endpoint: 0, DeviceType: null }],
},
]
#Issue https://github.com/CHIP-Specifications/chip-certification-tool/issues/768
- label: "TH2 writes ACL giving view privilge for basic cluster"
verification: |
./chip-tool accesscontrol write acl '[{"fabricIndex": 2, "privilege": 5, "authMode": 2, "subjects": [223344], "targets": [{ "cluster": 31, "endpoint": 0, "deviceType": null }]}, {"fabricIndex": 2, "privilege": 1, "authMode": 2, "subjects": null, "targets": [{ "cluster": 40, "endpoint": 0, "deviceType": null }]}]' 2 0 --commissioner-name beta
On TH2 (chip-tool) verify the success response for the write function
[1684416510.660175][118418:118420] CHIP:DMG: StatusIB =
[1684416510.660184][118418:118420] CHIP:DMG: {
[1684416510.660192][118418:118420] CHIP:DMG: status = 0x00 (SUCCESS),
[1684416510.660201][118418:118420] CHIP:DMG: },
[1684416510.660211][118418:118420] CHIP:DMG:
cluster: "LogCommands"
command: "UserPrompt"
PICS: PICS_SKIP_SAMPLE_APP
arguments:
values:
- name: "message"
value: "Enter 'y' after success"
- name: "expectedValue"
value: "y"
- label: "TH1 reads descriptor cluster - expect SUCCESS"
command: "readAttribute"
cluster: "Descriptor"
attribute: "DeviceTypeList"
- label: "TH1 reads basic cluster - expect UNSUPPORTED_ACCESS"
command: "readAttribute"
cluster: "Basic Information"
attribute: "VendorID"
response:
error: UNSUPPORTED_ACCESS
- label: "TH2 reads descriptor cluster - expect UNSUPPORTED_ACCESS"
identity: "beta"
PICS: PICS_SDK_CI_ONLY
command: "readAttribute"
cluster: "Descriptor"
attribute: "DeviceTypeList"
response:
error: UNSUPPORTED_ACCESS
#Issue https://github.com/CHIP-Specifications/chip-certification-tool/issues/768
- label: "TH2 reads descriptor cluster - expect UNSUPPORTED_ACCESS"
verification: |
./chip-tool descriptor read device-type-list 2 0 --commissioner-name beta
On TH2(chip-tool) verify the UNSUPPORTED_ACCESS (0x7e) response
[1684416700.274460][118482:118484] CHIP:DMG: StatusIB =
[1684416700.274467][118482:118484] CHIP:DMG: {
[1684416700.274475][118482:118484] CHIP:DMG: status = 0x7e (UNSUPPORTED_ACCESS),
[1684416700.274482][118482:118484] CHIP:DMG: },
cluster: "LogCommands"
command: "UserPrompt"
PICS: PICS_SKIP_SAMPLE_APP
arguments:
values:
- name: "message"
value: "Enter 'y' after success"
- name: "expectedValue"
value: "y"
- label: "TH2 reads basic cluster - expect SUCCESS"
identity: "beta"
PICS: PICS_SDK_CI_ONLY
command: "readAttribute"
cluster: "Basic Information"
attribute: "VendorID"
#Issue https://github.com/CHIP-Specifications/chip-certification-tool/issues/768
- label: "TH2 writes Extension attribute value as empty list"
verification: |
./chip-tool basicinformation read vendor-id 2 0 --commissioner-name beta
On TH2(chip-tool) verify the success with the Vendor-id
[1684416789.682243][118505:118507] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0028 Attribute 0x0000_0002 DataVersion: 2033462723
[1684416789.682271][118505:118507] CHIP:TOO: VendorID: 65521
[1684416789.682327][118505:118507] CHIP:EM: <<< [E:11340i S:29188 M:208193949 (Ack:232576417)] (S) Msg TX to 2:0000000000000002 [C33E] --- Type 0000:10 (SecureChannel:StandaloneAck)
cluster: "LogCommands"
command: "UserPrompt"
PICS: PICS_SKIP_SAMPLE_APP
arguments:
values:
- name: "message"
value: "Enter 'y' after success"
- name: "expectedValue"
value: "y"
- label: "TH1 resets ACL to default"
command: "writeAttribute"
attribute: "ACL"
arguments:
value: [
{
FabricIndex: 1,
Privilege: 5, # administer
AuthMode: 2, # case
Subjects: [commissionerNodeIdAlpha],
Targets: null,
},
]
- label: "TH1 sends RemoveFabric command for TH2"
cluster: "Operational Credentials"
PICS: PICS_SDK_CI_ONLY
command: "RemoveFabric"
arguments:
values:
- name: "FabricIndex"
value: th2FabricIndex
#Issue https://github.com/CHIP-Specifications/chip-certification-tool/issues/768
- label: "TH1 sends RemoveFabric command for TH2"
verification: |
./chip-tool operationalcredentials remove-fabric 2 1 0
On TH1(chip-tool) verify the success with the nocresponse with statuscode is success(0)
[1684416866.004187][118527:118529] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_003E Command=0x0000_0008
[1684416866.004214][118527:118529] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_003E Command 0x0000_0008
[1684416866.004236][118527:118529] CHIP:TOO: NOCResponse: {
[1684416866.004250][118527:118529] CHIP:TOO: statusCode: 0
[1684416866.004255][118527:118529] CHIP:TOO: fabricIndex: 2
[1684416866.004259][118527:118529] CHIP:TOO: }
[1684416866.004270][118527:118529] CHIP:DMG: ICR moving to [AwaitingDe]
cluster: "LogCommands"
command: "UserPrompt"
PICS: PICS_SKIP_SAMPLE_APP
arguments:
values:
- name: "message"
value: "Enter 'y' after success"
- name: "expectedValue"
value: "y"