caelum0x ed1ed54ec3 feat(privacy): expand gRPC surface, batch transfers, view keys, state machine
Adds full QueryServer gRPC with gateway REST, batch private transfers,
view key registration, commitment index/merkle proof/root history queries,
MPC trusted setup ceremony code, state machine for shielded notes, and
comprehensive integration tests.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 22:13:53 +03:00

34 lines
993 B
Go

package simulation
import (
"math/rand"
"github.com/cosmos/cosmos-sdk/baseapp"
"github.com/cosmos/cosmos-sdk/client"
sdk "github.com/cosmos/cosmos-sdk/types"
simtypes "github.com/cosmos/cosmos-sdk/types/simulation"
"clawchain/x/privacy/keeper"
"clawchain/x/privacy/types"
)
func SimulateMsgUnshield(
ak types.AuthKeeper,
bk types.BankKeeper,
k keeper.Keeper,
txGen client.TxConfig,
) simtypes.Operation {
return func(r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context, accs []simtypes.Account, chainID string,
) (simtypes.OperationMsg, []simtypes.FutureOperation, error) {
simAccount, _ := simtypes.RandomAcc(r, accs)
msg := &types.MsgUnshield{
Creator: simAccount.Address.String(),
}
// Unshield simulation requires a valid proof and an unspent shielded note.
// These values are generated off-chain and cannot be synthesized here.
return simtypes.NoOpMsg(types.ModuleName, sdk.MsgTypeURL(msg), "unshield requires off-chain zk proof inputs"), nil, nil
}
}