com.sshtools.j2ssh.transport.publickey

Class OpenSSHPublicKeyFormat

Implemented Interfaces:
SshPublicKeyFormat

public class OpenSSHPublicKeyFormat
extends java.lang.Object
implements SshPublicKeyFormat

Version:
$Revision: 1.19 $
Author:
$author$

Constructor Summary

OpenSSHPublicKeyFormat()
Creates a new OpenSSHPublicKeyFormat object.
OpenSSHPublicKeyFormat(String comment)
Creates a new OpenSSHPublicKeyFormat object.

Method Summary

byte[]
formatKey(byte[] keyblob)
String
getComment()
String
getFormatType()
byte[]
getKeyBlob(byte[] formattedKey)
boolean
isFormatted(byte[] formattedKey)
void
setComment(String comment)
boolean
supportsAlgorithm(String algorithm)

Constructor Details

OpenSSHPublicKeyFormat

public OpenSSHPublicKeyFormat()
Creates a new OpenSSHPublicKeyFormat object.

OpenSSHPublicKeyFormat

public OpenSSHPublicKeyFormat(String comment)
Creates a new OpenSSHPublicKeyFormat object.
Parameters:
comment -

Method Details

formatKey

public byte[] formatKey(byte[] keyblob)
Specified by:
formatKey in interface SshPublicKeyFormat
Parameters:
keyblob -
Returns:

getComment

public String getComment()
Specified by:
getComment in interface SshPublicKeyFormat
Returns:

getFormatType

public String getFormatType()
Specified by:
getFormatType in interface SshPublicKeyFormat
Returns:

getKeyBlob

public byte[] getKeyBlob(byte[] formattedKey)
            throws InvalidSshKeyException
Specified by:
getKeyBlob in interface SshPublicKeyFormat
Parameters:
formattedKey -
Returns:

isFormatted

public boolean isFormatted(byte[] formattedKey)
Specified by:
isFormatted in interface SshPublicKeyFormat
Parameters:
formattedKey -
Returns:

setComment

public void setComment(String comment)
Specified by:
setComment in interface SshPublicKeyFormat
Parameters:
comment -

supportsAlgorithm

public boolean supportsAlgorithm(String algorithm)
Specified by:
supportsAlgorithm in interface SshPublicKeyFormat
Parameters:
algorithm -
Returns:

Copyright © 2002-2003 Lee David Painter & Contributors. All Rights Reserved.