// Path: api/src/main/java/net/adamcin/httpsig/api/Algorithm.java
// public enum Algorithm {
//     RSA_SHA1("rsa-sha1"),
//     RSA_SHA256("rsa-sha256"),
//     RSA_SHA512("rsa-sha512"),
//     DSA_SHA1("dsa-sha1"),
//     HMAC_SHA1("hmac-sha1"),
//     HMAC_SHA256("hmac-sha256"),
//     HMAC_SHA512("hmac-sha512"),
//     SSH_RSA("ssh-rsa"),
//     SSH_DSS("ssh-dss");
// 
//     private final String name;
// 
//     private Algorithm(String name) {
//         this.name = name;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public static Algorithm forName(String name) {
//         for (Algorithm algorithm : Algorithm.values()) {
//             if (algorithm.getName().equalsIgnoreCase(name)) {
//                 return algorithm;
//             }
//         }
// 
//         return null;
//     }
// }


import java.security.InvalidKeyException;
import java.security.KeyPair;
import java.security.PrivateKey;
import java.security.PublicKey;
import java.security.Signature;
import java.security.SignatureException;
import java.util.Collections;
import java.util.LinkedHashSet;
import java.util.Set;
import net.adamcin.httpsig.api.Algorithm;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
        }
        if (keyPair.getPublic() == null) {
            throw new IllegalArgumentException("publicKey must not be null");
        }
        this.keyPair = keyPair;
        this.fingerprint = keyFormat.getFingerprint(keyPair.getPublic());
    }

    public SSHKey(KeyFormat keyFormat, PublicKey publicKey,
                  PrivateKey privateKey) {
        this(keyFormat, new KeyPair(publicKey, privateKey));
    }

    /**
     * {@inheritDoc}
     */
    public String getId() {
        return this.fingerprint;
    }

    /**
     * {@inheritDoc}
     */
    public String getFingerprint() {
        return this.fingerprint;
    }

    /**
     * {@inheritDoc}
     */
// Path: api/src/main/java/net/adamcin/httpsig/api/Algorithm.java
// public enum Algorithm {
//     RSA_SHA1("rsa-sha1"),
//     RSA_SHA256("rsa-sha256"),
//     RSA_SHA512("rsa-sha512"),
//     DSA_SHA1("dsa-sha1"),
//     HMAC_SHA1("hmac-sha1"),
//     HMAC_SHA256("hmac-sha256"),
//     HMAC_SHA512("hmac-sha512"),
//     SSH_RSA("ssh-rsa"),
//     SSH_DSS("ssh-dss");
// 
//     private final String name;
// 
//     private Algorithm(String name) {
//         this.name = name;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public static Algorithm forName(String name) {
//         for (Algorithm algorithm : Algorithm.values()) {
//             if (algorithm.getName().equalsIgnoreCase(name)) {
//                 return algorithm;
//             }
//         }
// 
//         return null;
//     }
// }


// Path: ssh-jce/src/main/java/net/adamcin/httpsig/ssh/jce/SSHKey.java
import java.security.InvalidKeyException;
import java.security.KeyPair;
import java.security.PrivateKey;
import java.security.PublicKey;
import java.security.Signature;
import java.security.SignatureException;
import java.util.Collections;
import java.util.LinkedHashSet;
import java.util.Set;
import net.adamcin.httpsig.api.Algorithm;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

        }
        if (keyPair.getPublic() == null) {
            throw new IllegalArgumentException("publicKey must not be null");
        }
        this.keyPair = keyPair;
        this.fingerprint = keyFormat.getFingerprint(keyPair.getPublic());
    }

    public SSHKey(KeyFormat keyFormat, PublicKey publicKey,
                  PrivateKey privateKey) {
        this(keyFormat, new KeyPair(publicKey, privateKey));
    }

    /**
     * {@inheritDoc}
     */
    public String getId() {
        return this.fingerprint;
    }

    /**
     * {@inheritDoc}
     */
    public String getFingerprint() {
        return this.fingerprint;
    }

    /**
     * {@inheritDoc}
     */
    public Set<Algorithm> getAlgorithms() {