code: def make_certificate_authority(**name):
    
    key = make_pkey()
    csr = make_certificate_signing_request(key, **name)
    crt = make_certificate(csr, key, csr, make_serial(), 0, 10 * 365 * 24 * 60 * 60, exts=[crypto.X509Extension(b'basicConstraints', True, b'CA:TRUE')])
    return key, crt
docs: Make a certificate authority.
  
    A certificate authority can sign certificates. For clients to be able to
    validate certificates signed by your certificate authorithy, they must trust
    the certificate returned by this function.
  
    :param name: Key word arguments containing subject name parts: C, ST, L, O,
      OU, CN.
    :return: A root self-signed certificate to act as an authority.
    :rtype: :class:`OpenSSL.crypto.X509`