File tree Expand file tree Collapse file tree 6 files changed +20
-14
lines changed
test/e2e/tests/state-snapshots Expand file tree Collapse file tree 6 files changed +20
-14
lines changed Original file line number Diff line number Diff line change @@ -8,20 +8,12 @@ import {
88 BlockaidResultType ,
99} from '../../../../shared/constants/security-provider' ;
1010import { CHAIN_IDS } from '../../../../shared/constants/network' ;
11+ import { SIGNING_METHODS } from '../../../../shared/constants/transaction' ;
1112import { PreferencesController } from '../../controllers/preferences' ;
1213import { SecurityAlertResponse } from '../transaction/util' ;
1314
1415const { sentry } = global as any ;
1516
16- export const SIGNING_METHODS = Object . freeze ( [
17- 'eth_sign' ,
18- 'eth_signTypedData' ,
19- 'eth_signTypedData_v1' ,
20- 'eth_signTypedData_v3' ,
21- 'eth_signTypedData_v4' ,
22- 'personal_sign' ,
23- ] ) ;
24-
2517const CONFIRMATION_METHODS = Object . freeze ( [
2618 'eth_sendRawTransaction' ,
2719 'eth_sendTransaction' ,
Original file line number Diff line number Diff line change @@ -84,10 +84,12 @@ export async function addDappTransaction(
8484
8585export async function addTransaction (
8686 request : AddTransactionRequest ,
87+ ///: BEGIN:ONLY_INCLUDE_IF(blockaid)
8788 updateSecurityAlertResponseByTxId : (
8889 reqId : string | undefined ,
8990 securityAlertResponse : SecurityAlertResponse ,
9091 ) => void ,
92+ ///: END:ONLY_INCLUDE_IF
9193) : Promise < TransactionMeta > {
9294 ///: BEGIN:ONLY_INCLUDE_IF(blockaid)
9395 const {
Original file line number Diff line number Diff line change @@ -143,7 +143,11 @@ import { BrowserRuntimePostMessageStream } from '@metamask/post-message-stream';
143143import { toChecksumHexAddress } from '../../shared/modules/hexstring-utils' ;
144144///: END:ONLY_INCLUDE_IF
145145
146- import { AssetType , TokenStandard } from '../../shared/constants/transaction' ;
146+ import {
147+ AssetType ,
148+ TokenStandard ,
149+ SIGNING_METHODS ,
150+ } from '../../shared/constants/transaction' ;
147151import {
148152 GAS_API_BASE_URL ,
149153 GAS_DEV_API_BASE_URL ,
@@ -228,10 +232,7 @@ import { AddressBookPetnamesBridge } from './lib/AddressBookPetnamesBridge';
228232import { AccountIdentitiesPetnamesBridge } from './lib/AccountIdentitiesPetnamesBridge' ;
229233
230234///: BEGIN:ONLY_INCLUDE_IF(blockaid)
231- import {
232- createPPOMMiddleware ,
233- SIGNING_METHODS ,
234- } from './lib/ppom/ppom-middleware' ;
235+ import { createPPOMMiddleware } from './lib/ppom/ppom-middleware' ;
235236import * as PPOMModule from './lib/ppom/ppom' ;
236237///: END:ONLY_INCLUDE_IF
237238import {
Original file line number Diff line number Diff line change @@ -10,6 +10,15 @@ export const IN_PROGRESS_TRANSACTION_STATUSES = [
1010 TransactionStatus . submitted ,
1111] ;
1212
13+ export const SIGNING_METHODS = Object . freeze ( [
14+ 'eth_sign' ,
15+ 'eth_signTypedData' ,
16+ 'eth_signTypedData_v1' ,
17+ 'eth_signTypedData_v3' ,
18+ 'eth_signTypedData_v4' ,
19+ 'personal_sign' ,
20+ ] ) ;
21+
1322///: BEGIN:ONLY_INCLUDE_IF(build-mmi)
1423/**
1524 * Status for finalized transactions.
Original file line number Diff line number Diff line change 3232 "outdatedBrowserWarningLastShown" : " number" ,
3333 "nftsDetectionNoticeDismissed" : false ,
3434 "showTestnetMessageInDropdown" : true ,
35+ "signatureSecurityAlertResponses" : false ,
3536 "showBetaHeader" : false ,
3637 "showProductTour" : true ,
3738 "showNetworkBanner" : true ,
Original file line number Diff line number Diff line change 6767 "outdatedBrowserWarningLastShown" : " number" ,
6868 "nftsDetectionNoticeDismissed" : false ,
6969 "showTestnetMessageInDropdown" : true ,
70+ "signatureSecurityAlertResponses" : false ,
7071 "showBetaHeader" : false ,
7172 "showProductTour" : true ,
7273 "showNetworkBanner" : true ,
You can’t perform that action at this time.
0 commit comments