I. The provisions of the ordinance in question involved in this action are as follows:
i. MCTmciPAi, corporation: powers of. “ Sec. 1. Be it ordained by the mayor and council of the city of Newton that it shall be unlawful for any person by himself, his clerk, servant or agent, for himself, . , . . or lor any person else, to keep any beer or wine for sale within the limits of the city of Newton, unless where the sale of said liquors is permitted by the board of supervisors of Jasper county. .
“Sec. 4. If any credible resident of the city of Newton shall, before the mayor, or any justice of the peace in said city, make written affidavit that he or she has reason to believe, or does believe, that any of the liquors mentioned in section one hereof is, in any place described as particularly as may be, kept or owned by any person with intent to be sold in violation of section one hereof, then said mayor or justice of the peace shall, upon finding probable cause for said belief, issue his warrant of search, directed to the marshal of said city, or to any other peace officer, describing as nearly as may be the place to be searched, the liquors in the *380information, and tbe person, named as tlie owner or keeper of said liquors, and commanding said officer to thoroughly search said place for said liquor, and, in case he find any, to seize it and the vessels containing it, and retain the same until disposed of, as hereinafter provided.
“ See. 5. Whenever, upon such warrant, any such liquors shall bo seized the mayor or justice who issued the warrant shall cause a notice to be posted up at some conspicuous place where said liquor was seized, and also a copy thereof to be left with or at the usual place of residence, if in this city, of the person named in said information as the owner or keeper of said liquor, summoning such person, and all others whom it may concern, to appear before said mayor or justice at a time not less than five nor more than fifteen days from the posting and leaving of said notice, and show cause, if any they have, why said liquor, and vessels containing it, should not be forfeited; the notice shall also describe said liquors and vessels, and state when, where and why the same were seized. At the time named in said notice any person claiming any part of said liquors or vessels may appear and be made a party defendant in said case, and show cause why said liquor should not be forfeited. A trial shall be had, conducted as near as may be in ordinary cases of misdemeanor, in which the defendant may demand a jury. Whether any person appears as defendant or not the mayor or justice shall, at the prescribed time, proceed to the trial of said cause, and the complainant may, and, in his default, the officer having the liquor shall, appear and prosecute said information.
“See. 6. Whenever, under a search warrant, judgment of condemnation against any beer or wine has been rendered, it shall be the duty of the officer who served said warrant to file at once information against the person or persons in whose possession it 'was found, or against the person claiming to be the owner of said liquor, charging him with a violation of section one hereof.
“ Sec. 7. Any person convicted of a violation of this ordi*381nance shall be fined fifty dollars, and costs of suit, and shall stand committed to jail until the same is paid, not exceeding thirty days. Eor each subsequent offense he shall pay a fine of one hundred dollars, and costs of suit, and shall stand committed until the same is paid, not exceeding thirty days.
“Sec. 8. Ordinance No. 40, passed August Ttli, 1872, is hereby repealed.”
It is claimed that these provisions are void for the reason that no power to enact them has been by the State delegated to municipal corporations. “ It is a general and undisputed proposition of law that a municipal corporation possesses, and can exercise, the following powers, and no others: First, those granted in express words. Second, those necessarily or.fairly impl/ied in or incident to the.powers expressly granted. Third, those essential to the declared objects and purposes of the corporation, not simply convenient, but indispensable.” 1 Dillon on Municipal Corporations, p. 173, and authorities cited.
Section 463 of the Code confers upon a municipal corporation power “ to regulate or prohibit the sale of intoxicating liquors not prohibited by the laws of this State.” It cannot be claimed that this section, in express words, confers upon a municipal corporation authority to search for and destroy liquors kept for sale in violation of an ordinance prohibiting their sale. It must be admitted also, we think, that this power is not essential, that is indispensable, to the declared objects and purposes of a municipal corporation. It remains to be seen whether it is necessarily or fairly implied in or incident to the power conferred of prohibiting the sale of intoxicating liquors not prohibited by the laws of the State. It has been quite uniformly held that a municipal corporation has no authority to pass an ordinance creating a forfeiture of goods and chattels as a penalty for violating its by-laws or ordinances, unless such powers are expressly granted by its charter.
In White v. Tallman, 2 Dutcher, 67, it was held that an *382ordinance of a municipal corporation providing for the forfeiture of impounded animals for the benefit of the borough, by reason of the failure of the owner to claim them within a specified time, was void.
In Cutler v. Doty, 5 Ohio, 245, it was held that the city of Cincinnati had no power to declare a forfeiture of gunpowder, brought within the city in violation of an ordinance,' although.the act of incorporation conferred upon the city authority “ to impose reasonable fines on all persons offending against the laws and ordinances aforesaid, and to cause all such fines and all such forfeit/iores and penalties as may be incurred, under the laws and ordinances of the corporation, to be assessed, levied and collected, in such manner as they may prescribe.” The court say: “That the city council, under the law of 1815, liad the power to pass a law to prevent large quantities of gunpowder from being kept in the city, we have no doubt. For offending against an ordinance of this description they might impose fines. With equal propriety they might provide for its removal to a safe place without .the limits of the corporation. But they have not the power to declare it forfeited, nor the right when it is removed to withhold it from the owner.”
In Miles v. Chamberlain, 17 Wis., 446, it was held that towns in that state have no authority to provide for the impounding and sale of animals found running at large. The court say: Section 3, of chapter 15, Revised Statutes, while it confers on towns the authority to make by-laws to restrain animals from running at large, very clearly indicates the means by which those by-laws are to be enforced, that is by imposing penalties upon the owner. Providing this means, by implication, excludes all others.” The case of Hart v. The Mayor of Albany, 9 Wend., 570, recognizes the same doctrine.
In Phillips v. Allen, 41 Penn. St., 481, where a city ordinance required that baskets used for the sale of fruit and vegetables should have the fractional parts of a bushel con*383tained in each marked or stamped thereon, or else to be forfeited with contents, and the clerk of the city market seized several baskets of apples and forfeited them as offered for sale in unmarked baskets, it was held that as no act of the legislature expressly authorized the forfeiture, the city council had no power to inflict that penalty for the violation of the ordinance.
The appellee, however, contends that express authority has been conferred upon the municipality to pass the provisions of the ordinance in question. In addition to section 463 of the Code, to which reference has already been made, the appellee cites and relies upon sections 456 and 482 of the Code. Section 456 authorizes a city to prevent nuisances, riots, gaming houses, etc.
Section 482 is as follows: “Municipal corporations shall have power to make and publish, from time to time, ordinances not inconsistent with the laws of the state, for carrying into effect or discharging the powers and duties conferred by this chapter, and such as shall seem necessary and proper to provide for the safety, preserve the health, promote the prosperity, improve the morals, order, comfort and convenience of such corporation and the inhabitants thereof, and tQ enforce obedience to such ordinances by fine not exceeding one hundred dollars, or by imprisonment not exceeding thirty days.”
It is to be observed, however, that this section provides a specific mode for enforcing obedience to such ordinances as a municipal corporation may enact. That mode is by fine not exceeding one hundred dollars, or by imprisonment not exceeding thirty days. No authority is expressly conferred to declare a forfeiture for the purpose of enforcing an ordinance. Upon the contrary, the provision that obedience may be enforced by fine or imprisonment, by implication, excludes all other means. Miles v. Chamberlain, supra. It is further to be observed that section 463 of the Code simply authorizes a municipal corporation to regulate or prohibit the sale of *384intoxicating liquors not prohibited by the laws of the state, whilst the sections of the ordinance under consideration seeks to punish the keeping of such liquors with intent to sell, which is an. offense altogether different and distinct. We feel constrained to hold that the city oí Newton had no authority to pass the provisions of the ordinance in question. See The City of Chariton v. Barber, 54 Iowa, 360.
^ 2. JUSTICE Of cMipiiaMiíty mentoi’vofd ordmance. II. The provisions of the ordinance in question being void for want of authority of the municipal corporation to enact them, is the justice of the peace who at-J tempted t° enforce them liable to an action as a trespasser? The law is well settled that a judicjai officer, acting within his jurisdiction, enjoys absolute immunity from liability in a civil action for mistake of law or error in judgment. 2 Hilliard on Torts, 101; Cooley on Torts, 403.
In a note to page 409 (Cooley on Torts) it is said: “ There are dicta in some cas.es that a justice is civilly responsible when he acts maliciously or corruptly, but they are not well founded, and the express decisions are against them.” See Jones v. Brown, 54 Iowa, 74; Green v. Talbot, 36 Iowa, 499; Howe v. Mason, 14 Iowa, 510; Gowing v. Gowgill, 12 Iowa, 495; Wasson v. Mitchell, 18 Iowa, 153; Lancaster v. Lane, 19 Ill., 242; Adkins v. Brewer, 5 Cowen, 206; Pratt v. Gardner, 2 Cush., 63; Yates v. Lansing, 5 Johns., 282; s. c., 9 Johns., 395.
In order that this immunity may be enjoyed it is necessary that the judicial officer shall have jurisdiction in the premises. 2 Hilliard on Torts, 119, and authorities cited; Adkins v. Brewer, 5 Cowen, 206; Lancaster v. Lane, 19 Ill., 241.
In Cooley on Torts, page 419,' it is said: “ It is universally conceded that when inferior courts or judicial officers act without jurisdiction the law can give them no protection whatever. Recently, however, the rule has been held to be otherwise in the case of judges of the superior courts where the error consisted in exceeding their authority. The par*385ticular case was one in which the judge, sitting in one court, ordered the name of an attorney to be stricken from- the rolls for contempt of authority committed in another court of' which the judge was also a member. It was held by the Federal Supreme Court that he was not responsible for this error. Bradley v. Fisher, 13 Wall., 335. Had it been a justice of the peace who had committed a like error an action would have been supported, however honest might have been his motives, and however plainly it might have appeared that he was intending to'keep within his powers.”
Whether a rule is just which affords immunity to the judge of a superior court, who from his position and presumed learning ought to be most free from error, whilst it holds an inferior judicial officer liable, we need not now determine.
In Kelly v. Bemis, 4 Gray, 83, it was held that a justice of the peace who issued a warrant under an unconstitutional law was liable in damages to the person arrested thereon.This is the only case which we have found that goes to this extreme length, and the doctrine, notwithstanding the learning and ability of the court by which it was pronounced, does not meet our approval. When the information was presented to the justice in this case all the matters pertaining to his'right to'issue a warrant were properly brought within his jurisdiction. He was called upon to exercise judicial powers. If the ordinance was valid it was his duty to issue a warrant. A refusal to do so would be a disregard of the obligations imposed upon him by his office. He could justify'his refusal only upon the ground that the ordinance was invalid. He was thus called upon to pass judicially upon the validity of the ordinance. In making this determination he acted strictly within his jurisdiction. An erroneous decision upon the subject is a mere mistake in judgment for which he ought not to be held responsible. If a judge of a Circuit or a District Court had committed a like error it would hardly be claimed that he would be liable to a civil action. There is neither reason nor justice, it seems to us, *386in holding a justice of the peace liable to a civil action for such an error in judgment.
III. The warrant upon which the defendant McCord acted is not set out in the record, and it is presumed to be regular on its face. As the justice of the peace had jurisdiction, and, in the exercise of that jurisdiction, simply erred in judgment, the ministerial officer executing the process is protected from civil liability. 2 Hilliard on Torts, 125; Clark v. May, 2 Gray, 410. As the defendants are not liable to a civil action under the facts alleged, the demurrers were properly sustained.
Aeeirmbd.