Digital certificate
Nuchain supports creating digital certificate.
Certificate data in Nuchain is eternal --once it is written, it can not be erased, but the validity can still be revoked.
info
Certificate in Nuchain is platform for storage only, it is not an authority. However, the data in the blockchain, that has eternal nature, can be used to prove the existence of the certificate digitally.
#
Creating certificatesCreating certificates requires an organisation, a holder of certificate issuer. Further details about creating organisation can be found at Organisation.
The steps of creating certificates in Nuchain are:
The organisation needs to generate a certificate (as a template). The template then will be used in issuing certificates. The access of creating certificate is only available for account
admin
of the organisation and for accounts that has DId access to the organisation. Creating certificate is also possible using the extrinsic functioncertificate.create
.The organisation issues a certificate for a recipient by using extrinsic function
certificate.issue
.
#
Checking the certificatesCreated and issued certificates are written on the blockchain and its existence can be proven by
querying using the function certificate.issuedCert(ID)
.
The validity of the certificates can be proven by ensuring that
- the certificates are not revoked
- the certificates does not expire
Example of getting information of issued certificate using the javascript API:
let cert = await api.query.certificate.issuedCert("A35tYxqSP6i");
#
Revoking the certificatesThe issued certificates are able to be revoked. Revoking the certificates will make them invalid.
Use extrinsic function certificate.revoke
to revoke the certificates.
#
Expiration of certificatesIn Nuchain, the certificate issuer is able to set expiration time of the digital certificates by
filling the parameter of expired
when issuing a certificate.