@@ -21,13 +21,6 @@ pub struct SingleSignatures {
21
21
#[ serde( rename = "indexes" ) ]
22
22
pub won_indexes : Vec < LotteryIndex > ,
23
23
24
- /// Message that is signed by the signer
25
- ///
26
- /// Used to buffer the signature for later if the aggregator has yet to create an open message
27
- /// for the signed entity type.
28
- #[ serde( skip_serializing_if = "Option::is_none" ) ]
29
- pub signed_message : Option < String > ,
30
-
31
24
/// Status of the authentication of the signer that emitted the signature
32
25
#[ serde( skip) ]
33
26
pub authentication_status : SingleSignatureAuthenticationStatus ,
@@ -54,23 +47,6 @@ impl SingleSignatures {
54
47
party_id : party_id. into ( ) ,
55
48
signature,
56
49
won_indexes,
57
- signed_message : None ,
58
- authentication_status : SingleSignatureAuthenticationStatus :: Unauthenticated ,
59
- }
60
- }
61
-
62
- /// `SingleSignatures` factory including the signed message
63
- pub fn new_with_signed_message < T : Into < PartyId > > (
64
- party_id : T ,
65
- signature : ProtocolSingleSignature ,
66
- won_indexes : Vec < LotteryIndex > ,
67
- signed_message : String ,
68
- ) -> SingleSignatures {
69
- SingleSignatures {
70
- party_id : party_id. into ( ) ,
71
- signature,
72
- won_indexes,
73
- signed_message : Some ( signed_message) ,
74
50
authentication_status : SingleSignatureAuthenticationStatus :: Unauthenticated ,
75
51
}
76
52
}
@@ -88,18 +64,10 @@ impl SingleSignatures {
88
64
89
65
cfg_test_tools ! {
90
66
impl SingleSignatures {
91
- /// Create a fake [SingleSignatures] with valid cryptographic data for testing purposes.
92
- pub fn fake<T1 : Into <String >, T2 : Into <String >>( party_id: T1 , message: T2 ) -> Self {
93
- Self {
94
- signed_message: None ,
95
- ..Self :: fake_with_signed_message( party_id, message)
96
- }
97
- }
98
-
99
67
/// Create a fake [SingleSignatures] with valid cryptographic data for testing purposes.
100
68
// TODO: this method is slow due to the fixture creation, we should either make
101
69
// the fixture faster or find a faster alternative.
102
- pub fn fake_with_signed_message <T1 : Into <String >, T2 : Into <String >>( party_id: T1 , message: T2 ) -> Self {
70
+ pub fn fake <T1 : Into <String >, T2 : Into <String >>( party_id: T1 , message: T2 ) -> Self {
103
71
use crate :: entities:: { ProtocolParameters } ;
104
72
use crate :: test_utils:: { MithrilFixtureBuilder , StakeDistributionGenerationMethod } ;
105
73
@@ -118,7 +86,6 @@ impl SingleSignatures {
118
86
party_id,
119
87
signature: signature. signature,
120
88
won_indexes: vec![ 10 , 15 ] ,
121
- signed_message: Some ( message) ,
122
89
authentication_status: SingleSignatureAuthenticationStatus :: Unauthenticated ,
123
90
}
124
91
}
@@ -131,8 +98,7 @@ impl Debug for SingleSignatures {
131
98
let mut debug = f. debug_struct ( "SingleSignatures" ) ;
132
99
debug
133
100
. field ( "party_id" , & self . party_id )
134
- . field ( "won_indexes" , & format_args ! ( "{:?}" , self . won_indexes) )
135
- . field ( "signed_message" , & self . signed_message ) ;
101
+ . field ( "won_indexes" , & format_args ! ( "{:?}" , self . won_indexes) ) ;
136
102
137
103
match is_pretty_printing {
138
104
true => debug
0 commit comments