; or (B) adjust the obligation under the lease to preserve the interests of all parties. (2) Relief to landlord If a court grants a stay under paragraph (1), the court may grant to the landlord (or other person with paramount title) such relief as equity may require. (c) Misdemeanor Except as provided in subsection (a), a person that knowingly takes part in an eviction or distress described in that subsection, or that knowingly attempts to take part in an eviction or distress described in that subsection, shall be fined as provided in title 18, United States Code, or imprisoned for not more than 1 year, or both. 7. Mortgage protection and foreclosures (a) Definition In this section, the term covered action means an action relating to an obligation— (1) with respect to real or personal property owned by a Federal worker; and (2) that— (A) originated before the date on which a shutdown begins; (B) is in effect on the date on which a shutdown begins; and (C) is secured by a mortgage, trust deed, or other security in the nature of a mortgage. (b) Stay of proceedings and adjustment of obligation If a covered action is filed in a court during a covered period, the court may, after a hearing and upon the motion of the court, and shall, upon application by the Federal worker if the ability of the Federal worker to comply with the covered obligation is materially affected by the shutdown— (1) stay the proceedings for a period of time as justice and equity require