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

Certificate declaration version number should be uint16 #425

Open
samadDotDev opened this issue Dec 6, 2022 · 0 comments
Open

Certificate declaration version number should be uint16 #425

samadDotDev opened this issue Dec 6, 2022 · 0 comments

Comments

@samadDotDev
Copy link

The certificate declaration version number is defined as uint16 in the Matter spec. This is pretty critical since the value is encoded as a smaller type in Certificate Declaration TLV:

certification-elements => STRUCTURE [ tag-order ]
{
    format_version [0]       : UNSIGNED INTEGER [ range 16-bits ]
    vendor_id [1]            : UNSIGNED INTEGER [ range 16-bits ]
    product_id_array [2]     : ARRAY [ length 1..100 ] OF UNSIGNED INTEGER [ range 16-bits ]
    device_type_id [3]       : UNSIGNED INTEGER [ range 32-bits ]
    certificate_id [4]       : STRING [ length 19 ]
    security_level [5]       : UNSIGNED INTEGER [ range 8-bits ]
    security_information [6] : UNSIGNED INTEGER [ range 16-bits ]
    version_number [7]       : UNSIGNED INTEGER [ range 16-bits ]
    certification_type [8]   : UNSIGNED INTEGER [ range 8-bits]
    dac_origin_vendor_id [9, optional]   : UNSIGNED INTEGER [ range 16-bits ]
    dac_origin_product_id [10, optional] : UNSIGNED INTEGER [ range 16-bits ]
    authorized_paa_list [11, optional]   : ARRAY [ length 1..10 ] OF OCTET STRING [ length 20 ]
}

On DCL however, it is declared as a mix of different types:

On the documentation, it is specified as uint32: https://github.com/zigbee-alliance/distributed-compliance-ledger/blob/master/docs/transactions.md#add_model_version

And the typescript / go syntax specifies it as int32:

CC: @msandstedt, @Con-Tejus

@ashcherbakov ashcherbakov modified the milestone: v1.3: DCL 1.3 Nov 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants