@exodus/solana-plugin 1.34.0 → 1.36.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,26 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [1.36.0](https://github.com/ExodusMovement/assets/compare/@exodus/solana-plugin@1.35.0...@exodus/solana-plugin@1.36.0) (2026-03-12)
7
+
8
+
9
+ ### Features
10
+
11
+
12
+ * feat: persist security checks in account state and formalize asset.api.securityChecks API (#7537)
13
+
14
+
15
+
16
+ ## [1.35.0](https://github.com/ExodusMovement/assets/compare/@exodus/solana-plugin@1.34.0...@exodus/solana-plugin@1.35.0) (2026-03-10)
17
+
18
+
19
+ ### Features
20
+
21
+
22
+ * feat: switch Solana txs to Clarity (#7449)
23
+
24
+
25
+
6
26
  ## [1.34.0](https://github.com/ExodusMovement/assets/compare/@exodus/solana-plugin@1.33.0...@exodus/solana-plugin@1.34.0) (2026-03-09)
7
27
 
8
28
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@exodus/solana-plugin",
3
- "version": "1.34.0",
3
+ "version": "1.36.0",
4
4
  "description": "Solana plugin for Exodus SDK powered wallets.",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
@@ -27,7 +27,7 @@
27
27
  "@exodus/bip44-constants": "^195.0.0",
28
28
  "@exodus/i18n-dummy": "^1.0.0",
29
29
  "@exodus/send-validation-model": "^1.0.0",
30
- "@exodus/solana-api": "^3.29.4",
30
+ "@exodus/solana-api": "^3.30.0",
31
31
  "@exodus/solana-lib": "^3.20.1",
32
32
  "@exodus/solana-meta": "^2.3.1",
33
33
  "@exodus/web3-solana-utils": "^2.9.0",
@@ -44,5 +44,5 @@
44
44
  "type": "git",
45
45
  "url": "git+https://github.com/ExodusMovement/assets.git"
46
46
  },
47
- "gitHead": "f27651709a0a2c70f3c0867afc543fcfa5cfd5c2"
47
+ "gitHead": "bdd3658f4f045809a360f53f0fd2027293c00de8"
48
48
  }
@@ -1,6 +1,22 @@
1
1
  import { SolanaClarityMonitor, SolanaMonitor, SolanaWebsocketMonitor } from '@exodus/solana-api'
2
2
  import assert from 'minimalistic-assert'
3
3
 
4
+ export const securityChecks = ({ accountState }) => {
5
+ if (accountState?.ownerChanged) {
6
+ return {
7
+ isSecure: false,
8
+ type: 'LOST_PERMISSIONS',
9
+ reason: 'Account owner changed.',
10
+ }
11
+ }
12
+
13
+ return {
14
+ isSecure: true,
15
+ type: null,
16
+ reason: null,
17
+ }
18
+ }
19
+
4
20
  export const createHistoryMonitorFactory = ({
5
21
  monitorType,
6
22
  assetClientInterface,
@@ -18,8 +34,8 @@ export const createHistoryMonitorFactory = ({
18
34
  assert(monitorType, 'expected monitorType')
19
35
  assert(interval, 'expected monitor interval')
20
36
  assert(clarityApi, 'expected clarity api server')
21
- assert(rpcApi, 'expected rpc api server')
22
37
  assert(wsApi, 'expected ws api server')
38
+ if (monitorType === 'rpc') assert(rpcApi, 'expected rpc api server')
23
39
 
24
40
  return (args) => {
25
41
  let monitor
@@ -29,7 +45,6 @@ export const createHistoryMonitorFactory = ({
29
45
  assetClientInterface,
30
46
  interval,
31
47
  includeUnparsed,
32
- rpcApi,
33
48
  clarityApi,
34
49
  wsApi,
35
50
  txsLimit,
@@ -44,7 +59,6 @@ export const createHistoryMonitorFactory = ({
44
59
  ticksBetweenHistoryFetches,
45
60
  ticksBetweenStakeFetches,
46
61
  includeUnparsed,
47
- rpcApi,
48
62
  clarityApi,
49
63
  txsLimit,
50
64
  ...args,
@@ -30,7 +30,7 @@ import {
30
30
  } from '@exodus/solana-lib'
31
31
  import ms from 'ms'
32
32
 
33
- import { createHistoryMonitorFactory } from './create-asset-utils.js'
33
+ import { createHistoryMonitorFactory, securityChecks } from './create-asset-utils.js'
34
34
  import { createGetBalanceForAddress } from './get-balance-for-address.js'
35
35
  import sendValidationsFactory from './send-validations.js'
36
36
  import { createWeb3API } from './web3/index.js'
@@ -44,7 +44,7 @@ export const createSolanaAssetFactory =
44
44
  ({
45
45
  assetClientInterface,
46
46
  config: {
47
- monitorType = 'rpc', // 'rpc' | 'clarity'
47
+ monitorType = 'ws-clarity', // 'rpc' | 'clarity' | 'ws-clarity'
48
48
  stakingFeatureAvailable = true,
49
49
  includeUnparsed = false,
50
50
  allowSendingAll = true,
@@ -227,7 +227,7 @@ export const createSolanaAssetFactory =
227
227
  addressHasHistory: (...args) => defaultApi.addressHasHistory(...args),
228
228
  broadcastTx: (...args) => defaultApi.broadcastTransaction(...args),
229
229
  createAccountState: () => SolanaAccountState,
230
- hasLostPermission: ({ accountState }) => Boolean(accountState?.ownerChanged),
230
+ securityChecks,
231
231
  createHistoryMonitor,
232
232
  createToken: (tokenDef) =>
233
233
  tokenDef.isBuiltIn ? createToken(tokenDef) : createCustomToken(tokenDef),