
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
gearbox-contracts
Advanced tools
This repository contains the smart contracts source code for Gearbox Protocol V2.
Gearbox is a generalized leverage protocol: it allows you to take leverage in one place and then use it across various DeFi protocols and platforms in a composable way. The protocol has two sides to it: passive liquidity providers who earn higher APY by providing liquidity; active traders, farmers, or even other protocols who can borrow those assets to trade or farm with x4+ leverage.
Gearbox protocol is a Marketmake ETHGlobal hackathon finalist.
This repository is subject to the Gearbox bug bounty program, per the terms defined here.
General documentation of the Gearbox Protocol can be found here. Developer documentation with more tech-related infromation about the protocol, contract interfaces, integration guides and audits is available on the Gearbox dev protal.
To install TS dependencies, run npm install
.
Running Forge unit tests requires Foundry. See Foundry Book for installation details.
forge test
yarn build
;yarn fork
(it is recommended to set a fixed starting block with --fork-block-number
, to speed up deployment in subsequent runs);yarn test <PATH_TO_TEST> --network localhost
.It is recommended to restart the fork before running a new test file. Different tests within a single file will work on a single fork instance.
An additional suite of Python-based tests was provided as a result of an audit from Sigma Prime. To install the Python dependencies, run
pip install -r requirements.txt
then
brownie test
to run tests.
The primary license for the Gearbox-Contracts is the Business Source License 1.1 (BUSL-1.1), see LICENSE. The files licensed under the BUSL-1.1 have appropriate SPDX headers.
contracts/adapters
, contracts/fuzzing
, contracts/interfaces
, contracts/support
are licensed under GPL-2.0-or-later.contracts/libraries
are licensed under GPL-2.0-or-later or GNU AGPL 3.0 (as indicated in their SPDX headers).contracts/integrations
are either licensed under GPL-2.0-or-later or unlicensed (as indicated in their SPDX headers).contracts/tokens/GearToken.sol
is based on Uni.sol
and distributed under the BSD 3-clause license.audits
, scripts
, test
, contracts/mocks
are unlicensed.This application is provided "as is" and "with all faults." Me as developer makes no representations or warranties of any kind concerning the safety, suitability, lack of viruses, inaccuracies, typographical errors, or other harmful components of this software. There are inherent dangers in the use of any software, and you are solely responsible for determining whether this software product is compatible with your equipment and other software installed on your equipment. You are also solely responsible for the protection of your equipment and backup of your data, and THE PROVIDER will not be liable for any damages you may suffer in connection with using, modifying, or distributing this software product.
FAQs
Core smart contracts of Gearbox V1
The npm package gearbox-contracts receives a total of 0 weekly downloads. As such, gearbox-contracts popularity was classified as not popular.
We found that gearbox-contracts demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.