—Order unanimously modified on the law and as modified affirmed with costs to plaintiff in accordance with the following Memorandum: Plaintiff, a subcontractor, provided labor and materials for the construction of a residential subdivision owned by defendant W. James Camperlino. Thereafter, plaintiff brought an action against Camperlino for breach of contract and unjust enrichment and against defendant United States Fidelity & *1098Guaranty Company (USF&G) for judgment on the bond issued by USF&G that Camperlino had posted to release plaintiff’s mechanic’s lien. On a prior appeal, we modified an order denying defendants’ motion for summary judgment by granting summary judgment dismissing plaintiff’s causes of action for breach of contract and unjust enrichment against Camperlino (Worlock Paving Corp. v Camperlino, 207 AD2d 975). Defendants then moved for summary judgment dismissing plaintiff’s remaining cause of action on the bond. Supreme Court granted their motion on the ground that there remained no basis upon which plaintiff could recover.
In order for plaintiff to recover on the bond, it need only establish that it has a valid mechanic’s lien. Where a mechanic’s lien on real property has been discharged by the filing of a security bond, a judgment in favor of the lienor in an action brought to enforce the lien, although not a judgment of foreclosure, is, nevertheless, a judgment against the property. Because the mechanic’s lien no longer attaches to the real property, "the judgment is against the property only as a matter of form. The decree may adjudge that the plaintiff has a good and valid lien for a specified amount, and that but for the filing of the bond the plaintiff would be entitled to a judgment of foreclosure” (77 NY Jur 2d, Mechanics’ Liens, § 318, at 52; see, Louis J. Sigl, Inc. v Wertheimer, 223 App Div 806, affd 250 NY 605).
Further, a subcontractor need not be in contractual privity with the property owner in order to foreclose on its mechanic’s lien (see, Kuhn v Kober, 203 AD2d 536; Rainbow Elec. Co. v Bloom, 132 AD2d 539). The subcontractor may recover up to the amount owed to the general contractor by the owner at the time the lien was filed (see, 76 NY Jur 2d, Mechanics’ Liens, § 21). Therefore, the court erred when it held that there must be an independent substantive cause of action to enable plaintiff to recover on the bond.
We, therefore, modify the order on appeal by denying the motion of defendants to dismiss the complaint and to vacate, cancel and discharge the bond, and by reinstating the complaint insofar as it seeks judgment on the bond. (Appeal from Order of Supreme Court, Onondaga County, Major, J. — Summary Judgment.) Present — Lawton, J. P., Wesley, Davis and Boehm, JJ.