The version file information is obtained by parsing the bootstrapping data, which consists of the conveyed information, ownership voucher, and owner certificate. As such, the bootstrapping data can be regarded as the key data for implementing SZTP.
Conveyed information consists of the redirect information and onboarding information.
<?xml version="1.0" encoding="utf-8"?>
<conveyed-information
xmlns="urn:ietf:params:xml:ns:yang:ietf-sztp-conveyed-info">
<redirect-information>
<bootstrap-server>
<address>192.168.1.2</address> //Indicates the IP address of the bootstrap server.
<trust-anchor>base64encodedvalue==</trust-anchor> //Indicates the trust anchor certificate of the redirect server. This parameter is optional.
</bootstrap-server>
<bootstrap-server>
<address>192.168.1.3</address>
<port>445</port> //Indicates the port number of the bootstrap server. This parameter is optional, and the default value is 443.
<trust-anchor>base64encodedvalue==</trust-anchor>
</bootstrap-server>
<bootstrap-server>
<address>huawei.com</address>
<port>446</port>
</bootstrap-server>
</redirect-information>
</conveyed-information>
<?xml version="1.0" encoding="utf-8"?>
<conveyed-information xmlns="urn:ietf:params:xml:ns:yang:ietf-sztp-conveyed-info">
<onboarding-information>
<boot-image>
<download-uri>https://10.1.1.1/path/image/file.cc</download-uri> //Indicates the address for downloading version files. Currently, version files can be downloaded only through HTTPS.
<download-uri>https://10.1.1.1/path/image/file.pat</download-uri>
<download-uri>https://10.1.1.1/path/config/file.cfg</download-uri>
<image-verification> //Indicates that version files are verified. Each version file corresponds to a <download-uri>.
<hash-algorithm>ietf-sztp-conveyed-info:sha-256</hash-algorithm> //Indicates the hash algorithm type. Currently, only SHA256 is supported.
<hash-value>xxxxxx</hash-value> //Indicates the hash value.
</image-verification>
<image-verification>
<hash-algorithm>ietf-sztp-conveyed-info:sha-256</hash-algorithm>
<hash-value>xxxxxx</hash-value>
</image-verification>
<image-verification>
<hash-algorithm>ietf-sztp-conveyed-info:sha-256</hash-algorithm>
<hash-value>xxxxxx</hash-value>
</image-verification>
</boot-image>
<configuration-handling>replace</configuration-handling> //Indicates the mode of processing configuration files. Currently, configuration files can only be replaced.
</onboarding-information>
</conveyed-information>
Redirect information redirects a device to another bootstrap server to obtain onboarding information. In load balancing or multi-vendor interworking scenarios, the device may need to perform redirection.
Before a device is delivered, it is configured with an IDevID. The IDevID contains information such as the ESN of the device and the public key of the identity certificate, and enables an SZTP-enabled device to establish a TLS connection with the bootstrap server. If a device does not contain a user's trusted root certificate, the device can use the ownership voucher and owner certificate to establish a secure chain of trust so that it can verify the conveyed information.
The process of issuing the ownership voucher is as follows: