Yellow Network error: "missing signature for participant 0x02F499..." #85
Unanswered
stevenzeiler
asked this question in
Q&A
Replies: 1 comment
-
|
I am encountering this issue when trying to establish an application session and receive the following error: Here is the code I am using to attempt to establish an application session: console.log(`📋 Creating Application Session`);
console.log(` Protocol: ${APP_PROTOCOL}`);
console.log(` Participant 1: ${sessionKey.address}`);
console.log(` Participant 2: ${secondSessionKey.address}`);
console.log(` Initial Amount: ${parseInt(WORKFLOW_AMOUNT) / 1000000} USDC\n`);
const appDefinition = {
protocol: APP_PROTOCOL as RPCProtocolVersion,
participants: [
sessionKey.address as `0x${string}`,
secondSessionKey.address as `0x${string}`
],
weights: [100, 0], // theoretically only requires signature from first participant
quorum: 100, // Both must approve all changes
challenge: 86400,
nonce: Date.now()
};
const initialAllocations = [
{
participant: sessionKey.address as `0x${string}`,
asset: 'usdc',
amount: WORKFLOW_AMOUNT
},
{
participant: secondSessionKey.address as `0x${string}`,
asset: 'usdc',
amount: '0'
}
];
const signer = createECDSAMessageSigner(sessionKey.privateKey);
const secondSigner = createECDSAMessageSigner(secondSessionKey.privateKey);
const sessionMessage = await createAppSessionMessage(
signer,
{ definition: appDefinition, allocations: initialAllocations }
);
console.log("SESSION MESSAGE", sessionMessage);
await client.sendMessage(sessionMessage);
console.log(` 📤 Session creation sent...`);
```
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
The following solution is taken from the nitro-viper-dual demo application: https://github.com/YellowProjects/nitro-viper-duel/blob/825b1b967cb714d40b542c56a8012e1634dcbd21/server/CLIENT_SIGNING_GUIDE.md?plain=1#L4
Client-Side App Session Signing Guide
Problem
Yellow Network error:
"missing signature for participant 0x02F499..."This means Yellow Network cannot verify the signature. This happens when:
createAppSessionMessage()appSessionDatabefore signingCritical Requirements
createAppSessionMessage()from @erc7824/nitroliteappSessionDatafrom server (don't modify it)How Client Must Sign
When the client receives
appSession:signatureRequestorappSession:startGameRequest:✅ CORRECT Approach: Step-by-Step
Step 1: Setup Session Key (Do this ONCE during auth)
Step 2: Sign App Session Request
❌ WRONG Approaches
Don't sign the requestToSign array directly:
Don't sign with main wallet:
Don't recreate appSessionData:
Key Points
createAppSessionMessageappSessionDatareceived from serversig[0]Verification
The signature will be verified by Yellow Network against:
participantsarray (main wallet address)Troubleshooting Checklist
1. Check Session Key Setup
2. Check createMessageSigner Import
3. Check appSessionData Usage
4. Verify Signature Format
The signature should:
"0x"5. Check Console for Errors
Look for:
6. Common Mistakes
Mistake 1: Signing with main wallet
Mistake 2: Not storing session key
Mistake 3: Using wrong signing method
Quick Debug Steps
Beta Was this translation helpful? Give feedback.
All reactions