blob: f6104a53d411d14591b5a1767b05b20c7f5929a5 [file] [log] [blame]
# Copyright (c) 2024 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: 217.2.3. [TC-ICDM-3.2] Verify RegisterClient command with DUT as Server
PICS:
- ICDM.S
- ICDM.S.C00.Rsp
- ICDM.S.C02.Rsp
config:
nodeId: 0x12344321
cluster: "Basic Information"
endpoint: 0
tests:
- label: "Preconditions"
verification: |
1.Commission DUT to TH (can be skipped if done in a preceding test).
2a.TH reads from the DUT the RegisteredClients attribute.
2b.If list of registered clients is not empty, unregister existing client(s)
2c.TH reads from the DUT the RegisteredClients attribute. Verify that the DUT response contains empty list of registered clients.
disabled: true
- label:
"Step 1a: TH sends RegisterClient command. - CheckInNodeID:
registering clients node ID (CheckInNodeID1) - MonitoredSubject:
monitored subject ID (MonitorSubID1) - Key: shared secret between the
client and the ICD (Key1)"
PICS: ICDM.S.C00.Rsp
verification: |
./chip-tool icdmanagement register-client 1 1 hex:1234567890abcdef1234567890abcdef 1 0
[1702418857.289325][1350:1352] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0001
[1702418857.289426][1350:1352] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Command 0x0000_0001
[1702418857.289635][1350:1352] CHIP:TOO: RegisterClientResponse: {
[1702418857.289725][1350:1352] CHIP:TOO: ICDCounter: 1321491095
[1702418857.289781][1350:1352] CHIP:TOO: }
disabled: true
- label: "Step 1b: TH reads from the DUT the RegisteredClients attribute."
PICS: ICDM.S.A0003
verification: |
./chip-tool icdmanagement read registered-clients 1 0
[1702418868.283920][1353:1355] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0003 DataVersion: 4124981277
[1702418868.284152][1353:1355] CHIP:TOO: RegisteredClients: 2 entries
[1702418868.284338][1353:1355] CHIP:TOO: [1]: {
[1702418868.284396][1353:1355] CHIP:TOO: CheckInNodeID: 112233
[1702418868.284449][1353:1355] CHIP:TOO: MonitoredSubject: 112233
[1702418868.284525][1353:1355] CHIP:TOO: FabricIndex: 1
[1702418868.284577][1353:1355] CHIP:TOO: }
[1702418868.284647][1353:1355] CHIP:TOO: [2]: {
[1702418868.284700][1353:1355] CHIP:TOO: CheckInNodeID: 1
[1702418868.284751][1353:1355] CHIP:TOO: MonitoredSubject: 1
[1702418868.284801][1353:1355] CHIP:TOO: FabricIndex: 1
[1702418868.284849][1353:1355] CHIP:TOO: }
disabled: true
- label: "Step 1c: Power cycle DUT"
verification: |
Power cycle DUT
disabled: true
- label: "Step 1d: TH reads from the DUT the RegisteredClients attribute."
PICS: ICDM.S.A0003(RegisteredClients)
verification: |
./chip-tool icdmanagement read registered-clients 1 0
[1702418876.828984][1356:1358] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0003 DataVersion: 4124981277
[1702418876.829201][1356:1358] CHIP:TOO: RegisteredClients: 2 entries
[1702418876.829372][1356:1358] CHIP:TOO: [1]: {
[1702418876.829426][1356:1358] CHIP:TOO: CheckInNodeID: 112233
[1702418876.829535][1356:1358] CHIP:TOO: MonitoredSubject: 112233
[1702418876.829609][1356:1358] CHIP:TOO: FabricIndex: 1
[1702418876.829655][1356:1358] CHIP:TOO: }
[1702418876.829719][1356:1358] CHIP:TOO: [2]: {
[1702418876.829766][1356:1358] CHIP:TOO: CheckInNodeID: 1
[1702418876.829867][1356:1358] CHIP:TOO: MonitoredSubject: 1
[1702418876.829912][1356:1358] CHIP:TOO: FabricIndex: 1
[1702418876.829955][1356:1358] CHIP:TOO: }
disabled: true
- label:
"Step 2a: Setup the TH such that is has administrator privileges for
the ICDM cluster."
verification: |
chip-tool default with admin privilege.
disabled: true
- label:
"Step 2b: TH sends RegisterClient command with same CheckInNodeID as
in Step 1a and different MonitoredSubject and Key. - CheckInNodeID:
registering clients node ID (CheckInNodeID1) - MonitoredSubject:
monitored subject ID (MonitorSubID2) - Key: shared secret between the
client and the ICD (Key2)"
PICS: ICDM.S.C00.Rsp
verification: |
./chip-tool icdmanagement register-client 1 2 hex:abcdef1234567890abcdef1234567890 1 0
[1702418883.807797][1359:1361] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0001
[1702418883.807919][1359:1361] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Command 0x0000_0001
[1702418883.808188][1359:1361] CHIP:TOO: RegisterClientResponse: {
[1702418883.808260][1359:1361] CHIP:TOO: ICDCounter: 1321491095
[1702418883.808316][1359:1361] CHIP:TOO: }
disabled: true
- label: "Step 2c: TH reads from the DUT the ICDCounter attribute."
PICS: ICDM.S.A0004
verification: |
./chip-tool icdmanagement read icdcounter 1 0
[1702418902.706877][1365:1367] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0004 DataVersion: 4124981277
[1702418902.706989][1365:1367] CHIP:TOO: ICDCounter: 1321491095
disabled: true
- label: "Step 2d: TH reads from the DUT the RegisteredClients attribute."
PICS: ICDM.S.A0003
verification: |
./chip-tool icdmanagement read registered-clients 1 0
[1702418891.793516][1362:1364] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0003 DataVersion: 4124981277
[1702418891.793737][1362:1364] CHIP:TOO: RegisteredClients: 2 entries
[1702418891.793959][1362:1364] CHIP:TOO: [1]: {
[1702418891.794016][1362:1364] CHIP:TOO: CheckInNodeID: 112233
[1702418891.794065][1362:1364] CHIP:TOO: MonitoredSubject: 112233
[1702418891.794133][1362:1364] CHIP:TOO: FabricIndex: 1
[1702418891.794179][1362:1364] CHIP:TOO: }
[1702418891.794290][1362:1364] CHIP:TOO: [2]: {
[1702418891.794344][1362:1364] CHIP:TOO: CheckInNodeID: 1
[1702418891.794390][1362:1364] CHIP:TOO: MonitoredSubject: 2
[1702418891.794483][1362:1364] CHIP:TOO: FabricIndex: 1
[1702418891.794531][1362:1364] CHIP:TOO: }
disabled: true
- label:
"Step 2e: TH sends UnregisterClient command with the CheckInNodeID
(CheckInNodeID1)."
PICS: ICDM.S.C02.Rsp
verification: |
./chip-tool icdmanagement unregister-client 1 1 0
[1702419153.281757][1380:1382] CHIP:DMG: InvokeResponseMessage =
[1702419153.281885][1380:1382] CHIP:DMG: {
[1702419153.282005][1380:1382] CHIP:DMG: suppressResponse = false,
[1702419153.282061][1380:1382] CHIP:DMG: InvokeResponseIBs =
[1702419153.282126][1380:1382] CHIP:DMG: [
[1702419153.282177][1380:1382] CHIP:DMG: InvokeResponseIB =
[1702419153.282243][1380:1382] CHIP:DMG: {
[1702419153.282296][1380:1382] CHIP:DMG: CommandStatusIB =
[1702419153.282357][1380:1382] CHIP:DMG: {
[1702419153.282576][1380:1382] CHIP:DMG: CommandPathIB =
[1702419153.282650][1380:1382] CHIP:DMG: {
[1702419153.282725][1380:1382] CHIP:DMG: EndpointId = 0x0,
[1702419153.282812][1380:1382] CHIP:DMG: ClusterId = 0x46,
[1702419153.282895][1380:1382] CHIP:DMG: CommandId = 0x2,
[1702419153.282973][1380:1382] CHIP:DMG: },
[1702419153.283183][1380:1382] CHIP:DMG:
[1702419153.283246][1380:1382] CHIP:DMG: StatusIB =
[1702419153.283327][1380:1382] CHIP:DMG: {
[1702419153.283409][1380:1382] CHIP:DMG: status = 0x00 (SUCCESS),
[1702419153.283490][1380:1382] CHIP:DMG: },
[1702419153.283562][1380:1382] CHIP:DMG:
[1702419153.283626][1380:1382] CHIP:DMG: },
[1702419153.283699][1380:1382] CHIP:DMG:
[1702419153.283751][1380:1382] CHIP:DMG: },
[1702419153.283811][1380:1382] CHIP:DMG:
[1702419153.283859][1380:1382] CHIP:DMG: ],
[1702419153.283919][1380:1382] CHIP:DMG:
[1702419153.283966][1380:1382] CHIP:DMG: InteractionModelRevision = 11
[1702419153.284013][1380:1382] CHIP:DMG: },
[1702419153.284182][1380:1382] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0002 Status=0x0
disabled: true
- label: "Step 2f: TH reads from the DUT the RegisteredClients attribute."
PICS: ICDM.S.A0003
verification: |
./chip-tool icdmanagement read registered-clients 1 0
[1702419210.157158][1385:1387] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0003 DataVersion: 4124981277
[1702419210.157311][1385:1387] CHIP:TOO: RegisteredClients: 1 entries
[1702419210.157489][1385:1387] CHIP:TOO: [1]: {
[1702419210.157543][1385:1387] CHIP:TOO: CheckInNodeID: 112233
[1702419210.157591][1385:1387] CHIP:TOO: MonitoredSubject: 112233
[1702419210.157662][1385:1387] CHIP:TOO: FabricIndex: 1
[1702419210.157730][1385:1387] CHIP:TOO: }
disabled: true
- label:
"Step 2g: Clear the THs administrator privileges for the ICDM cluster."
verification: |
./chip-tool accesscontrol write acl '[{"fabricIndex": 1, "privilege": 4, "authMode": 2, "subjects": [112233], "targets": null } ]' 1 0
disabled: true
- label:
"Step 3a: TH sends RegisterClient command. - CheckInNodeID:
registering clients node ID (CheckInNodeID3) - MonitoredSubject:
monitored subject ID (MonitorSubID3) - Key: shared secret between the
client and the ICD (Key3) - VerificationKey: verification key
(VerificationKey3)"
PICS: ICDM.S.C00.Rsp
verification: |
./chip-tool icdmanagement register-client 3 3 hex:3334567890abcdef3334567890abcdef 1 0 --VerificationKey hex:abcdef1234567890abcdef1234567890
[1702433488.601132][2043:2045] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0001
[1702433488.601231][2043:2045] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Command 0x0000_0001
[1702433488.601414][2043:2045] CHIP:TOO: RegisterClientResponse: {
[1702433488.601478][2043:2045] CHIP:TOO: ICDCounter: 228745926
[1702433488.601531][2043:2045] CHIP:TOO: }
disabled: true
- label: "Step 3b: TH reads from the DUT the RegisteredClients attribute."
PICS: ICDM.S.A0003
verification: |
./chip-tool icdmanagement read registered-clients 1 0
[1702433698.808800][2095:2097] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0003 DataVersion: 2083795792
[1702433698.808939][2095:2097] CHIP:TOO: RegisteredClients: 2 entries
[1702433698.809081][2095:2097] CHIP:TOO: [1]: {
[1702433698.809126][2095:2097] CHIP:TOO: CheckInNodeID: 112233
[1702433698.809167][2095:2097] CHIP:TOO: MonitoredSubject: 112233
[1702433698.809226][2095:2097] CHIP:TOO: FabricIndex: 1
[1702433698.809266][2095:2097] CHIP:TOO: }
[1702433698.809319][2095:2097] CHIP:TOO: [2]: {
[1702433698.809359][2095:2097] CHIP:TOO: CheckInNodeID: 3
[1702433698.809399][2095:2097] CHIP:TOO: MonitoredSubject: 3
[1702433698.809514][2095:2097] CHIP:TOO: FabricIndex: 1
[1702433698.809559][2095:2097] CHIP:TOO: }
disabled: true
- label:
"Step 4: TH sends RegisterClient command with same CheckInNodeID as in
Step 3a and different MonitoredSubject and Key, and an invalid
VerificationKey - CheckInNodeID: registering clients node ID
(CheckInNodeID3) - MonitoredSubject: monitored subject ID
(MonitorSubID4) - Key: shared secret between the client and the ICD
(Key4) - VerificationKey: invalid verification key (VerificationKey4)"
PICS: ICDM.S.C00.Rsp
verification: |
./chip-tool icdmanagement register-client 3 4 hex:3334567890abcdef3334567890abcdef 1 0 --VerificationKey hex:abcdef1234567890
[1703266655.434604][2378:2381] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0000 Status=0x1
[1703266655.434688][2378:2381] CHIP:TOO: Error: IM Error 0x00000501: General error: 0x01 (FAILURE)
disabled: true
- label:
"Step 5: TH sends RegisterClient command with same CheckInNodeID as in
Step 3a and different MonitoredSubject, Key, and VerificationKey -
CheckInNodeID: registering clients node ID (CheckInNodeID3) -
MonitoredSubject: monitored subject ID (MonitorSubID5) - Key: shared
secret between the client and the ICD (Key5) - VerificationKey: valid
verification key (VerificationKey5)"
PICS: ICDM.S.C00.Rsp
verification: |
./chip-tool icdmanagement register-client 3 5 hex:3334567890abcdef3334567890abcdef 1 0 --VerificationKey hex:abcdef1234567890abcdef1234500000
[1703266705.829853][2551:2553] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0000 Status=0x1
[1703266705.829994][2551:2553] CHIP:TOO: Error: IM Error 0x00000501: General error: 0x01 (FAILURE)
disabled: true
- label:
"Step 6a: TH sends RegisterClient command with same CheckInNodeID and
VerificationKey as in Step 3a and different MonitoredSubject and Key -
CheckInNodeID: registering clients node ID (CheckInNodeID3) -
MonitoredSubject: monitored subject ID (MonitorSubID6) - Key: shared
secret between the client and the ICD (Key6) - VerificationKey:
verification key (VerificationKey3)"
PICS: ICDM.S.C00.Rsp
verification: |
./chip-tool icdmanagement register-client 3 6 hex:3334567890abcdef3334567890abcdef 1 0 --VerificationKey hex:abcdef1234567890abcdef1234567890
[1703267703.849366][2694:2696] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Command 0x0000_0001
[1703267703.849532][2694:2696] CHIP:TOO: RegisterClientResponse: {
[1703267703.849587][2694:2696] CHIP:TOO: ICDCounter: 228745930
[1703267703.849633][2694:2696] CHIP:TOO: }
disabled: true
- label: "Step 6b: TH reads from the DUT the RegisteredClients attribute."
PICS: ICDM.S.A0003
verification: |
./chip-tool icdmanagement read registered-clients 1 0
[1702433698.808800][2095:2097] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0046 Attribute 0x0000_0003 DataVersion: 2083795792
[1702433698.808939][2095:2097] CHIP:TOO: RegisteredClients: 2 entries
[1702433698.809081][2095:2097] CHIP:TOO: [1]: {
[1702433698.809126][2095:2097] CHIP:TOO: CheckInNodeID: 112233
[1702433698.809167][2095:2097] CHIP:TOO: MonitoredSubject: 112233
[1702433698.809226][2095:2097] CHIP:TOO: FabricIndex: 1
[1702433698.809266][2095:2097] CHIP:TOO: }
[1702433698.809319][2095:2097] CHIP:TOO: [2]: {
[1702433698.809359][2095:2097] CHIP:TOO: CheckInNodeID: 3
[1702433698.809399][2095:2097] CHIP:TOO: MonitoredSubject: 6
[1702433698.809514][2095:2097] CHIP:TOO: FabricIndex: 1
[1702433698.809559][2095:2097] CHIP:TOO: }
disabled: true
- label:
"Step 6c: TH sends UnregisterClient command with the CheckInNodeID
(CheckInNodeID3) and VerificationKey (VerificationKey3)."
PICS: ICDM.S.C02.Rsp
verification: |
./chip-tool icdmanagement unregister-client 3 3 0
[1702419153.281757][1380:1382] CHIP:DMG: InvokeResponseMessage =
[1702419153.281885][1380:1382] CHIP:DMG: {
[1702419153.282005][1380:1382] CHIP:DMG: suppressResponse = false,
[1702419153.282061][1380:1382] CHIP:DMG: InvokeResponseIBs =
[1702419153.282126][1380:1382] CHIP:DMG: [
[1702419153.282177][1380:1382] CHIP:DMG: InvokeResponseIB =
[1702419153.282243][1380:1382] CHIP:DMG: {
[1702419153.282296][1380:1382] CHIP:DMG: CommandStatusIB =
[1702419153.282357][1380:1382] CHIP:DMG: {
[1702419153.282576][1380:1382] CHIP:DMG: CommandPathIB =
[1702419153.282650][1380:1382] CHIP:DMG: {
[1702419153.282725][1380:1382] CHIP:DMG: EndpointId = 0x0,
[1702419153.282812][1380:1382] CHIP:DMG: ClusterId = 0x46,
[1702419153.282895][1380:1382] CHIP:DMG: CommandId = 0x2,
[1702419153.282973][1380:1382] CHIP:DMG: },
[1702419153.283183][1380:1382] CHIP:DMG:
[1702419153.283246][1380:1382] CHIP:DMG: StatusIB =
[1702419153.283327][1380:1382] CHIP:DMG: {
[1702419153.283409][1380:1382] CHIP:DMG: status = 0x00 (SUCCESS),
[1702419153.283490][1380:1382] CHIP:DMG: },
[1702419153.283562][1380:1382] CHIP:DMG:
[1702419153.283626][1380:1382] CHIP:DMG: },
[1702419153.283699][1380:1382] CHIP:DMG:
[1702419153.283751][1380:1382] CHIP:DMG: },
[1702419153.283811][1380:1382] CHIP:DMG:
[1702419153.283859][1380:1382] CHIP:DMG: ],
[1702419153.283919][1380:1382] CHIP:DMG:
[1702419153.283966][1380:1382] CHIP:DMG: InteractionModelRevision = 11
[1702419153.284013][1380:1382] CHIP:DMG: },
[1702419153.284182][1380:1382] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0046 Command=0x0000_0002 Status=0x0
disabled: true