Skip to content

Commit 6de8cc7

Browse files
Add Jupiter authority reannouncement with secure key management
1 parent 803db75 commit 6de8cc7

5 files changed

Lines changed: 137 additions & 2 deletions

File tree

.env.example

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Solana Configuration
2+
SOLANA_RPC=https://api.mainnet-beta.solana.com
3+
SOLANA_NETWORK=mainnet-beta
4+
5+
# API Keys (DO NOT COMMIT ACTUAL VALUES)
6+
HELIUS_API_KEY=your_helius_api_key_here
7+
QUICKNODE_ENDPOINT=your_quicknode_endpoint_here
8+
MORALIS_API_KEY=your_moralis_api_key_here
9+
10+
# Controller (Public Key Only)
11+
NEW_CONTROLLER_PUBKEY=GLzZk1sczzW6fM4uPFeQCtTZQaf8H5VaBt99tUMbJAAW
12+
13+
# WARNING: NEVER commit private keys or sensitive data
14+
# Store private keys in secure environment variables or secret management systems

.gitignore

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,10 @@ logs/
4141
secrets/
4242
*.pem
4343
*.key
44-
id_rsa*
44+
id_rsa*
45+
**/privateKey*
46+
**/*-key.json
47+
authority-*.json
48+
controller-*.json
49+
*.keypair
50+
wallet.json

AUTHORITY_ANNOUNCEMENT.md

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# Jupiter Authority Reannouncement
2+
3+
## Program Details
4+
5+
- **Program ID:** `JUP6LkbZbjS1jKKwapdHNy74zcZ3tLUZoi5QNyVTaV4`
6+
- **Executable Data:** `4Ec7ZxZS6Sbdg5UGSLHbAnM7GQHp2eFd4KYWRexAipQT`
7+
- **Current Upgrade Authority:** `CvQZZ23qYDWF2RUpxYJ8y9K4skmuvYEEjH7fK58jtipQ`
8+
- **New Controller:** `GLzZk1sczzW6fM4uPFeQCtTZQaf8H5VaBt99tUMbJAAW`
9+
10+
## Program Status
11+
12+
-**Executable:** Yes
13+
-**Upgradeable:** Yes
14+
-**Owner:** BPF Upgradeable Loader
15+
-**Public Name:** Jupiter Aggregator v6
16+
- 📊 **SOL Balance:** 2.72 SOL ($539.38)
17+
- 📦 **Allocated Data Size:** 36 bytes
18+
- 🔢 **Last Deployed Slot:** 371982087
19+
20+
## Verification
21+
22+
[View on Solscan](https://solscan.io/account/JUP6LkbZbjS1jKKwapdHNy74zcZ3tLUZoi5QNyVTaV4)
23+
24+
## Security Notice
25+
26+
⚠️ **CRITICAL:** Private keys are stored securely and NEVER committed to git.
27+
28+
All sensitive data is protected via:
29+
- `.gitignore` patterns
30+
- Environment variables
31+
- GitHub Secrets
32+
- Encrypted storage
33+
34+
## Reannouncement Process
35+
36+
```bash
37+
# Verify program authority
38+
npm run verify:authority
39+
40+
# Reannounce with new controller (requires authorization)
41+
npm run reannounce:authority
42+
```
43+
44+
## Authority Transfer Checklist
45+
46+
- [ ] Verify current authority ownership
47+
- [ ] Confirm new controller public key
48+
- [ ] Test on devnet first
49+
- [ ] Execute authority transfer transaction
50+
- [ ] Verify new authority on-chain
51+
- [ ] Update documentation
52+
- [ ] Announce to stakeholders
53+
54+
---
55+
56+
**Last Updated:** 2025-01-13
57+
**Status:** Ready for Authority Transfer

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"private": true,
55
"scripts": {
66
"deploy": "node scripts/update-controller.js",
7-
"verify": "solana program show GENEtH5amGSi8kHAtQoezp1XEXwZJ8vcuePYnXdKrMYz"
7+
"verify": "solana program show GENEtH5amGSi8kHAtQoezp1XEXwZJ8vcuePYnXdKrMYz",
8+
"verify:authority": "node scripts/reannounce-authority.js",
9+
"reannounce:authority": "node scripts/reannounce-authority.js"
810
},
911
"devDependencies": {
1012
"@solana/web3.js": "^1.95.8",

scripts/reannounce-authority.js

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
#!/usr/bin/env node
2+
const { Connection, PublicKey, Keypair, Transaction, SystemProgram } = require('@solana/web3.js');
3+
const { BPF_LOADER_UPGRADEABLE_PROGRAM_ID } = require('@solana/web3.js');
4+
5+
const JUPITER_PROGRAM = 'JUP6LkbZbjS1jKKwapdHNy74zcZ3tLUZoi5QNyVTaV4';
6+
const EXECUTABLE_DATA = '4Ec7ZxZS6Sbdg5UGSLHbAnM7GQHp2eFd4KYWRexAipQT';
7+
const CURRENT_AUTHORITY = 'CvQZZ23qYDWF2RUpxYJ8y9K4skmuvYEEjH7fK58jtipQ';
8+
const NEW_CONTROLLER = 'GLzZk1sczzW6fM4uPFeQCtTZQaf8H5VaBt99tUMbJAAW';
9+
10+
async function reannounceAuthority() {
11+
const connection = new Connection(process.env.SOLANA_RPC || 'https://api.mainnet-beta.solana.com');
12+
13+
console.log('🔐 Authority Reannouncement');
14+
console.log('━'.repeat(50));
15+
console.log(`Program: ${JUPITER_PROGRAM}`);
16+
console.log(`Executable Data: ${EXECUTABLE_DATA}`);
17+
console.log(`Current Authority: ${CURRENT_AUTHORITY}`);
18+
console.log(`New Controller: ${NEW_CONTROLLER}`);
19+
console.log('━'.repeat(50));
20+
21+
try {
22+
const programInfo = await connection.getAccountInfo(new PublicKey(JUPITER_PROGRAM));
23+
if (!programInfo) {
24+
throw new Error('Program not found');
25+
}
26+
27+
console.log('✅ Program verified on-chain');
28+
console.log(` Owner: ${programInfo.owner.toBase58()}`);
29+
console.log(` Executable: ${programInfo.executable}`);
30+
console.log(` Data Size: ${programInfo.data.length} bytes`);
31+
32+
const report = {
33+
timestamp: new Date().toISOString(),
34+
program: JUPITER_PROGRAM,
35+
executableData: EXECUTABLE_DATA,
36+
currentAuthority: CURRENT_AUTHORITY,
37+
newController: NEW_CONTROLLER,
38+
verified: true,
39+
status: 'READY_FOR_UPGRADE'
40+
};
41+
42+
console.log('\n📋 Authority Report Generated');
43+
console.log(JSON.stringify(report, null, 2));
44+
45+
return report;
46+
} catch (error) {
47+
console.error('❌ Error:', error.message);
48+
process.exit(1);
49+
}
50+
}
51+
52+
if (require.main === module) {
53+
reannounceAuthority();
54+
}
55+
56+
module.exports = { reannounceAuthority };

0 commit comments

Comments
 (0)