@@ -184,6 +184,9 @@ pub trait Api {
184
184
recovery_param : u8 ,
185
185
) -> Result < Vec < u8 > , RecoverPubkeyError > ;
186
186
187
+ /// Add up points of the G1 subgroup on the BLS12-381 curve
188
+ ///
189
+ /// The length of `g1s` must be a multiple of 48 (each point is encoded in 48 bytes).
187
190
#[ allow( unused_variables) ]
188
191
fn bls12_381_aggregate_g1 ( & self , g1s : & [ u8 ] ) -> Result < [ u8 ; 48 ] , VerificationError > {
189
192
// Support for BLS12-381 is added in 2.1, i.e. we can't add a compile time requirement for new function.
@@ -193,6 +196,9 @@ pub trait Api {
193
196
unimplemented ! ( )
194
197
}
195
198
199
+ /// Add up points of the G2 subgroup on the BLS12-381 curve
200
+ ///
201
+ /// The length of `g2s` must be a multiple of 96 (each point is encoded in 96 bytes)
196
202
#[ allow( unused_variables) ]
197
203
fn bls12_381_aggregate_g2 ( & self , g2s : & [ u8 ] ) -> Result < [ u8 ; 96 ] , VerificationError > {
198
204
// Support for BLS12-381 is added in 2.1, i.e. we can't add a compile time requirement for new function.
@@ -243,6 +249,9 @@ pub trait Api {
243
249
unimplemented ! ( )
244
250
}
245
251
252
+ /// Take some arbitrary data and hash it to a point on the G1 subgroup of the curve.
253
+ ///
254
+ /// The `dst` parameter should be a constant is actually something similar to the "context" parameter in key derivation functions.
246
255
#[ allow( unused_variables) ]
247
256
fn bls12_381_hash_to_g1 (
248
257
& self ,
@@ -257,6 +266,9 @@ pub trait Api {
257
266
unimplemented ! ( )
258
267
}
259
268
269
+ /// Take some arbitrary data and hash it to a point on the G2 subgroup of the curve.
270
+ ///
271
+ /// The `dst` parameter should be a constant is actually something similar to the "context" parameter in key derivation functions.
260
272
#[ allow( unused_variables) ]
261
273
fn bls12_381_hash_to_g2 (
262
274
& self ,
0 commit comments