net.ripe.rpki.commons.crypto.util
Class KeyPairUtil

java.lang.Object
  extended by net.ripe.rpki.commons.crypto.util.KeyPairUtil

public final class KeyPairUtil
extends Object


Nested Class Summary
static class KeyPairUtil.FileSystemSafeBase64UrlEncoder
           
 
Method Summary
static String base64UrlEncode(byte[] data)
           
static String getAsciiHexEncodedPublicKeyHash(PublicKey publicKey)
          Get ASCII Hex encoded hash of the public key; for use in certificate subjects as described here: http://tools.ietf.org/html/draft-ietf-sidr-res-certs-21#section-8
static String getEncodedKeyIdentifier(PublicKey key)
          Get Base64 encoded public key as string.
static byte[] getKeyIdentifier(PublicKey key)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getEncodedKeyIdentifier

public static String getEncodedKeyIdentifier(PublicKey key)
Get Base64 encoded public key as string. Primarily for generating filenames and transferring public keys across the wire.. Not fit for decoding: strips the trailing '=' characters!


getAsciiHexEncodedPublicKeyHash

public static String getAsciiHexEncodedPublicKeyHash(PublicKey publicKey)
Get ASCII Hex encoded hash of the public key; for use in certificate subjects as described here: http://tools.ietf.org/html/draft-ietf-sidr-res-certs-21#section-8


getKeyIdentifier

public static byte[] getKeyIdentifier(PublicKey key)

base64UrlEncode

public static String base64UrlEncode(byte[] data)


Copyright © 2008-2012 RIPE NCC, the Netherlands. All Rights Reserved.