Commit Graph

22 Commits

Author SHA1 Message Date
Tyera Eulberg 2491b29a1e
Add AuthorityType variant to use for mint close-authority adjustment (#3111) 2022-04-26 07:55:15 -06:00
samkim-crypto 049a89f351
token-2022: Add confidential transfer with fee instruction (#2988)
* token-2022: add separate transfer with fee instruction

* token-2022: add `TransferWithFee` client code

* apply twoxtx patch

* token-2022: add brief tests for transfer with fee

* Revert "apply twoxtx patch"

This reverts commit ce09d1f5d2fb496cd4ee9991be234726786e39f2.

* token-2022: cargo fmt

* token-2022: uncommenting the rest of the tests

* token-2022: cargo fmt

* token-2022: temporarily reverting to 5f89521

* token-2022: minor

* token-2022: clippy

* token-2022: apply twoxtx patch

* token-2022: fix transfer with fee test

* Revert "token-2022: apply twoxtx patch"

This reverts commit 577e63c2f38ce0a17fa4aede3d0acfd852b1d3ab.

* token-2022: simplify fee parameter for zkp on client

* token-2022: fix build
2022-04-22 14:00:42 -04:00
samkim-crypto 76f0532d83
token-2022: fix confidential transfer tests (#3096)
* token-2022: update zk-token-sdk to 1.10.8

* token-2022: remove ignore tag for confidential tranfer test
2022-04-21 12:21:21 -04:00
Jon Cinque b7a3fc6243
token-2022: Fix (rarely) flakey test by changing tx (#3015) 2022-03-19 02:39:31 +01:00
samkim-crypto 4ddaae5f21
Bump zk token sdk (#3002)
* token-2022: bumping zk-token-sdk to 1.10.1-pre1 and updating variable names accordingly

* token-2022: updating client and test variables to match newest zk-token-sdk
2022-03-11 06:57:32 -05:00
Jon Cinque 29479fcc72
token-2022: Make program and crate deployable (#2985)
* token-2022: Make program and crate deployable

* Featurize the syscall usage

* Re-add GenericTokenAccount

* Rebase correctly with GenericTokenAccount

* Add updated valid_account_data implementation
2022-03-10 17:42:16 +01:00
Tyera Eulberg 810c79ec32
token-2022: Allow anyone to burn/close an Account owned by the system program or the incinerator (#2890)
* Allow anyone to burn and close token Accounts owned by the system program and the incinerator

* Require rent from incinerator/system-owned token accounts be burnt when accounts closed

* Add support to OG program
2022-03-09 19:31:39 -07:00
Tyera Eulberg 221935bdba
Ignore failing test (#2999) 2022-03-09 16:48:36 -07:00
Michael Vines ab23d6b41e Augment ct tests with decryptable_available_balance assertions 2022-02-28 17:26:32 -08:00
Michael Vines 22135e547c Add ConfidentialTransferInstruction Deposit/Transfer/Withdraw tests 2022-02-28 09:34:23 -08:00
Michael Vines 38243ddcd4 Add temporary twoxtx feature for ConfidentialTransfer extension unit testing 2022-02-28 09:34:23 -08:00
Michael Vines 6875603085 Initial ConfidentialTransferInstruction::EmptyAccount test 2022-02-28 09:34:23 -08:00
samkim-crypto af90facd1d
token-2022: add fee withdraw and harvest instructions (#2907)
* token-2022: add fee harvest instruction for confidential extension

* token-2022: cargo fmt

* token-2022: add `WithdrawWithheldTokensMint` processor

* token-2022: add `WithdrawWithheldTokensAccounts` processor

* token-2022: incorporate VerifyWithdrawWithheldTokens instruction

* token-2022: minor variable name changes

* token-2022: additional comments + renaming variables

* token-2022: check if confidential extension was approved for fee harvest

Co-authored-by: Michael Vines <mvines@gmail.com>

* token-2022: fix error type for overflow

* token-2022: remove unnecessary fee extension check for confidential token harvest

* token-2022: add extra detail on front-running for harvesting fees

* token-2022: fix pending balance

* token-2022: bump zk-token-sdk to 0.8.0

* token-2022: fix minor variable name issue

* token-2022: minor spelling

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>

* token-2022: addressing smaller review feedback

* token-2022: change fee_mint to transfer_fee_config in confidential transfer

* Update token/program-2022/Cargo.toml

* token-2022: fix cargo bpf-test fail

* token-2022: fixing a previous comment mistake

Co-authored-by: Michael Vines <mvines@gmail.com>
Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
2022-02-24 21:16:32 -05:00
Tyera Eulberg 0268d76d30
token-2022: complete memo extension functionality (#2876)
* Add NoMemo error and use syscall to require memos

* Flesh out + dedupe memo-transfer tests

* Add memo v1 test cases
2022-02-24 16:48:42 -07:00
Michael Vines 1bcd07dca1 Field name cleanup 2022-02-23 09:54:46 -08:00
Michael Vines 656f0eb1d9 Reduce test code duplication 2022-02-23 09:54:46 -08:00
Michael Vines e111e997b7 Add {En,Dis}ableBalanceCredits test 2022-02-23 08:37:19 -08:00
Michael Vines 7c3b614af0 Add confidential transfer configure and approve account tests 2022-02-23 07:37:14 -08:00
Michael Vines c4c14b5c51 Add confidential transfer initialize/update mint tests 2022-02-22 21:25:18 -07:00
Jon Cinque 558322798f
token-2022: Support extensions in `SyncNative` (#2926) 2022-02-17 22:50:10 +01:00
Michael Vines 2e968115ab Add CreateNativeMint instruction 2022-02-09 20:03:21 -08:00
Tyera Eulberg 428d93bdcb
Move program-2022 tests to new crate (#2892) 2022-02-09 15:02:33 -07:00