
356 N.W.2d 541 (1984)
Fay Monroe VAN METER, Plaintiff,
v.
The Honorable Paul E. HELLWEGE, Judge of the District Court of Iowa in and for Webster County, Defendant.
No. 83-323.
Supreme Court of Iowa.
October 17, 1984.
*542 Keith Ferguson, Dayton, for plaintiff.
Thomas J. Miller, Atty. Gen., Teresa Baustian, Asst. Atty. Gen., and Catherine Tinker, County Atty., for defendant.
Considered by UHLENHOPP, P.J., and McGIVERIN, LARSON, SCHULTZ, and WOLLE, JJ.
McGIVERIN, Justice.
Plaintiff Fay Monroe Van Meter challenges, by petition for writ of certiorari, defendant district court's finding of contempt of court and imposition of a six month jail sentence for the contempt. We conclude that, although the court was exercising a judicial function, the contempt finding and the imposition of the sentence were erroneous acts, and so we sustain the writ and remand for a new hearing on the issue of whether Van Meter was in contempt.
On February 15, 1979, Van Meter was permanently enjoined by the Iowa district court in Lee County from bringing any new legal action or proceeding against certain state and county employees in the Iowa court system. The court in that proceeding appointed counsel to represent Van Meter, but noted in its decree that he refused the presence and assistance of that counsel and instead appeared on his own behalf and presented his own case.
Thereafter, Van Meter brought additional actions against certain public employees in district court in Webster County. The State instituted contempt proceedings in that district court, contending that Van Meter had violated the 1979 injunction.
On August 20, 1980, Van Meter was adjudicated in contempt by the district court in Webster County, Judge B.C. Sullivan presiding, for violating the injunction. At the beginning of the contempt trial, Van Meter's court-appointed counsel withdrew, alleging that Van Meter would not accept his advice. The trial proceeded without counsel representing Van Meter.
Van Meter was sentenced to six months in jail based on the contempt finding. He petitioned this court for writ of certiorari, which was denied. He then sought post-conviction relief in district court, which was denied. He appealed that denial to this court, which treated the appeal as an amendment to his previous petition for writ of certiorari, and granted certiorari for review with respect to (1) the validity of the injunction against him and (2) whether he had been improperly denied counsel at the contempt hearing.
On October 27, 1982, in an unpublished per curiam opinion, Van Meter v. Iowa District Court, 327 N.W.2d 238 (Iowa 1982) (table), we affirmed the validity of the injunction, but found that plaintiff had been denied counsel at the contempt hearing. We reversed the contempt proceedings and judgment, vacated the sentence, and remanded the case for further proceedings *543 in which he would be provided with counsel.
On January 21, 1983, on remand, a contempt hearing was held, Judge Sullivan again presiding. Van Meter was provided with counsel. At the hearing Van Meter's counsel asked if this was a retrial of the contempt proceeding and stated he did not know the evidence of the alleged contempt. The attorney also pointed out that Van Meter had no attorney to question any evidence presented at the initial 1980 hearing.
The court prescribed the parameters of the hearing and stated its understanding that only the sentence had been set aside by the supreme court opinion, and that the evidence and finding of the 1980 contempt proceeding remained valid and in the record. The court pointed out that Van Meter's counsel had a transcript of the prior contempt proceeding. Counsel also acknowledged seeing the documentary evidence in that record.
In behalf of Van Meter, his counsel said he would not enter a plea or present evidence.
At the hearing, therefore, no direct evidence of plaintiff's contempt was introduced by the State. Instead, the court noted that at the August 20, 1980 hearing, it had adjudicated Van Meter in contempt, and stated that nothing had happened since then to alter its conclusion that Van Meter was in contempt. Accordingly, the court again found Van Meter in contempt. Judge Sullivan then disqualified himself from the matter of sentencing.
On March 22, 1983, Van Meter was sentenced by the district court, Judge Paul E. Hellwege presiding, to six months in jail for his contempt and given credit for the six months he had earlier voluntarily served pursuant to his 1980 contempt sentence. Van Meter then petitioned this court for review of the sentence and proceeding by writ of certiorari. We granted the writ.
"Certiorari, unless specifically authorized by statute, lies only when the inferior court or tribunal, exercising judicial functions, is alleged to have exceeded its proper jurisdiction or otherwise acted illegally." Iowa R.Civ.P. 306; City of Webster City v. Draheim, 292 N.W.2d 406, 407 (Iowa 1980).
I. The remanded contempt proceedings. The issue presented for our review is whether the district court acted erroneously at the January 1983 remanded contempt hearing in finding Van Meter to be in contempt without allowing a new trial on the contempt issue and requiring the State to present evidence anew. Had the State been required to produce evidence, Van Meter's counsel, who did not represent him at the 1980 hearing, would have had the opportunity to object to the evidence as it was offered. Van Meter could also have presented evidence. The district court at the January 1983 hearing apparently concluded that the August 1980 contempt adjudication was still valid and that the only matter before it was the resentencing of Van Meter. It, therefore, found Van Meter in contempt on the basis of the 1980 adjudication and its supporting evidence without requiring or allowing the State to submit any evidence of contempt. We agree with plaintiff that this was an erroneous act by the court. The later sentence based on the erroneous contempt finding cannot stand.
In our per curiam opinion of October 27, 1982, we found that plaintiff had been denied counsel at the 1980 adjudication. The denial of counsel mandated a reversal for a new hearing. See State v. Ware, 205 N.W.2d 700, 704 (Iowa 1973). The case was accordingly remanded for further proceedings. It was not only the sentence for contempt that was vacated, but the underlying adjudication of contempt as well, because the denial of counsel was a denial of due process that deprived the court of jurisdiction to make the adjudication. See Johnson v. Zerbst, 304 U.S. 458, 468, 58 S.Ct. 1019, 1024, 82 L.Ed. 1461, 1468 (1938); McNabb v. Osmundson, 315 N.W.2d 9, 14 (Iowa 1982).
On remand, it was the duty of the district court to allow and hear the evidence anew and make an adjudication as though the 1980 adjudication had never *544 taken place. This was not done. The court heard no evidence and instead relied entirely upon the 1980 adjudication for its finding of contempt. The court misunderstood the type of hearing to be held on remand. The district court acted erroneously in adjudicating plaintiff to be in contempt under this record. See Lane v. Oxberger, 224 N.W.2d 245, 247 (Iowa 1974). The six month jail sentence based on the adjudication, also, cannot stand.
The writ of certiorari is sustained. The case is remanded for a full evidentiary hearing on the issue of plaintiff's alleged contempt, which proceeding shall be in conformance with Iowa Code ch. 665.
II. Burden of production. Because the issue is likely to arise on remand, we address a question raised by Van Meter in his brief regarding the burden of producing certain evidence.
The 1979 injunction against commencement by Van Meter of new legal proceedings against certain state and county employees contained a provision by which the injunction could be modified, upon petition by Van Meter, to permit commencement of a particular proceeding. Van Meter contends that, in order to support a finding of contempt for violation of the injunction, the State must show not only that he began a legal proceeding of the type proscribed by the injunction, but also that the injunction had not been modified so as to permit such proceeding. The State, on the other hand, maintains that modification of the injunction is in the nature of an affirmative defense and that Van Meter bears the burden of producing evidence on the issue before the State need address it.
We agree with the State's position on this question. Because any facts relating to a modification of the injunction are peculiarly within Van Meter's knowledge, but considerably more difficult for the State to ascertain, we believe that the intent of the enjoining court was to make modification of the injunction an affirmative defense. See State v. Gibbs, 239 N.W.2d 866, 868 (Iowa 1976). Van Meter, therefore, has the burden of production on this issue. The State, however, retains the ultimate burden of persuading the court that Van Meter violated the injunction notwithstanding any modification of it that he is able to show.[1]See Skinner v. Ruigh, 351 N.W.2d 182, 185 (Iowa 1984).
Although the district court acted within its proper judicial function, it acted erroneously in interpreting the scope of the hearing on the remand. Therefore, the writ of certiorari is sustained and the case is remanded for a new hearing on the issue of Van Meter's alleged contempt.
WRIT SUSTAINED.
NOTES
[1]  We express no opinion as to the quantum of proof required for a finding of contempt. Although our prior cases have stated that clear and satisfactory proof is required, decisions from other courts suggest that proof beyond a reasonable doubt is necessary to support an adjudication of contempt. See Skinner v. Ruigh, 351 N.W.2d 182, 185 n. 1 (Iowa 1984).
