Upon confirmation of the sale, the clerk of the district court shall certify to the county treasurer the year or years of the taxes for which the real property was sold. The county treasurer shall thereupon cancel the taxes for such years, and the proceedings shall operate as a release of such real property from all liens for the taxes included on the real property. The delivery of the sheriff's deed shall pass title to the purchaser free and clear of all liens and interests of all persons who were parties to the proceedings, who received service of process, and over whom the court had jurisdiction, excluding any lien on real estate for special assessments levied by any sanitary and improvement district which special assessments have not been previously offered for sale by the county treasurer.