prividium 1.0.0 → 1.0.2
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/README.md +2 -1
- package/dist/cli/commands/doctor/probes/wallet/authorization-and-wallet-rpc.d.ts +1 -1
- package/dist/cli/commands/doctor/probes/wallet/authorization-and-wallet-rpc.js +3 -3
- package/dist/cli/commands/doctor/probes/wallet.js +4 -4
- package/dist/tsconfig.cli.tsbuildinfo +1 -1
- package/dist/tsconfig.sdk.tsbuildinfo +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -2,4 +2,4 @@ import type { DoctorContext, ProbeOutput } from '../../types.js';
|
|
|
2
2
|
export declare function runTransactionAuthorizationProbe(context: DoctorContext, walletAddress: string): Promise<void>;
|
|
3
3
|
export declare function runWalletBalanceProbe(context: DoctorContext, walletAddress: string): Promise<ProbeOutput>;
|
|
4
4
|
export declare function runWalletEthCallRestrictionProbe(context: DoctorContext, walletAddress: string): Promise<void>;
|
|
5
|
-
export declare function
|
|
5
|
+
export declare function runWalletStorageAtRestrictionProbe(context: DoctorContext, walletAddress: string): Promise<void>;
|
|
@@ -24,10 +24,10 @@ export async function runWalletEthCallRestrictionProbe(context, walletAddress) {
|
|
|
24
24
|
params: [{ to: walletAddress }, 'latest']
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
|
-
export async function
|
|
27
|
+
export async function runWalletStorageAtRestrictionProbe(context, walletAddress) {
|
|
28
28
|
await requireForbiddenRpc(context.targets.apiBaseUrl, {
|
|
29
|
-
method: '
|
|
29
|
+
method: 'eth_getStorageAt',
|
|
30
30
|
path: context.walletApiPath,
|
|
31
|
-
params: [walletAddress, 'latest']
|
|
31
|
+
params: [walletAddress, '0x0', 'latest']
|
|
32
32
|
});
|
|
33
33
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { passed, shortenAddress } from '../utils.js';
|
|
2
2
|
import { runAuthBalanceProbe, runAuthNonceProbe } from './wallet/authenticated-rpc.js';
|
|
3
|
-
import { runTransactionAuthorizationProbe, runWalletBalanceProbe, runWalletEthCallRestrictionProbe,
|
|
3
|
+
import { runTransactionAuthorizationProbe, runWalletBalanceProbe, runWalletEthCallRestrictionProbe, runWalletStorageAtRestrictionProbe } from './wallet/authorization-and-wallet-rpc.js';
|
|
4
4
|
export function createWalletStage(walletAddress, index, total) {
|
|
5
5
|
const progressSuffix = `${index + 1}/${total}: ${walletAddress}`;
|
|
6
6
|
return {
|
|
@@ -39,10 +39,10 @@ export function createWalletStage(walletAddress, index, total) {
|
|
|
39
39
|
run: (ctx) => runWalletEthCallRestrictionProbe(ctx, walletAddress)
|
|
40
40
|
},
|
|
41
41
|
{
|
|
42
|
-
id: `wallet-eth-get-
|
|
43
|
-
label: 'Wallet RPC
|
|
42
|
+
id: `wallet-eth-get-storage-at-restricted:${walletAddress}`,
|
|
43
|
+
label: 'Wallet RPC eth_getStorageAt restriction',
|
|
44
44
|
runIf: passed(`wallet-balance:${walletAddress}`, 'Wallet balance check failed'),
|
|
45
|
-
run: (ctx) =>
|
|
45
|
+
run: (ctx) => runWalletStorageAtRestrictionProbe(ctx, walletAddress)
|
|
46
46
|
}
|
|
47
47
|
]
|
|
48
48
|
};
|