Commit e12e8976 authored by Murphy Law's avatar Murphy Law Committed by GitHub

dtl: Use Basic Auth in L1TransportServer (#2439)

parent e420ca7d
---
'@eth-optimism/data-transport-layer': patch
---
Use Basic Authentication in L1TransportServer
...@@ -93,12 +93,22 @@ export class L1TransportServer extends BaseService<L1TransportServerOptions> { ...@@ -93,12 +93,22 @@ export class L1TransportServer extends BaseService<L1TransportServerOptions> {
this.state.l1RpcProvider = this.state.l1RpcProvider =
typeof this.options.l1RpcProvider === 'string' typeof this.options.l1RpcProvider === 'string'
? new JsonRpcProvider(this.options.l1RpcProvider) ? new JsonRpcProvider({
url: this.options.l1RpcProvider,
user: this.options.l1RpcProviderUser,
password: this.options.l1RpcProviderPassword,
headers: { 'User-Agent': 'data-transport-layer' },
})
: this.options.l1RpcProvider : this.options.l1RpcProvider
this.state.l2RpcProvider = this.state.l2RpcProvider =
typeof this.options.l2RpcProvider === 'string' typeof this.options.l2RpcProvider === 'string'
? new JsonRpcProvider(this.options.l2RpcProvider) ? new JsonRpcProvider({
url: this.options.l2RpcProvider,
user: this.options.l2RpcProviderUser,
password: this.options.l2RpcProviderPassword,
headers: { 'User-Agent': 'data-transport-layer' },
})
: this.options.l2RpcProvider : this.options.l2RpcProvider
this._initializeApp() this._initializeApp()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment