Skip to content

Commit

Permalink
make SD::verify_previous_owner_signatures public
Browse files Browse the repository at this point in the history
Signed-off-by: Benjamin Bollen <benjamin.bollen@maidsafe.net>
  • Loading branch information
Benjamin Bollen committed Aug 18, 2015
1 parent e746a15 commit d892eb2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/structured_data.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ impl StructuredData {
}

/// Confirms *unique and valid* owner_signatures are at least 50% of total owners
fn verify_previous_owner_signatures(&self, owner_keys: &Vec<crypto::sign::PublicKey>) -> Result<(), RoutingError> {
pub fn verify_previous_owner_signatures(&self, owner_keys: &Vec<crypto::sign::PublicKey>) -> Result<(), RoutingError> {
// Refuse any duplicate previous_owner_signatures (people can have many owner keys)
// Any duplicates invalidates this type
if self.previous_owner_signatures.iter().filter(|&sig| self.previous_owner_signatures.iter()
Expand Down Expand Up @@ -141,7 +141,7 @@ impl StructuredData {
Ok(())
}

fn data_to_sign(&self) -> Result<Vec<u8>, RoutingError> {
pub fn data_to_sign(&self) -> Result<Vec<u8>, RoutingError> {
// seems overkill to use serialisation here, but done
// to ensure cross platform signature handling is OK
let mut enc = cbor::Encoder::from_memory();
Expand Down

0 comments on commit d892eb2

Please sign in to comment.