infoservice.agreement.paxos.integration
Class Commitment

java.lang.Object
  extended by infoservice.agreement.paxos.integration.Commitment

public class Commitment
extends java.lang.Object


Field Summary
private  java.lang.String m_random
           
private  java.lang.String m_value
           
 
Constructor Summary
Commitment(java.lang.String a_value, java.lang.String a_random)
          Creates a Commitment for the given value.
 
Method Summary
 java.lang.String getCommitmentAsString()
          Returns this Commitment as String.
 java.lang.String getRevealAsString()
          Returns the Reveal as string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_value

private java.lang.String m_value

m_random

private java.lang.String m_random
Constructor Detail

Commitment

public Commitment(java.lang.String a_value,
                  java.lang.String a_random)
Creates a Commitment for the given value. The random is used to prevent codebook attacks (@see CommitmentScheme)

Parameters:
a_value -
a_random -
Method Detail

getCommitmentAsString

public java.lang.String getCommitmentAsString()
Returns this Commitment as String. The value is concatenated with the random and then hashed

Returns:

getRevealAsString

public java.lang.String getRevealAsString()
Returns the Reveal as string. The reveal is of the form \\#}\

Returns:
The Reveal as string. The reveal is of the form \\#}\