Skip to content

Commit 25a5f99

Browse files
committed
./alchemy zap --attribute="in-progress" --sdkRoot=[] --specRoot=[] 'TLSCertificateManagement.adoc'
./alchemy zap --attribute="in-progress" --sdkRoot=[] --specRoot=[] 'TLSClientManagement.adoc' With manual edits adding description
1 parent 2af51b0 commit 25a5f99

File tree

7 files changed

+718
-141
lines changed

7 files changed

+718
-141
lines changed

.github/workflows/tests.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,8 @@ jobs:
195195
src/app/zap-templates/zcl/data-model/chip/time-format-localization-cluster.xml \
196196
src/app/zap-templates/zcl/data-model/chip/time-synchronization-cluster.xml \
197197
src/app/zap-templates/zcl/data-model/chip/timer-cluster.xml \
198+
src/app/zap-templates/zcl/data-model/chip/tls-certificate-management-cluster.xml \
199+
src/app/zap-templates/zcl/data-model/chip/tls-client-management-cluster.xml \
198200
src/app/zap-templates/zcl/data-model/chip/user-label-cluster.xml \
199201
src/app/zap-templates/zcl/data-model/chip/unit-localization-cluster.xml \
200202
src/app/zap-templates/zcl/data-model/chip/wake-on-lan-cluster.xml \

scripts/rules.matterlint

+2
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@ load "../src/app/zap-templates/zcl/data-model/chip/thread-network-directory-clus
103103
load "../src/app/zap-templates/zcl/data-model/chip/time-format-localization-cluster.xml";
104104
load "../src/app/zap-templates/zcl/data-model/chip/time-synchronization-cluster.xml";
105105
load "../src/app/zap-templates/zcl/data-model/chip/timer-cluster.xml";
106+
load "../src/app/zap-templates/zcl/data-model/chip/tls-certificate-management-cluster.xml";
107+
load "../src/app/zap-templates/zcl/data-model/chip/tls-client-management-cluster.xml";
106108
load "../src/app/zap-templates/zcl/data-model/chip/unit-localization-cluster.xml";
107109
load "../src/app/zap-templates/zcl/data-model/chip/user-label-cluster.xml";
108110
load "../src/app/zap-templates/zcl/data-model/chip/wake-on-lan-cluster.xml";
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,142 @@
1+
<?xml version="1.0"?>
2+
<!--
3+
Copyright (c) 2024 Project CHIP Authors
4+
5+
Licensed under the Apache License, Version 2.0 (the "License");
6+
you may not use this file except in compliance with the License.
7+
You may obtain a copy of the License at
8+
9+
http://www.apache.org/licenses/LICENSE-2.0
10+
11+
Unless required by applicable law or agreed to in writing, software
12+
distributed under the License is distributed on an "AS IS" BASIS,
13+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
See the License for the specific language governing permissions and
15+
limitations under the License.
16+
-->
17+
<!--
18+
XML generated by Alchemy; DO NOT EDIT.
19+
Source: src/tls/TLSCertificateManagement.adoc
20+
Parameters: in-progress
21+
Git: 1.4-282-gad46b0990
22+
-->
23+
<configurator xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../zcl.xsd">
24+
<domain name="General"/>
25+
<struct name="TLSCertStruct" apiMaturity="provisional">
26+
<cluster code="0x0801"/>
27+
<item fieldId="0" name="CAID" type="int16u"/>
28+
<item fieldId="1" name="Certificate" type="long_octet_string" length="3000"/>
29+
</struct>
30+
31+
<struct name="TLSClientCertificateDetailStruct" apiMaturity="provisional">
32+
<cluster code="0x0801"/>
33+
<item fieldId="0" name="CCDID" type="int16u"/>
34+
<item fieldId="1" name="ClientCertificate" type="long_octet_string" length="3000"/>
35+
<item fieldId="2" name="IntermediateCerts" array="true" type="octet_string"/>
36+
</struct>
37+
38+
<cluster>
39+
<domain name="General"/>
40+
<name>TLS Certificate Management</name>
41+
<code>0x0801</code>
42+
<define>TLS_CERTIFICATE_MANAGEMENT_CLUSTER</define>
43+
<description>This Cluster is used to manage TLS Client Certificates and to provision
44+
TLS endpoints with enough information to facilitate subsequent connection.</description>
45+
<client init="false" tick="false">true</client>
46+
<server init="false" tick="false">true</server>
47+
<globalAttribute code="0xFFFD" side="either" value="1"/>
48+
<attribute code="0x0000" side="server" define="MAX_ROOT_CERTIFICATES" type="int8u">MaxRootCertificates</attribute>
49+
<attribute code="0x0001" side="server" define="CURRENT_ROOT_CERTIFICATES" type="int8u">CurrentRootCertificates</attribute>
50+
<attribute code="0x0002" side="server" define="MAX_CLIENT_CERTIFICATES" type="int8u">MaxClientCertificates</attribute>
51+
<attribute code="0x0003" side="server" define="CURRENT_CLIENT_CERTIFICATES" type="int8u">CurrentClientCertificates</attribute>
52+
<command code="0x00" source="client" name="ProvisionRootCertificate" optional="false" response="ProvisionRootCertificateResponse">
53+
<description>This command SHALL provision the provided certificate for the passed in CAID.</description>
54+
<access op="invoke" privilege="administer"/>
55+
<arg id="0" name="Certificate" type="long_octet_string" length="3000"/>
56+
<arg id="1" name="CAID" type="int16u" optional="true" isNullable="true"/>
57+
</command>
58+
59+
<command code="0x01" source="server" name="ProvisionRootCertificateResponse" optional="false" disableDefaultResponse="true">
60+
<description>This command SHALL be generated in response to a ProvisionRootCertificate command.</description>
61+
<arg id="0" name="CAID" type="int16u"/>
62+
</command>
63+
64+
<command code="0x02" source="client" name="FindRootCertificate" optional="false" response="FindRootCertificateResponse">
65+
<description>This command SHALL return the TLSCertStruct for the passed in CAID.</description>
66+
<arg id="0" name="CAID" type="int16u" optional="true" isNullable="true"/>
67+
</command>
68+
69+
<command code="0x03" source="server" name="FindRootCertificateResponse" optional="false" disableDefaultResponse="true">
70+
<description>This command SHALL be generated in response to a FindRootCertificate command.</description>
71+
<arg id="0" name="CertificateDetails" array="true" type="TLSCertStruct"/>
72+
</command>
73+
74+
<command code="0x04" source="client" name="LookupRootCertificate" optional="false" response="LookupRootCertificateResponse">
75+
<description>This command SHALL return the CAID for the passed in fingerprint.</description>
76+
<arg id="0" name="Fingerprint" type="octet_string" length="64"/>
77+
</command>
78+
79+
<command code="0x05" source="server" name="LookupRootCertificateResponse" optional="false" disableDefaultResponse="true">
80+
<description>This command SHALL be generated in response to a LookupRootCertificate command.</description>
81+
<arg id="0" name="CAID" type="int16u"/>
82+
</command>
83+
84+
<command code="0x06" source="client" name="RemoveRootCertificate" optional="false">
85+
<description>This command SHALL be generated to request the server removes the certificate provisioned to the provided Certificate Authority ID.</description>
86+
<access op="invoke" privilege="administer"/>
87+
<arg id="0" name="CAID" type="int16u"/>
88+
</command>
89+
90+
<command code="0x07" source="client" name="TLSClientCSR" optional="false" response="TLSClientCSRResponse">
91+
<description>This command SHALL be generated to request the Node generates a Certificate Signing Request.</description>
92+
<access op="invoke" privilege="administer"/>
93+
<arg id="1" name="Nonce" type="octet_string"/>
94+
</command>
95+
96+
<command code="0x08" source="server" name="TLSClientCSRResponse" optional="false" disableDefaultResponse="true">
97+
<description>This command SHALL be generated in response to a TLSClientCSR command.</description>
98+
<arg id="0" name="CCDID" type="int16u"/>
99+
<arg id="1" name="CSR" type="octet_string"/>
100+
<arg id="2" name="Nonce" type="octet_string"/>
101+
</command>
102+
103+
<command code="0x09" source="client" name="ProvisionClientCertificate" optional="false" response="ProvisionClientCertificateResponse">
104+
<description>This command SHALL be generated to request the Node provisions the provided Client Certificate Details.</description>
105+
<access op="invoke" privilege="administer"/>
106+
<arg id="0" name="CCDID" type="int16u"/>
107+
<arg id="1" name="ClientCertificateDetails" type="TLSClientCertificateDetailStruct"/>
108+
</command>
109+
110+
<command code="0x0A" source="server" name="ProvisionClientCertificateResponse" optional="false" disableDefaultResponse="true">
111+
<description>This command SHALL be generated in response to a ProvisionClientCertificate command.</description>
112+
<arg id="0" name="CCDID" type="int16u"/>
113+
</command>
114+
115+
<command code="0x0B" source="client" name="FindClientCertificate" optional="false" response="FindClientCertificateResponse">
116+
<description>This command SHALL return the TLSClientCertificateDetailStruct for the passed in CCDID.</description>
117+
<arg id="0" name="CCDID" type="int16u"/>
118+
</command>
119+
120+
<command code="0x0C" source="server" name="FindClientCertificateResponse" optional="false" disableDefaultResponse="true">
121+
<description>This command SHALL be generated in response to a FindClientCertificate command.</description>
122+
<arg id="0" name="CertificateDetails" array="true" type="TLSClientCertificateDetailStruct"/>
123+
</command>
124+
125+
<command code="0x0D" source="client" name="LookupClientCertificate" optional="false" response="LookupClientCertificateResponse">
126+
<description>This command SHALL return the CCDID for the passed in Fingerprint.</description>
127+
<arg id="0" name="Fingerprint" type="octet_string" length="64"/>
128+
</command>
129+
130+
<command code="0x0E" source="server" name="LookupClientCertificateResponse" optional="false" disableDefaultResponse="true">
131+
<description>This command SHALL be generated in response to a LookupClientCertificate command.</description>
132+
<arg id="0" name="CCDID" type="int16u"/>
133+
</command>
134+
135+
<command code="0x0F" source="client" name="RemoveClientCertificate" optional="false">
136+
<description>This command SHALL be generated to request the Node removes the certificate provisioned to the provided Client Certificate Details ID.</description>
137+
<access op="invoke" privilege="administer"/>
138+
<arg id="0" name="CCDID" type="int16u"/>
139+
</command>
140+
141+
</cluster>
142+
</configurator>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
<?xml version="1.0"?>
2+
<!--
3+
Copyright (c) 2024 Project CHIP Authors
4+
5+
Licensed under the Apache License, Version 2.0 (the "License");
6+
you may not use this file except in compliance with the License.
7+
You may obtain a copy of the License at
8+
9+
http://www.apache.org/licenses/LICENSE-2.0
10+
11+
Unless required by applicable law or agreed to in writing, software
12+
distributed under the License is distributed on an "AS IS" BASIS,
13+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
See the License for the specific language governing permissions and
15+
limitations under the License.
16+
-->
17+
<!--
18+
XML generated by Alchemy; DO NOT EDIT.
19+
Source: src/tls/TLSClientManagement.adoc
20+
Parameters: in-progress
21+
Git: 1.4-282-gad46b0990
22+
-->
23+
<configurator xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../zcl.xsd">
24+
<domain name="General"/>
25+
<enum name="TLSEndpointStatusEnum" type="enum8">
26+
<cluster code="0x0802"/>
27+
<item name="Provisioned" value="0x00"/>
28+
<item name="InUse" value="0x01"/>
29+
</enum>
30+
31+
<struct name="TLSEndpointStruct" apiMaturity="provisional">
32+
<cluster code="0x0802"/>
33+
<item fieldId="0" name="EndpointID" type="int16u"/>
34+
<item fieldId="1" name="Hostname" type="octet_string"/>
35+
<item fieldId="2" name="Port" type="int16u"/>
36+
<item fieldId="3" name="CAID" type="int16u"/>
37+
<item fieldId="4" name="CCDID" type="int16u" isNullable="true" optional="true"/>
38+
<item fieldId="5" name="Status" type="TLSEndpointStatusEnum" min="0x00" max="0x01"/>
39+
</struct>
40+
41+
<cluster>
42+
<domain name="General"/>
43+
<name>TLS Client Management</name>
44+
<code>0x0802</code>
45+
<define>TLS_CLIENT_MANAGEMENT_CLUSTER</define>
46+
<description>This Cluster is used to provision TLS Endpoints with enough information to facilitate subsequent connection.</description>
47+
<client init="false" tick="false">true</client>
48+
<server init="false" tick="false">true</server>
49+
<globalAttribute code="0xFFFD" side="either" value="1"/>
50+
<attribute code="0x0000" side="server" define="MAX_PROVISIONED" type="int8u">MaxProvisioned</attribute>
51+
<attribute code="0x0001" side="server" define="CURRENT_PROVISIONED" type="int8u">CurrentProvisioned</attribute>
52+
<attribute code="0x0002" side="server" define="MAX_IN_USE" type="int8u">MaxInUse</attribute>
53+
<attribute code="0x0003" side="server" define="CURRENT_IN_USE" type="int8u">CurrentInUse</attribute>
54+
<command code="0x00" source="client" name="ProvisionEndpoint" optional="false" response="ProvisionEndpointResponse">
55+
<description>This command SHALL provision a TLS Endpoint for the provided HostName / Port combination.</description>
56+
<access op="invoke" privilege="administer"/>
57+
<arg id="0" name="Hostname" type="octet_string"/>
58+
<arg id="1" name="Port" type="int16u"/>
59+
<arg id="2" name="CAID" type="int16u"/>
60+
<arg id="3" name="CCDID" type="int16u" optional="true" isNullable="true"/>
61+
<arg id="4" name="EndpointID" type="int16u" optional="true" isNullable="true"/>
62+
</command>
63+
64+
<command code="0x01" source="server" name="ProvisionEndpointResponse" optional="false" disableDefaultResponse="true">
65+
<description>This command SHALL be generated in response to a ProvisionEndpointRequest command.</description>
66+
<arg id="0" name="EndpointID" type="int16u"/>
67+
</command>
68+
69+
<command code="0x02" source="client" name="FindEndpoint" optional="false" response="FindEndpointResponse">
70+
<description>This command SHALL return the TLS Endpoint details for the passed in EndpointID.</description>
71+
<arg id="0" name="EndpointID" type="int16u" optional="true" isNullable="true"/>
72+
</command>
73+
74+
<command code="0x03" source="server" name="FindEndpointResponse" optional="false" disableDefaultResponse="true">
75+
<description>This command SHALL be generated in response to a FindEndpointRequest command.</description>
76+
<arg id="0" name="Endpoints" array="true" type="TLSEndpointStruct"/>
77+
</command>
78+
79+
<command code="0x04" source="client" name="RemoveEndpoint" optional="false">
80+
<description>This command SHALL be generated to request the Node terminates the TLS Connection.</description>
81+
<access op="invoke" privilege="administer"/>
82+
<arg id="0" name="EndpointID" type="int16u"/>
83+
</command>
84+
85+
<event code="0x0000" name="EndpointProvisioned" priority="info" side="server">
86+
<field id="0" name="EndpointID" type="int16u"/>
87+
<description>This event SHALL indicate a new TLS Endpoint has been provisioned.</description>
88+
</event>
89+
90+
<event code="0x0001" name="EndpointRemoved" priority="info" side="server">
91+
<description/>
92+
</event>
93+
94+
</cluster>
95+
</configurator>

0 commit comments

Comments
 (0)