forked from tornadocash/classic-ui
update rpcs & remove sanction check
This commit is contained in:
parent
1b922fa445
commit
135adee8e8
@ -1,12 +1,3 @@
|
||||
const {
|
||||
INFURA_KEY,
|
||||
ALCHEMY_MAINNET_KEY,
|
||||
ALCHEMY_POLYGON_KEY,
|
||||
ALCHEMY_OPTIMISM_KEY,
|
||||
ALCHEMY_ARBITRUM_KEY,
|
||||
ALCHEMY_GOERLI_KEY
|
||||
} = process.env
|
||||
|
||||
export default {
|
||||
netId1: {
|
||||
rpcCallRetryAttempt: 15,
|
||||
@ -28,13 +19,9 @@ export default {
|
||||
networkName: 'Ethereum Mainnet',
|
||||
deployedBlock: 9116966,
|
||||
rpcUrls: {
|
||||
Infura: {
|
||||
name: 'Infura',
|
||||
url: `https://mainnet.infura.io/v3/${INFURA_KEY}`
|
||||
},
|
||||
Alchemy: {
|
||||
name: 'Alchemy',
|
||||
url: `https://eth-mainnet.alchemyapi.io/v2/${ALCHEMY_MAINNET_KEY}`
|
||||
SecureRPC: {
|
||||
name: 'SecureRPC',
|
||||
url: 'https://api.securerpc.com/v1'
|
||||
}
|
||||
},
|
||||
multicall: '0xeefba1e63905ef1d7acba5a8513c70307c1ce441',
|
||||
@ -148,17 +135,9 @@ export default {
|
||||
multicall: '0x41263cba59eb80dc200f3e2544eda4ed6a90e76c',
|
||||
echoContractAccount: '0xa75BF2815618872f155b7C4B0C81bF990f5245E4',
|
||||
rpcUrls: {
|
||||
publicRpc1: {
|
||||
name: 'BSC Public RPC 1',
|
||||
url: 'https://bsc-dataseed.binance.org/'
|
||||
},
|
||||
publicRpc2: {
|
||||
name: 'BSC Public RPC 2',
|
||||
url: 'https://bsc-dataseed1.defibit.io/'
|
||||
},
|
||||
publicRpc3: {
|
||||
name: 'BSC Public RPC 3',
|
||||
url: 'https://bsc-dataseed1.ninicoin.io/'
|
||||
bscRpc: {
|
||||
name: 'BSC RPC',
|
||||
url: 'https://bscrpc.com/'
|
||||
}
|
||||
},
|
||||
tokens: {
|
||||
@ -203,13 +182,9 @@ export default {
|
||||
multicall: '0x11ce4B23bD875D7F5C6a31084f55fDe1e9A87507',
|
||||
echoContractAccount: '0xa75BF2815618872f155b7C4B0C81bF990f5245E4',
|
||||
rpcUrls: {
|
||||
Infura: {
|
||||
name: 'Infura',
|
||||
url: `https://polygon-mainnet.infura.io/v3/${INFURA_KEY}`
|
||||
},
|
||||
Alchemy: {
|
||||
name: 'Alchemy',
|
||||
url: `https://polygon-mainnet.g.alchemy.com/v2/${ALCHEMY_POLYGON_KEY}`
|
||||
polygonRPC: {
|
||||
name: 'Polygon RPC',
|
||||
url: `https://polygon-rpc.com`
|
||||
}
|
||||
},
|
||||
tokens: {
|
||||
@ -255,13 +230,9 @@ export default {
|
||||
echoContractAccount: '0xa75BF2815618872f155b7C4B0C81bF990f5245E4',
|
||||
ovmGasPriceOracleContract: '0x420000000000000000000000000000000000000F',
|
||||
rpcUrls: {
|
||||
Alchemy: {
|
||||
name: 'Alchemy',
|
||||
url: `https://opt-mainnet.g.alchemy.com/v2/${ALCHEMY_OPTIMISM_KEY}`
|
||||
},
|
||||
Infura: {
|
||||
name: 'Infura',
|
||||
url: `https://optimism-mainnet.infura.io/v3/${INFURA_KEY}`
|
||||
Optimism: {
|
||||
name: 'Optimism',
|
||||
url: `https://mainnet.optimism.io`
|
||||
}
|
||||
},
|
||||
tokens: {
|
||||
@ -309,14 +280,6 @@ export default {
|
||||
Arbitrum: {
|
||||
name: 'Arbitrum Public RPC',
|
||||
url: 'https://arb1.arbitrum.io/rpc'
|
||||
},
|
||||
Alchemy: {
|
||||
name: 'Alchemy',
|
||||
url: `https://arb-mainnet.g.alchemy.com/v2/${ALCHEMY_ARBITRUM_KEY}`
|
||||
},
|
||||
Infura: {
|
||||
name: 'Infura',
|
||||
url: `https://arbitrum-mainnet.infura.io/v3/${INFURA_KEY}`
|
||||
}
|
||||
},
|
||||
tokens: {
|
||||
@ -362,8 +325,8 @@ export default {
|
||||
echoContractAccount: '0xa75BF2815618872f155b7C4B0C81bF990f5245E4',
|
||||
rpcUrls: {
|
||||
publicRpc: {
|
||||
name: 'Gnosis Chain RPC',
|
||||
url: 'https://rpc.gnosischain.com/tornado'
|
||||
name: 'Community RPC',
|
||||
url: 'https://development.tornadocash.community/rpc/v1'
|
||||
}
|
||||
},
|
||||
tokens: {
|
||||
@ -455,9 +418,9 @@ export default {
|
||||
echoContractAccount: '0x37e6859804b6499d1e4a86d70a5fdd5de6a0ac65',
|
||||
aggregatorContract: '0x8cb1436F64a3c33aD17bb42F94e255c4c0E871b2',
|
||||
rpcUrls: {
|
||||
Alchemy: {
|
||||
name: 'Alchemy',
|
||||
url: `https://eth-goerli.alchemyapi.io/v2/${ALCHEMY_GOERLI_KEY}`
|
||||
Infura: {
|
||||
name: 'Infura',
|
||||
url: 'https://goerli.infura.io/v3/9aa3d95b3bc440fa88ea12eaa4456161'
|
||||
}
|
||||
},
|
||||
tokens: {
|
||||
|
@ -7,8 +7,6 @@ import { PROVIDERS } from '@/constants'
|
||||
import networkConfig from '@/networkConfig'
|
||||
import { walletConnectConnector } from '@/services'
|
||||
|
||||
import SanctionsListAbi from '@/abis/SanctionsList.abi'
|
||||
|
||||
const { toChecksumAddress } = require('web3-utils')
|
||||
|
||||
const state = () => {
|
||||
@ -330,20 +328,6 @@ const actions = {
|
||||
console.error('networkChangeHandler', err.message)
|
||||
}
|
||||
},
|
||||
async checkIsSanctioned({ rootGetters }, { address }) {
|
||||
const ethProvider = rootGetters['relayer/ethProvider']
|
||||
const contract = new ethProvider.eth.Contract(
|
||||
SanctionsListAbi,
|
||||
'0x40C57923924B5c5c5455c48D93317139ADDaC8fb'
|
||||
)
|
||||
|
||||
const isSanctioned = await contract.methods.isSanctioned(address).call()
|
||||
|
||||
if (isSanctioned) {
|
||||
window.onbeforeunload = null
|
||||
window.location = 'https://twitter.com/TornadoCash/status/1514904975037669386'
|
||||
}
|
||||
},
|
||||
async onNetworkChanged({ state, getters, commit, dispatch }, { netId }) {
|
||||
dispatch('checkMismatchNetwork', netId)
|
||||
|
||||
@ -424,8 +408,6 @@ const actions = {
|
||||
throw new Error('lockedMetamask')
|
||||
}
|
||||
|
||||
await dispatch('checkIsSanctioned', { address })
|
||||
|
||||
commit('IDENTIFY', address)
|
||||
|
||||
const netId = await dispatch('checkNetworkVersion')
|
||||
@ -528,7 +510,7 @@ const actions = {
|
||||
56: {
|
||||
chainId: '0x38',
|
||||
chainName: 'Binance Smart Chain Mainnet',
|
||||
rpcUrls: ['https://bsc-dataseed1.ninicoin.io'],
|
||||
rpcUrls: ['https://bscrpc.com'],
|
||||
nativeCurrency: {
|
||||
name: 'Binance Chain Native Token',
|
||||
symbol: 'BNB',
|
||||
@ -550,7 +532,7 @@ const actions = {
|
||||
100: {
|
||||
chainId: '0x64',
|
||||
chainName: 'Gnosis',
|
||||
rpcUrls: ['https://rpc.gnosischain.com'],
|
||||
rpcUrls: ['https://development.tornadocash.community/rpc/v1'],
|
||||
nativeCurrency: {
|
||||
name: 'xDAI',
|
||||
symbol: 'xDAI',
|
||||
@ -561,7 +543,7 @@ const actions = {
|
||||
137: {
|
||||
chainId: '0x89',
|
||||
chainName: 'Polygon Mainnet',
|
||||
rpcUrls: ['https://rpc-mainnet.maticvigil.com'],
|
||||
rpcUrls: ['https://polygon-rpc.com'],
|
||||
nativeCurrency: {
|
||||
name: 'MATIC',
|
||||
symbol: 'MATIC',
|
||||
|
Loading…
Reference in New Issue
Block a user