add support for confidential mint/burn token extension#836
add support for confidential mint/burn token extension#836jshiohaha wants to merge 2 commits intosolana-foundation:masterfrom
Conversation
|
@jshiohaha is attempting to deploy a commit to the Solana Foundation Team on Vercel. A member of the Team first needs to authorize it. |
| } | ||
| case 'confidentialMintBurn': { | ||
| const description = | ||
| 'Allow token issuers to opt in to encrypted mint and burn operations, along with encrypted total supply'; |
There was a problem hiding this comment.
Acknowledging this text can probably be improved — open to suggestions.
There was a problem hiding this comment.
sorry I don't know how this works i was just now getting this in email i've had aa few bad weeks so forgive me for being late or unresponsive but working by yourself is hard to do. Thanks for the help and since it's cleared up i'm going to get a hour of sleep until i got to get up to go to work do you need anything else from me or did i need to do anything to make this push through or whatever?
Greptile OverviewGreptile SummaryThis PR adds support for the confidential mint/burn SPL Token extension to prevent tokens with this extension from breaking the viewing experience. Changes made:
Implementation quality: Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant API as Solana RPC API
participant Validator as token-extension.ts<br/>(Validator)
participant Utils as token-extension.ts<br/>(Utils)
participant Component as TokenAccountSection.tsx
participant UI as Browser UI
API->>Validator: Token account data with<br/>confidentialMintBurn extension
Validator->>Validator: Validate against<br/>ConfidentialMintBurn schema
Note over Validator: Checks for 4 required<br/>string fields:<br/>- confidentialSupply<br/>- decryptableSupply<br/>- pendingBurn<br/>- supplyElgamalPubkey
Validator->>Utils: Validated extension object
Utils->>Utils: Populate metadata<br/>(name, description, docs link)
Utils->>Component: Extension with metadata
Component->>Component: Render confidentialMintBurn case<br/>with conditional field display
Component->>UI: Display extension table rows
|
|
that's very cool you found it out what was messing stuff up i'm sure but i
still don't know what to do with this i'm not a coder as much as i know i
could hardly read it but i did get that there was a hidden code nobody
saw.. and it put bots in control of burning tokens confidently and the
reason i'm seeing zeros is the code was hiding it until i out pass key in
which you gave me in the message correct? ? The rest of it was other
stocks that i got wrong or didn't finish and they were missed all this time
and i was the one that put this in there?? who is the person that put this
in the code?? The outcome will or should be I get to see the real amount
of money and control my accounts again no more "bots " controlling my stuff
and the code is fixed what about all my gold that I lost yesterday out the
bitcoins the day before or the victims on my other sites that were targeted
by the bots?? who are you?? Can you help me out and help me clean up this
mess a little bit if i had a few people that lost money I want to give it
back to them out of mine that i should be able to see now and as long as
it's the right number then I want to give it all back to the people that
lost it cause of this and i'll pay you to help out and make sure it gets
done right and with no more hacks???
…On Tue, Feb 3, 2026 at 1:51 AM greptile-apps[bot] ***@***.***> wrote:
*greptile-apps[bot]* left a comment (solana-foundation/explorer#836)
<#836 (comment)>
Greptile Overview Greptile Summary
This PR adds support for the confidential mint/burn SPL Token extension to
prevent tokens with this extension from breaking the viewing experience.
*Changes made:*
- Extended the validator schema with confidentialMintBurn variant
including four decoded fields (confidentialSupply, decryptableSupply,
pendingBurn, supplyElgamalPubkey)
- Added rendering logic to display all four fields with appropriate
labels in the token account details
- Included the extension in the sort order array to ensure proper
display positioning
- Added metadata and documentation links for the extension
- Provided comprehensive test coverage for the new extension
- Added realistic fixture data with base64-encoded values for
mocks/stories
*Implementation quality:*
The implementation follows existing patterns consistently across the
codebase, with all four extension fields being conditionally rendered and
proper test coverage included.
Confidence Score: 5/5
- This PR is safe to merge with no blocking issues
- The implementation follows established patterns, includes
comprehensive test coverage, and all changes are localized to adding
support for a new extension type without modifying existing functionality
- No files require special attention
Important Files Changed
Filename Overview
app/validators/accounts/token-extension.ts Added confidentialMintBurn
enum variant and schema definition with four string fields
app/utils/token-extension.ts Added metadata for confidential mint/burn
extension including description, name, and docs link
app/components/account/TokenAccountSection.tsx Added rendering logic for
confidential mint/burn fields and included extension in sort order
app/components/account/*tests*/TokenExtensionRow.spec.tsx Added
comprehensive test coverage for confidential mint/burn extension rendering Sequence
Diagram
sequenceDiagram
participant API as Solana RPC API
participant Validator as token-extension.ts<br/>(Validator)
participant Utils as token-extension.ts<br/>(Utils)
participant Component as TokenAccountSection.tsx
participant UI as Browser UI
API->>Validator: Token account data with<br/>confidentialMintBurn extension
Validator->>Validator: Validate against<br/>ConfidentialMintBurn schema
Note over Validator: Checks for 4 required<br/>string fields:<br/>- confidentialSupply<br/>- decryptableSupply<br/>- pendingBurn<br/>- supplyElgamalPubkey
Validator->>Utils: Validated extension object
Utils->>Utils: Populate metadata<br/>(name, description, docs link)
Utils->>Component: Extension with metadata
Component->>Component: Render confidentialMintBurn case<br/>with conditional field display
Component->>UI: Display extension table rows
Loading
—
Reply to this email directly, view it on GitHub
<#836 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/BZZDNNPNSZ7VEV6IZ3JNNRD4KBHOTAVCNFSM6AAAAACTZCAGN2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTQMZZGY3DIMRSG4>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Motivation
The explorer does not support the confidential mint/burn SPL Token extension, so tokens with this extension broke the viewing experience. I noticed this while building on top of confidential token extensions for the privacy hackathon.
Changes
confidentialMintBurnvariant and its four decoded fields so TokenAccount queries can parse the data. Confidential mint/burn data found here: https://github.com/solana-program/token-2022/blob/1af0e5a5fc6ea8f986e8f31260ba5778d6e91368/interface/src/extension/confidential_mint_burn/mod.rs#L17-L29Out of Scope
explorer/app/components/instruction/token/TokenDetailsCard.tsx
Line 31 in bd0b842
explorer/app/components/instruction/token/types.ts
Line 369 in bd0b842
Type of change
Screenshots
Current explorer behavior
Behavior after changes
Testing
Manual tests
On a local instance of surfpool with confidential transfers enabled, I created a SPL token with the following extensions: confidential transfer, confidential mint burn, metadata pointer, and token metadata. I started the explorer locally and verified that I could see all extensions, as expected.
Unit tests
Added a Jest test (should render confidentialMintBurn extension in TokenExtensionRow) to ensure the new renderer outputs each field header and value when provided.
Ran both
pnpm testandpnpm test:ciChecklist
build:infoscript to update build informationPending
Not applicable