@@ -1604,27 +1604,32 @@ async fn command_transfer(
1604
1604
. unwrap ( ) ;
1605
1605
1606
1606
// setup proofs
1607
+ let create_range_proof_context_signer = & [ & range_proof_context_state_account] ;
1608
+ let create_equality_proof_context_signer = & [ & equality_proof_context_state_account] ;
1609
+ let create_ciphertext_validity_proof_context_signer =
1610
+ & [ & ciphertext_validity_proof_context_state_account] ;
1611
+
1607
1612
let _ = try_join ! (
1608
1613
token. confidential_transfer_create_context_state_account(
1609
1614
& range_proof_pubkey,
1610
1615
& context_state_authority_pubkey,
1611
1616
& range_proof_data,
1612
1617
true ,
1613
- & range_proof_context_state_account ,
1618
+ create_range_proof_context_signer
1614
1619
) ,
1615
1620
token. confidential_transfer_create_context_state_account(
1616
1621
& equality_proof_pubkey,
1617
1622
& context_state_authority_pubkey,
1618
1623
& equality_proof_data,
1619
1624
false ,
1620
- & equality_proof_context_state_account ,
1625
+ create_equality_proof_context_signer
1621
1626
) ,
1622
1627
token. confidential_transfer_create_context_state_account(
1623
1628
& ciphertext_validity_proof_pubkey,
1624
1629
& context_state_authority_pubkey,
1625
1630
& ciphertext_validity_proof_data,
1626
1631
false ,
1627
- & ciphertext_validity_proof_context_state_account ,
1632
+ create_ciphertext_validity_proof_context_signer
1628
1633
)
1629
1634
) ?;
1630
1635
@@ -1655,24 +1660,25 @@ async fn command_transfer(
1655
1660
. await ?;
1656
1661
1657
1662
// close context state accounts
1663
+ let close_context_state_signer = & [ & context_state_authority] ;
1658
1664
let _ = try_join ! (
1659
1665
token. confidential_transfer_close_context_state(
1660
1666
& equality_proof_pubkey,
1661
1667
& sender,
1662
1668
& context_state_authority_pubkey,
1663
- & context_state_authority ,
1669
+ close_context_state_signer
1664
1670
) ,
1665
1671
token. confidential_transfer_close_context_state(
1666
1672
& ciphertext_validity_proof_pubkey,
1667
1673
& sender,
1668
1674
& context_state_authority_pubkey,
1669
- & context_state_authority ,
1675
+ close_context_state_signer
1670
1676
) ,
1671
1677
token. confidential_transfer_close_context_state(
1672
1678
& range_proof_pubkey,
1673
1679
& sender,
1674
1680
& context_state_authority_pubkey,
1675
- & context_state_authority ,
1681
+ close_context_state_signer
1676
1682
) ,
1677
1683
) ?;
1678
1684
@@ -3353,21 +3359,23 @@ async fn command_deposit_withdraw_confidential_tokens(
3353
3359
3354
3360
// set up context state accounts
3355
3361
let context_state_authority_pubkey = context_state_authority. pubkey ( ) ;
3362
+ let create_equality_proof_signer = & [ & equality_proof_context_state_keypair] ;
3363
+ let create_range_proof_signer = & [ & range_proof_context_state_keypair] ;
3356
3364
3357
3365
let _ = try_join ! (
3358
3366
token. confidential_transfer_create_context_state_account(
3359
3367
& equality_proof_context_state_pubkey,
3360
3368
& context_state_authority_pubkey,
3361
3369
& equality_proof_data,
3362
3370
false ,
3363
- & equality_proof_context_state_keypair ,
3371
+ create_equality_proof_signer
3364
3372
) ,
3365
3373
token. confidential_transfer_create_context_state_account(
3366
3374
& range_proof_context_state_pubkey,
3367
3375
& context_state_authority_pubkey,
3368
3376
& range_proof_data,
3369
3377
true ,
3370
- & range_proof_context_state_keypair ,
3378
+ create_range_proof_signer ,
3371
3379
)
3372
3380
) ?;
3373
3381
@@ -3392,18 +3400,19 @@ async fn command_deposit_withdraw_confidential_tokens(
3392
3400
. await ?;
3393
3401
3394
3402
// close context state account
3403
+ let close_context_state_signer = & [ & context_state_authority] ;
3395
3404
let _ = try_join ! (
3396
3405
token. confidential_transfer_close_context_state(
3397
3406
& equality_proof_context_state_pubkey,
3398
3407
& token_account_address,
3399
3408
& context_state_authority_pubkey,
3400
- & context_state_authority ,
3409
+ close_context_state_signer
3401
3410
) ,
3402
3411
token. confidential_transfer_close_context_state(
3403
3412
& range_proof_context_state_pubkey,
3404
3413
& token_account_address,
3405
3414
& context_state_authority_pubkey,
3406
- & context_state_authority ,
3415
+ close_context_state_signer
3407
3416
)
3408
3417
) ?;
3409
3418
0 commit comments