Open c4-submissions opened 11 months ago
Picodes marked the issue as primary issue
dyedm1 (sponsor) disputed
This seems like a feature request rather than an actual issue. Although this mechanism is indeed described as similar to vega in options to help readers get an idea, the intended effect is to keep the liquidity utilization in check by increasing the premium multiplier when there is more demand for options buying than selling. Additionally, there is a disclaimer about the opinionated nature of this mechanism, noting that it may not be a fit for all protocols: https://github.com/code-423n4/2023-11-panoptic/blob/aa86461c9d6e60ef75ed5a1fe36a748b952c8666/contracts/SemiFungiblePositionManager.sol#L282
As long as the relationship between the premium multiplier and liquidity utilization holds as documented, there is no issue here.
Picodes changed the severity to QA (Quality Assurance)
Picodes marked the issue as grade-b
Lines of code
https://github.com/code-423n4/2023-11-panoptic/blob/f75d07c345fd795f907385868c39bafcd6a56624/contracts/SemiFungiblePositionManager.sol#L130-L135 https://github.com/code-423n4/2023-11-panoptic/blob/f75d07c345fd795f907385868c39bafcd6a56624/contracts/SemiFungiblePositionManager.sol#L1250-L1329
Vulnerability details
Impact
The
SemiFungiblePositionManager.sol
contract employs a fixed parameter,VEGOID
, assigned a constant value of 2:uint128 private constant VEGOID = 2
used in calculating premiums associated with liquidity utilization. This parameter acts as a multiplier, adjusting the sensitivity of premium calculations to changes in liquidity, akin to Vega in options.In financial terms, Vega (or VEGOID in this context) measures the sensitivity of an option's price to changes in implied volatility. However, the fixed nature of VEGOID overlooks the dynamic nature of market conditions where volatility (liquidity sensitivity) can vary significantly.
Implied volatility (IV) is a key determinant in options pricing, representing the market's estimation of an asset's future volatility. A higher IV signifies increased uncertainty regarding an asset's price, usually leading to higher option premiums. Vega, in turn, measures an option's price sensitivity concerning a 1% change in implied volatility. It is pivotal for assessing an option's potential to gain value before expiration.
https://www.sciencedirect.com/topics/mathematics/implied-volatility#:~:text=Implied%20volatility%20is%20calculated%20by,price%20of%20the%20option%2C%20for
https://corporatefinanceinstitute.com/resources/derivatives/vega/
So, the fixed
VEGOID
parameter overlooks the dynamic nature of implied volatility, leading to significant repercussions in options pricing:VEGOID
parameter for changing market conditions could result in mispriced premiums, potentially causing financial losses for users.Proof of Concept
The function that updates the Owed and Gross account liquidities:
Tools Used
Manual review.
Recommended Mitigation Steps
Short term: Implement an adjustable
VEGOID
within defined limits, allowing authorized entities to update it based on observed market conditions. Long Term: Develop algorithms to adaptively adjustVEGOID
concerning observed liquidity changes or shifts in market volatility and establish transparent guidelines forVEGOID
updates and educate stakeholders about its pivotal role in pricing accuracy, e.g here:https://panoptic.xyz/research/streamia-vs-black-scholes
Assessed type
Other