iaik.xkms
Interface Authentication


public interface Authentication

Authentication for a key binding in an XKRSS request.

[277a] Clients and Responders MAY use dsig:KeyName for HMAC validation.

[291] The <Authentication> element is used to authenticate the key binding element within an XKRSS request. This may be a <PrototypeKeyBinding>, <ReissueKeyBinding>, <RevokeKeyBinding> or <RecoverKeyBinding> element depending on the type of request.

<KeyBindingAuthentication> [Optional]
Authentication of the key binding by means of a signature using a previously established key.
<NotBoundAuthentication> [Optional]
Plaintext data used to authenticate the XKRSS request that is not bound to the key binding.

XKMS Responders do not have to support both of these optional elements in a request message.


Method Summary
 String getKeyBindingAuthenticationKeyName()
          Gets key name of the KeyBindingAuthentication.
 String getNotBoundAuthenticationProtocol()
          Gets protocol of the NotBoundAuthentication.
 byte[] getNotBoundAuthenticationValue()
          Gets value of the NotBoundAuthentication.
 void setKeyBindingAuthentication(Key key, String keyname)
          Sets KeyBindingAuthentication according to the supplied values.
 void setKeyBindingAuthentication(String code, String keyname)
          Sets KeyBindingAuthentication according to the supplied passphrase.
 void setNotBoundAuthentication(String protocol, byte[] value)
          Sets NotBoundAuthentication according to the supplied values.
 

Method Detail

setKeyBindingAuthentication

void setKeyBindingAuthentication(Key key,
                                 String keyname)
Sets KeyBindingAuthentication according to the supplied values.

Parameters:
key - key to use
keyname - (optional) key name

setKeyBindingAuthentication

void setKeyBindingAuthentication(String code,
                                 String keyname)
Sets KeyBindingAuthentication according to the supplied passphrase.

Parameters:
code - passphrase to derive the KeyBindingAuthentication from
keyname - (optional) key name

getKeyBindingAuthenticationKeyName

String getKeyBindingAuthenticationKeyName()
Gets key name of the KeyBindingAuthentication.

Returns:
key name of the KeyBindingAuthentication

setNotBoundAuthentication

void setNotBoundAuthentication(String protocol,
                               byte[] value)
                               throws XKMSException
Sets NotBoundAuthentication according to the supplied values.

Parameters:
protocol - protocol to use, specified by an URI
value - value to use
Throws:
XKMSException - if the protocol is not an URI

getNotBoundAuthenticationProtocol

String getNotBoundAuthenticationProtocol()
Gets protocol of the NotBoundAuthentication.

Returns:
protocol of the NotBoundAuthentication

getNotBoundAuthenticationValue

byte[] getNotBoundAuthenticationValue()
Gets value of the NotBoundAuthentication.

Returns:
value of the NotBoundAuthentication