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 CHANGED
@@ -437,7 +437,8 @@ await prividium.admin.contracts.create({
437
437
  name: null,
438
438
  description: null,
439
439
  discloseErc20TotalSupply: false,
440
- discloseBytecode: false
440
+ discloseBytecode: false,
441
+ disclosureStartBlock: '0x0'
441
442
  });
442
443
  ```
443
444
 
@@ -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 runWalletTxCountRestrictionProbe(context: DoctorContext, walletAddress: string): Promise<void>;
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 runWalletTxCountRestrictionProbe(context, walletAddress) {
27
+ export async function runWalletStorageAtRestrictionProbe(context, walletAddress) {
28
28
  await requireForbiddenRpc(context.targets.apiBaseUrl, {
29
- method: 'eth_getTransactionCount',
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, runWalletTxCountRestrictionProbe } from './wallet/authorization-and-wallet-rpc.js';
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-transaction-count-restricted:${walletAddress}`,
43
- label: 'Wallet RPC eth_getTransactionCount restriction',
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) => runWalletTxCountRestrictionProbe(ctx, walletAddress)
45
+ run: (ctx) => runWalletStorageAtRestrictionProbe(ctx, walletAddress)
46
46
  }
47
47
  ]
48
48
  };