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

Set ICAC to nullable to align with spec #14411

Merged
merged 2 commits into from
Jan 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2086,7 +2086,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
2 changes: 1 addition & 1 deletion examples/bridge-app/bridge-common/bridge-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
2 changes: 1 addition & 1 deletion examples/lighting-app/lighting-common/lighting-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1080,7 +1080,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
2 changes: 1 addition & 1 deletion examples/lock-app/lock-common/lock-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
2 changes: 1 addition & 1 deletion examples/pump-app/pump-common/pump-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
2 changes: 1 addition & 1 deletion examples/thermostat/thermostat-common/thermostat.matter
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
4 changes: 2 additions & 2 deletions examples/tv-app/tv-common/tv-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1333,7 +1333,7 @@ client cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down Expand Up @@ -1431,7 +1431,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1854,7 +1854,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
2 changes: 1 addition & 1 deletion examples/window-app/common/window-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -458,7 +458,7 @@ server cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,15 @@ CHIP_ERROR OperationalCredentialsAttrAccess::ReadNOCs(EndpointId endpoint, Attri

if (accessingFabricIndex == fabricInfo.GetFabricIndex())
{
ByteSpan icac;

ReturnErrorOnFailure(fabricInfo.GetNOCCert(noc.noc));
ReturnErrorOnFailure(fabricInfo.GetICACert(noc.icac));
ReturnErrorOnFailure(fabricInfo.GetICACert(icac));

if (!icac.empty())
{
noc.icac.SetNonNull(icac);
}
}

ReturnErrorOnFailure(encoder.Encode(noc));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ limitations under the License.
<cluster code="0x003E"/>
<item name="FabricIndex" type="fabric_idx"/>
<item name="NOC" type="OCTET_STRING"/>
<item name="ICAC" type="OCTET_STRING"/>
<item name="ICAC" type="OCTET_STRING" isNullable="true"/>
</struct>

<cluster>
Expand Down
2 changes: 1 addition & 1 deletion src/controller/data_model/controller-clusters.matter
Original file line number Diff line number Diff line change
Expand Up @@ -2306,7 +2306,7 @@ client cluster OperationalCredentials = 62 {
struct NOCStruct {
fabric_idx fabricIndex = 0;
OCTET_STRING noc = 1;
OCTET_STRING icac = 2;
nullable OCTET_STRING icac = 2;
}

struct FabricDescriptor {
Expand Down
15 changes: 11 additions & 4 deletions src/controller/java/zap-generated/CHIPReadCallbacks.cpp

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/controller/python/chip/clusters/Objects.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.