If a levy has been made on property or property has been sold pursuant to a levy, any person (other than the person against whom is assessed the tax out of which such levy arose) who claims an interest in or lien on such property and that such property was wrongfully levied upon may bring a civil action against the United States in a district court of the United States. Such action may be brought without regard to whether such property has been surrendered to or sold by the Secretary.
If property has been sold pursuant to a levy, any person (other than the person against whom is assessed the tax out of which such levy arose) who claims an interest in or lien on such property junior to that of the United States and to be legally entitled to the surplus proceeds of such sale may bring a civil action against the United States in a district court of the United States.
If property has been sold pursuant to an agreement described in section 6325(b)(3) (relating to substitution of proceeds of sale), any person who claims to be legally entitled to all or any part of the amount held as a fund pursuant to such agreement may bring a civil action against the United States in a district court of the United States.
If a certificate of discharge is issued to any person under section 6325(b)(4) with respect to any property, such person may, within 120 days after the day on which such certificate is issued, bring a civil action against the United States in a district court of the United States for a determination of whether the value of the interest of the United States (if any) in such property is less than the value determined by the Secretary. No other action may be brought by such person for such a determination.
If a levy or sale would irreparably injure rights in property which the court determines to be superior to rights of the United States in such property, the court may grant an injunction to prohibit the enforcement of such levy or to prohibit such sale.
If the court determines that the interest or lien of any party to an action under this section was transferred to the proceeds of a sale of such property, the court may grant a judgment in an amount equal to all or any part of the amount of the surplus proceeds of such sale.
If the court determines that a party has an interest in or lien on the amount held as a fund pursuant to an agreement described in section 6325(b)(3) (relating to substitution of proceeds of sale), the court may grant a judgment in an amount equal to all or any part of the amount of such fund.
If the court determines that the Secretary’s determination of the value of the interest of the United States in the property for purposes of section 6325(b)(4) exceeds the actual value of such interest, the court shall grant a judgment ordering a refund of the amount deposited, and a release of the bond, to the extent that the aggregate of the amounts thereof exceeds such value determined by the court.
For purposes of an adjudication under this section, the assessment of tax upon which the interest or lien of the United States is based shall be conclusively presumed to be valid.
No action may be maintained against any officer or employee of the United States (or former officer or employee) or his personal representative with respect to any acts for which an action could be maintained under this section.
If an action, which could be brought against the United States under this section, is improperly brought against any officer or employee of the United States (or former officer or employee) or his personal representative, the court shall order, upon such terms as are just, that the pleadings be amended to substitute the United States as a party for such officer or employee as of the time such action was commenced upon proper service of process on the United States.
The provisions of section 7422(a) (relating to prohibition of suit prior to filing claim for refund) shall not apply to actions under this section.
The rules of section 7433(d) shall apply for purposes of this subsection.
Claims pursuant to this section shall be payable out of funds appropriated under section 1304 of title 31, United States Code.