
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@rsksmart/bridges-core-sdk
Advanced tools
Core module of all the RSK bridges SDKs that contains common functionality
This is the core module shared by all the bridges in the monorepo. This has common functionality such as logic to call the blockchain, HTTP client configuration, common valitadions and the configuration objects to initialize each bridges product.
This repo also contains a submodule which can be imported with the path @rsksmart/bridges-core-sdk/initialization
. That helps the user to initialize multiple bridges at once (have in count that every bridge package still provides its own contructor and ways to initialize it specificly).
To use core initialization you need to use the init()
function, provide the common configuration fields, and in the bridges
field add all the keys for the bridges you want to initialize, for each key the value that you'll provide is the specific configuration for that bridge or {}
if you want to initialize that bridge with its default configuration
// this would initialize flyover with custom config and tokenbridge with default config
const { flyover, tokenbridge } = await init({
network: 'Regtest',
allowInsecureConnections: true,
bridges: {
flyover: {
captchaTokenResolver: async () => Promise.resolve('')
},
tokenbridge: {}
}
})
One advantage of using initialization module is that you can lazy load the bridges. If you provide an unexisting bridge name the funciton will return and error. Also if you provide an existing bridge name but you don't have that package installed on your project the function will return and error.
This comes with one drawback, even when the SDK ensures that any lazy loaded bridge error is catched, you can find problems with some code bundlers that don't support external dependencies dynamic importing. If your bundler doesn't support that and you can't fix it via bundler configuration the only solution that you have is to install all the bridges packages even if you're not using them all. If your bundler does suport external dependency dynamic importing then you shouldn't have any problem.
If you need to connect to RSK to execute some operation then you need to create an RSKConnection and provide it to your bridge object
const rsk = await BlockchainConnection.createUsingStandard(window.ethereum)
const flyover = new Flyover({ rskConnection: rsk, network: 'Regtest' })
or you can set it after creation
const rsk = await BlockchainConnection.createUsingStandard(window.ethereum)
await flyover.connectToRsk(rsk)
There are multiple ways to create the connection, all of them are specified in the BlockchainConnection
class JSDocs
To see the full API of this package please refer to the the docs folder of this project
FAQs
Core module of all the RSK bridges SDKs that contains common functionality
We found that @rsksmart/bridges-core-sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.