/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.lightsail.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *

* Describes the public SSH host keys or the RDP certificate. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class HostKeyAttributes implements Serializable, Cloneable, StructuredPojo { /** *

* The SSH host key algorithm or the RDP certificate format. *

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. *

*/ private String algorithm; /** *

* The public SSH host key or the RDP certificate. *

*/ private String publicKey; /** *

* The time that the SSH host key or RDP certificate was recorded by Lightsail. *

*/ private java.util.Date witnessedAt; /** *

* The SHA-1 fingerprint of the returned SSH host key or RDP certificate. *

* */ private String fingerprintSHA1; /** *

* The SHA-256 fingerprint of the returned SSH host key or RDP certificate. *

* */ private String fingerprintSHA256; /** *

* The returned RDP certificate is valid after this point in time. *

*

* This value is listed only for RDP certificates. *

*/ private java.util.Date notValidBefore; /** *

* The returned RDP certificate is not valid after this point in time. *

*

* This value is listed only for RDP certificates. *

*/ private java.util.Date notValidAfter; /** *

* The SSH host key algorithm or the RDP certificate format. *

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. *

* * @param algorithm * The SSH host key algorithm or the RDP certificate format.

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. */ public void setAlgorithm(String algorithm) { this.algorithm = algorithm; } /** *

* The SSH host key algorithm or the RDP certificate format. *

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. *

* * @return The SSH host key algorithm or the RDP certificate format.

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. */ public String getAlgorithm() { return this.algorithm; } /** *

* The SSH host key algorithm or the RDP certificate format. *

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. *

* * @param algorithm * The SSH host key algorithm or the RDP certificate format.

*

* For SSH host keys, the algorithm may be ssh-rsa, ecdsa-sha2-nistp256, * ssh-ed25519, etc. For RDP certificates, the algorithm is always x509-cert. * @return Returns a reference to this object so that method calls can be chained together. */ public HostKeyAttributes withAlgorithm(String algorithm) { setAlgorithm(algorithm); return this; } /** *

* The public SSH host key or the RDP certificate. *

* * @param publicKey * The public SSH host key or the RDP certificate. */ public void setPublicKey(String publicKey) { this.publicKey = publicKey; } /** *

* The public SSH host key or the RDP certificate. *

* * @return The public SSH host key or the RDP certificate. */ public String getPublicKey() { return this.publicKey; } /** *

* The public SSH host key or the RDP certificate. *

* * @param publicKey * The public SSH host key or the RDP certificate. * @return Returns a reference to this object so that method calls can be chained together. */ public HostKeyAttributes withPublicKey(String publicKey) { setPublicKey(publicKey); return this; } /** *

* The time that the SSH host key or RDP certificate was recorded by Lightsail. *

* * @param witnessedAt * The time that the SSH host key or RDP certificate was recorded by Lightsail. */ public void setWitnessedAt(java.util.Date witnessedAt) { this.witnessedAt = witnessedAt; } /** *

* The time that the SSH host key or RDP certificate was recorded by Lightsail. *

* * @return The time that the SSH host key or RDP certificate was recorded by Lightsail. */ public java.util.Date getWitnessedAt() { return this.witnessedAt; } /** *

* The time that the SSH host key or RDP certificate was recorded by Lightsail. *

* * @param witnessedAt * The time that the SSH host key or RDP certificate was recorded by Lightsail. * @return Returns a reference to this object so that method calls can be chained together. */ public HostKeyAttributes withWitnessedAt(java.util.Date witnessedAt) { setWitnessedAt(witnessedAt); return this; } /** *

* The SHA-1 fingerprint of the returned SSH host key or RDP certificate. *

* * * @param fingerprintSHA1 * The SHA-1 fingerprint of the returned SSH host key or RDP certificate.

*