Submitted by kenzo, also found by bardamu, csanuragjain, and IllIllI
Lenders mint function does not check whether the supplied market is paused.
Even if a market is paused due to insolvency/bugs, an attacker can issue iPTs.
This renders the whole pause and insolvency protection mechanism ineffective.  See POC.
Lets say market P has become insolvent, and Illuminate pauses that market, as it doesnt want to create further bad debt.
Lets say Ps principal tokenss value has declined severely in the market because of the insolvency.
An attacker can buy many worthless P principal tokens for cheap, then call Lender and mint from them iPT.
The attacker is now owed underlying which belongs to the legitimate users. There wont be enough funds to repay everybody.
Check in mint that the market is not paused.
sourabhmarathe (Illuminate) confirmed
