Class OwnedIdentity

    • Constructor Detail

      • OwnedIdentity

        public OwnedIdentity​(java.security.cert.Certificate[] chain,
                             java.security.PrivateKey privateKey)
        Creates new owned identity from given chain of x.509 certificates.

        The certificate at index 0 must represent the identity of a system, the certificate at index 1 the identity of a cloud, while all subsequent certificates constitute their chain of issuers. The certificates, including the first two, must be in order in the sense that the certificate at index n must be issued by the certificate at index n + 1.

        Parameters:
        chain - x.509 certificate chain belonging to an Arrowhead system.
        privateKey - Private key associated with the system certificate.
        Throws:
        java.lang.NullPointerException - If chain is null.
        java.lang.IllegalArgumentException - If chain.length == 0, if chain contains any other type of certificate than X509Certificate, or if the subject common name of the certificate at index 0 is not a valid Arrowhead system certificate name.
        See Also:
        Class description for details on valid names.
      • OwnedIdentity

        public OwnedIdentity​(java.security.cert.X509Certificate[] chain,
                             java.security.PrivateKey privateKey)
        Creates new system identity from given chain of x.509 certificates.

        The certificate at index 0 must represent the identity of a system, the certificate at index 1 the identity of a cloud, while all subsequent certificates constitute their chain of issuers. The certificates, including the first two, must be in order in the sense that the certificate at index n must be issued by the certificate at index n + 1.

        Parameters:
        chain - x.509 certificate chain belonging to an Arrowhead system.
        privateKey - Private key associated with the system certificate.
        Throws:
        java.lang.NullPointerException - If chain is null.
        java.lang.IllegalArgumentException - If chain.length == 0 or if the subject common name of the certificate at index 0 is not a valid Arrowhead system certificate name.
        See Also:
        Class description for details on valid names.
      • OwnedIdentity

        public OwnedIdentity​(SystemIdentity identity,
                             java.security.PrivateKey privateKey)
        Promotes given identity to an OwnedIdentity.

        The promotion will succeed only if the certificate of the given identity contains an Arrowhead-compliant subject common name.

        Parameters:
        identity - Identity to promote.
        privateKey - Private key associated with system certificate.
        Throws:
        java.lang.IllegalArgumentException - If given identity does not satisfy the Arrowhead naming requirements.
        See Also:
        Class description for details on valid names.
      • OwnedIdentity

        public OwnedIdentity​(TrustedIdentity identity,
                             java.security.PrivateKey privateKey)
        Promotes given identity to an OwnedIdentity.

        The promotion will succeed only if the certificate of the given identity contains an Arrowhead-compliant subject common name.

        Parameters:
        identity - Identity to promote.
        privateKey - Private key associated with system certificate.
        Throws:
        java.lang.IllegalArgumentException - If given identity does not satisfy the Arrowhead naming requirements.
        See Also:
        Class description for details on valid names.
    • Method Detail

      • privateKey

        public java.security.PrivateKey privateKey()
        Returns:
        Private key associated key store system.