delivered the opinion of the court:
This is an appeal from an order of the circuit court of Alexander County • finding appellants, a criminal defendant and his lawyer, in contempt of court. Appellants were each prosecuted on three counts of a rule to show cause, charging that their refusal to cooperate fully with the preparation of a presentence report and their filing of a civil action against the presiding judge were contemptuous.
By jury verdict, appellant James Coleson was found guilty of two counts of perjury for falsification of an application for welfare benefits. Coleson, represented by appellant Dennis Hogan, did not testify at trial. The trial judge ordered a presentence investigation of Coleson, and ordered Coleson and Hogan to cooperate fully with the probation officer conducting the investigation. After post-trial motions were filed by Hogan on Coleson’s behalf, but prior to sentencing, appellants filed a civil suit against 1;hree judges of the circuit court and the State’s attorney of Alexander County for damages arising out of bail practices in the criminal proceedings against Coleson.
At an interview with the probation officer, Coleson provided certain background information, but on the advice of Hogan, refused to answer questions material to the perjury offense, asserting instead his rights under the first, fifth and sixth amendments to the United States Constitution. After a hearing on the post-trial motions, the trial judge was informed of appellants’ actions at the interview. He then ordered a second interview, *676ordered Coleson to respond to aU questions asked by the officer, ordered Hogan not to interfere, and warned both appeUants of possible contempt citations. The trial judge further stated that he was granting full and complete immunity to Coleson for aU information given to the probation officer. A second interview was held and again, on Hogan’s advice, Coleson refused to answer certain questions and refused to take a literacy test. Sentence for the perjury convictions was thereafter imposed by the trial judge.
A few days prior to sentencing, the trial judge filed a rule to show cause charging appeUants with contempt. Count I of the rule related to appeUants’ actions with respect to the presentence investigation, Counts II and HI related to the civil action in which the trial judge was named a defendant. Because of the action pending against him, the trial judge excused himself and another judge, who wiU hereafter be referred to as the “presiding judge,” presided over the contempt proceedings. AppeUants were adjudged in contempt of court on aU three counts. Hogan was fined *750 for each of the three counts, sentenced to three concurrent 30-day jail terms, and referred for possible disciplinary action to the Attorney Registration and Disciplinary Commission. Coleson was fined *100 for each count.
Under the statutes of the State of IUinois a sentencing court is required to order a presentence report for any defendant convicted of a felony, unless waived by the defendant. (Ill. Rev. Stat. 1973, ch. 38, par. 1005 — 3—1.) The purpose of the presentence report is to provide the court with information about the defendant so that sentence may be imposed, with the court being able to take into account not only the nature and circumstances of the offense but also the history and character of the defendant, his mental and physical condition, and his social situation. (Ill. Rev. Stat. 1973, ch. 38, par. 1005 — 3—2.) In the instant case, defendant Coleson chose to take advantage of his right to have the court impose an informed sentence, but without discussing certain matters with the investigating officer. Putting aside for a moment the validity of Coleson’s asserted privilege against self-incrimination, we are faced with the issue of the power of a sentencing court to order a defendant who does not waive the presentence report to communicate with an investigating probation officer. Does a defendant’s failure to waive the report amount to a waiver of any and all objections, legal or personal, that he may have to disclosing certain information?
There exists in this country a right to testimony, based in part on the sixth amendment’s right to confrontation and the right to subpoena witnesses, which has been characterized as necessary to the functioning of the courts and to the preservation of an orderly society. (Blair v. United States, 250 U.S. 273, 281, 63 L. Ed. 979, 982-83,39 S. Ct. 468, 471 (1919); *677Lilienthal, The Power of Governmental Agencies to Compel Testimony, 39 Harv. L. Rev. 694 (1926).) Based on one party’s right to testimony is the concomitant duty in another party to testify. And to effectuate the right to testimony, thus, to enforce the duty to testify, there exists the power to compel testimony. Without a right to testimony, or some governmental necessity, there can be no power to compel. Recognizing the burden of enforcing the duty to testify, Justice Homes stated, “[T]he power to require testimony is limited, as it usually is in English-speaking countries, at least, to the only cases where the sacrifice of privacy is necessary * o o ” (Harriman v. Interstate Commerce Com., 211 U.S. 407,419-20,53 L. Ed. 253, 263, 29 S. Ct. 115, 118 (1908).) And in order that the proper balance may be struck between the necessity for testimony and the policy of noninterference, the power to compel is possessed primarily by the judiciary. (Lilienthal, at 695; Wigmore, Evidence §2195 (1961).) Therefore, the power to compel testimony before an inferior judicial officer, such as the probation officer in this case, depends upon the existence of the power in superior court. Wigmore.
In the instant case the validity of the trial judge’s order that defendant Coleson communicate with the probation officer depends upon the court’s right to the information sought. We can conceive of no basis for such a right.1 T o the contrary, a defendant has the right to waive the entire presentence report. (Ill. Rev. Stat. 1973, ch. 38, par. 1005 — 3—1.) We do not believe that the lack of such a waiver magically creates a right in the court to probe the mind of the defendant or a governmental necessity for his testimony. Courts in other jurisdictions have stated that interrogation of a defendant by a sentencing court is improper after a verdict of guilty has been rendered by a jury. E.g., Heyward v. State, 161 med. 685,158 A. 897, 900-901 (1932).
Furthermore, the Supreme Court has held that at the sentencing stage a defendant still possesses basic due process rights. (Mempa v. Rhay, 389 U.S. 128, 19 L. Ed. 2d 336, 88 S. Ct. 254 (1967).) It is our conclusion that a defendant facing sentencing by an Illinois court has the right to be free from the burden of the duty to testify, unless there exists an overriding governmental necessity, or a right to his testimony, neither of which are present in this case.
Then too, it is clear that the defendant’s refusal to answer questions was justified under the fifth amendment privilege against self-incrimination. At the time of Coleson’s refusal to testify he had been adjudged guilty by a jury of the offense of perjury. The lower court apparently believed that as a result of the guilty verdict, Coleson’s fifth amendment privilege *678ceased. It is true that the removal of the possibility of incrimination, including a final adjudication of guilty, does eliminate the privilege. (Reina v. United States, 364 U.S. 507, 5 L. Ed. 2d 249, 81 S. Ct. 260 (1960).) But “[t]he conviction here was not final in several aspects. Sentence had not been imposed.” (People v. Hartley, 22 Ill. App. 3d 108, 109 (1974).) In Hartley the court held, with ample authority, that where a defendant had not been sentenced, post-trial motions were pending, and the time for appeal had not expired, the jury verdict was not a final conviction such as to extinguist the defendant’s fifth amendment privilege. A defendant is entitled to full protection from the effects of his testimony. (Halpin v. Scotti, 415 Ill. 104,108,112 N.E .2d 91 (1953).) Reina is clearly distinguishable from Hartley and the case at bar in that the contemnor in Reina was already serving a sentence and there is no indication in that case that any post-conviction remedies were being pursued.
A proper grant of immunity from the use of incriminating testimony can operate to extinguish a witness’s privilege against self-incrimination, and can be the basis for a valid order compelling his testimony. (Kastigar v. United States, 406 U.S. 441,32 L. Ed. 2d 212, 92 S. Ct. 1653 (1972).) The statutes of this State provide a procedure where under certain specified circumstances immunity can be granted to a witness and the witness compelled to testify. (Ill. Rev. Stat. 1973, ch. 38, par. 106—3.) Assuming, arguendo, that the presentence investigation is part of a trial, the immunity statute was not complied with in two important respects. First, the trial judge granted immunity to Coleson on its own motion rather than on motion of the State, and secondly, Coleson was the defendant, not a material witness. A grant of immunity under statutory authority must be in strict compliance with the terms of the statute. (People v. Rockola, 339 Ill. 474, 171 N.E. 559 (1930).) In Rockola the Supreme Court reversed a contempt adjudication which was based on a refusal to testify after an invalid grant of immunity. The statute in that case empowered the court to grant immunity in investigations or trials for certain specified offenses, including the crime of bribery. The grant of immunity was held invalid in Rockola because the offense charged in the trial was conspiracy to commit bribery, not the offense itself.
Having decided that the immunity granted by the trial judge was not within his statutory authority, there remains the question of a court’s inherent power to grant immunity. The courts of this State have no such power. (People v. English, 31 III. 2d 301, 201 N.E.2d 455 (1964).) The removal of the privilege against self-incrimination by a grant of immunity may only be accomplished by the legislature. (Apodaca v. Viramontes, 53 N.M. 514, 212 P.2d 425, 13 A.L.R.2d 1427 (1949); English. In the words of Judge Cardozo:
*679“The grant of an immunity is in very truth the assumption of a legislative power ° * *. It is the assumption of a power to annul as to individuals or classes the statutory law of crimes, to stem the course of justice, to absolve the grand jurors of the county from the performance of their duties, and the prosecuting officer from his.” Doyle v. Hofstader, 257 N.Y. 244, 261-62, 177 N.E. 489, 495 (1931).
Aside from the legal invalidity of the trial judge’s grant of immunity, the protection granted was wholly inadequate to protect the defendant against the effects of his statements. A grant of immunity, to be valid, must be co-extensive with the fifth amendment privilege it purports to remove. (Counselman v. Hitchcock, 142 U.S. 547, 35 L. Ed. 1110 (1892); Kastigar v. United States.) In this case the grant of immunity did not protect Coleson from the imposition of a harsher sentence as the result of his testimony, nor is it clear that the information obtained would not be used against him in the event of a retrial.
Another ground on which the lower court seems to have based its judgment are the disclosure limitations imposed upon information obtained in the presentence investigation. Such information may be provided to the sentencing judge, the prosecutor, officials of a penal institution, and anyone else “as ordered by the court.” (Ill. Rev. Stat. 1973, ch. 38, par. 1005—3—4.) We do not comprehend, and the State gives us no legal or logical suggestion, how limited disclosure could serve to remove the privilege against self-incrimination.
The fact the court ordered Coleson to communicate with the probation officer after overruling the fifth amendment plea does not affect the outcome of this case. As the State contends, all orders and judgments of courts must be complied with promptly, even if believed incorrect. (United States v. United Mine Workers of America, 330 U.S. 258, 91 L. Ed. 884, 67 S. Ct. 677 (1947).) But that general rule does not apply where the order is to reveal information which is asserted to be self-incriminating. (Maness v. Meyers, 419 U.S. 449, 464, 42 L. Ed. 2d 574, 586-87, 95 S. Ct. 584, 594 (1975).) The situation is different in that instance because of the possibility of irreparable injury from compliance. Thus, in the area of the fifth amendment, precompliance review may properly be sought, and if the privilege is later held to prevail, the violation of the order no longer supports a contempt citation. Maness v. Meyers.
The final ground on which Coleson’s privilege could have been extinguished is that the information obtained by the probation officer would not have been voluntarily provided, and thus subject to subsequent suppression.
In the words of Chief Justice Burger:
“Here the ‘cat’ was not yet ‘out of the bag’ and reliance upon a later objection or motion to suppress would ‘let the cat out’ with no *680assurance whatever of putting it back.” (Maness v. Meyers, 419 U.S. 449, 463, 42 L. Ed. 2d 574, 586, 95 S. Ct. 584, 593.)
(See also Ellis v. United States, 416 F.2d 791, 796 (D.C. Cir. 1969).) We cannot hold that a court may lawfully compel testimony because the compulsion would be the basis for a subsequent exclusion. Such circular reasoning would destroy the very protection which is guaranteed by the fifth amendment.
The final issue with which we are faced is whether a lawyer can be held in contempt of court for offering good faith advice to his client to disobey a court order. Since we hold that the advice given was correct, the judgment against Hogan must be reversed along with the judgment against Coleson. But we feel an obligation to go further than to base our decision as to attorney Hogan on that alone. It is extremely important that we express clearly and unequivocally that the contempt adjudication against Hogan would be reversed even if his advice were incorrect.
As a general rule, orders of courts must be complied with until reversed on appeal. (United States v. United Mine Workers, 330 U.S. 258, 91 L. Ed. 884, 67 S. Ct. 677 (1947).) Moreover, it is improper, and in certain circumstances contemptuous, for an attorney to advise a client to disobey a court order. (Maness v. Meyers, 419 U.S. 449, 42 L. Ed. 2d 574, 95 S. Ct. 584, 591 (1975).) “When a court * * * orders a witness to reveal information, however, a different situation may be presented.” (Maness v. Meyers, 419 U.S. 449, 460, 42 L. Ed. 2d 574, 584, 95 S. Ct. 584, 592.) The procedure counseled in this case was the ordinary and proper course for achieving precompliance review of a fifth amendment claim. (Maness v. Meyers, 419 U.S. 449, 462-63, 42 L. Ed. 2d 574, 585-86, 95 S. Ct. 584, 593.) We regard Maness as controlling on this issue, for the Supreme Court held that an attorney may not be penalized for good faith advice to disobey a court order on the ground of the fifth amendment privilege against self-incrimination. (Maness v. Meyers, 419 U.S. 449, 464-65, 42 L. Ed. 2d 574, 587, 95 S. Ct. 584, 594-95.)
The right to assistance of counsel in a criminal case is guaranteed by the sixth amendment to the United States Constitution and by article I, section 8 of the Illinois Constitution. Any restriction on the rights of a lawyer to give advice seriously impairs the constitutional right of a client to receive that advice, and denies the client due process of law. (Powell v. Alabama, 287 U.S. 45, 60, 69, 77 L. Ed. 158, 166, 170-71, 53 S. Ct. 55, 61, 64 (1932).) Contempt adjudications like the one below serve to chill the effective and unfettered representation which attorneys are bound to provide their clients. We would not hesitate to reverse the contempt adjudication of an attorney for offering a client good faith, albeit incorrect, advice to disobey an order for the disclosure of information, on the ground of the privilege against self-incrimination.
*681Appellants also contend that the evidence introduced at trial was not sufficient to support a finding of contempt under Counts II and HI of the rule to show cause. The trial judge alleged in Count II that because the civil complaint filed by the appellants against the circuit court and three of its judges, which was based on the theory that the circuit court had required Coleson to post excessive bail in the criminal proceeding, could have been filed after the sentencing of Coleson in the criminal proceeding, the filing of the complaint before the sentencing obstructed justice and was thus in contempt of the circuit court. The trial judge alleged in Count HI that because the complaint had no basis in fact or law, and because the complaint was not filed in good faith, but for the purpose of embarrassing the circuit court, the filing of the complaint was contemptuous.
Prior to Coleson’s indictment, substantial controversy had existed concerning bail procedures in Alexander County. This controversy had resulted in the filing of civil litigation in the United States District Court against some of the judges and other officials of Alexander County. The Court of Appeals for the Seventh Circuit ruled that a cause of action had been stated in that litigation. (Littleton v. Berbling, 468 F.2d 389 (7th Cir. 1972).) On review, the United States Supreme Court reversed, holding that the plaintiffs lacked standing in that most of them had never been charged with an offense. As to those plaintiffs who had been prosecuted in the past, the Supreme Court held that lacked standing to compláin because their prosecutions had terminated with the filing of suit. O’Shea v. Littleton, 414 U.S. 488, 38 L. Ed. 2d 674, 683, 94 S. Ct. 669 (1974); Spomer v. Littleton, 414 U.S. 514, 38 L. Ed. 2d 694, 94 S. Ct. 685 (1974).
Hogan claimed that prior to the time of Coleson’s sentencing, bail practices similar to those attacked in the O’Shea and Spomer litigation still existed. Essentially, Coleson alleged that he had been denied assistance of counsel at his bail hearing, had been placed under a *1000 bond, and had been denied the opportunity to show his entitlement to release on his own recognizance. It was Hogan’s stipulated testimony in the contempt hearing that after reading the United States Supreme Court cases of O’Shea v. Littleton and Spomer v. Littleton, he concluded that a plaintiff in a civil action challenging bail practices would lose standing to litigate once he was sentenced and his bail deposit returned.
With reference to Counts II and HI of the contempt citation, the presiding judge did not find that the complaint was contemptuous in and of itself because of the language used, but rather that it was totally lacking in merit; that it could have been filed after sentencing rather than before and therefore it was filed solely for the purpose of obstructing justice. The only evidence introduced to sustain the charges was a transcript of the criminal proceedings, the complaint in the civil proceeding and the *682verified rule to show cause filed by the trial judge. At the hearing before the presiding judge, the State agreed that the only evidence it had to prove that the complaint was not filed in good faith, but rather was filed to “disrupt or embarrass the court,” was the verified rule to show cause.
However, because the appellants were not charged with committing a direct criminal contempt in the physical presence of the judge, the trial judge’s verified rule to show cause was not evidence against the appellants. (See In re Oliver, 333 U.S. 257, 92 L. Ed. 682, 68 S. Ct. 499; People v. Skar, 30 Ill. 2d 491, 198 N.E.2d 101.) Therefore, if we are to sustain the trial court’s order, we must do so solely on the basis that the filing of the complaint prior to sentencing was filed with the intent to obstruct justice. We point out that contempt may be committed by incorporating impertinent, scandalous, insulting or contemptous language reflecting on the integrity of the court in pleadings, motions and notice of motions. (People v. Sherwin, 334 Ill. 609; People v. Richardson, 397 Ill. 84.) However, we further observe the trial court’s order did not find that there was any such language in the complaint. The trial court’s order must be sustained upon the ground on which it was imposed or not at all. People v. Miller, 51 Ill. 2d 76, 281 N.E.2d 292.
We are therefore not faced with a situation where language contained in the complaint is sufficient to furnish an evidentiary basis for a contempt conviction, but rather a situation where the State must prove beyond a reasonable doubt by extrinsic evidence that the defendant filed the complaint with intent to obstruct justice. The record reflects that the State introduced no evidence whatsoever in support of these charges other than the verified contempt citation.
This case was tried on the theory that it was an indirect contempt. In our opinion, the charges made against the defendant were not of indirect contempt, but rather of direct contempt committed in a constituent part of the court outside the presence of the judge.
There are two classes of direct contempt. One consists of acts that are performed in the physical presence of a judge, so that the judge sees and hears for himself all the elements of misconduct which are later charged against the defendant has having been contemptuous. The other category of direct contempt includes conduct which occurs before a constituent part of a court, but not in the physical presence of a judge. (In re Oliver; People v. Jashunsky, 51 Ill. 2d 220, 224, 282 N.E.2d 1, 3; People v. Skar.) Contemptous conduct that falls within the first category may be punished summarily by the judge. (In re Oliver; People v. Skar.) Allegedly contemptous behavior which falls within the second category of direct criminal contempt must be established by extrinsic evidence at a fair and impartial hearing. (In re Oliver; People v. Skar.) When a *683contempt of this kind is charged against a defendant, the State must prove beyond a reasonable doubt that the defendant commited the contempt. People v. Skar; People ex rel. Chicago Bar Association v. Barasch, 21 Ill. 2d 407, 412, 173 N.E.2d 417, 420; City of Chicago v. Hart Building Corp., 116 Ill. App. 2d 39, 253 N.E.2d 496.
The filing of documents with a court is behavior which occurs in the constructive presence of the court and is therefore a direct contempt of the second category if either the documents or the act of filing is regarded as contemptuous. (People v. Jashunsky; In re Estate of Kelly, 365 Ill. 174, 6 N.E.2d 113; People v. Andalman, 346 Ill. 149, 178 N.E. 412.) Thus the charges against the appeUants under Counts II and III of the rule to show cause, which were based on the filing of the complaint with the circuit court, should have been for a direct contempt of the second category instead of for an indirect contempt. The proof necessary to establish the contempt charges, however, is the same regardless of whether the charges are considered to be for an indirect contempt or a direct contempt of the second category, because extrinsic evidence is necessary to substantiate the charges under either theory.
The proceeding against the appeUants on the contempt charges was criminal, rather than civil, proceeding because the object of the proceeding was to punish the appellants. American Cyanamid Co. v. Rogers, 21 Ill. App. 3d 152, 314 N.E.2d 679; Eastman v. Dole, 213 Ill. App. 364.
A criminal contempt is a crime in every fundamental respect. (Bloom v. Illinois, 391 U.S. 194, 201 rev'g 35 Ill. 2d 255, 220 N.E.2d 475.) Because a criminal contempt is a crime, it consists of the two basic parts of a criminal offense; that is, a mens rea and an actus reus. The mens rea required for criminal contempt is an intent “to embarrass, hinder or obstruct a court in its administration of justice or to derogate from its authority or dignity, or bring the administration of law into disrepute.” (In re Estate of Melody, 42 Ill. 2d 451, 452, 248 N.E.2d 104; see also United States v. Seale, 461 F.2d 345 (7th Cir. 1972).) The actus reus of a criminal contempt is an act which does embarrass, hinder, or obstruct a court in the administration of justice. In re Estate of Melody; see also United States ex rel. Robson v. Oliver, 470 F.2d 10 (7th Cir. 1972).
In order to sustain the trial court’s order entered pursuant to Counts II and III of. the rule to show cause, the State had to prove beyond a reasonable doubt that the appeUants filed the civU complaint with the intent “to embarrass, hinder, or obstruct” the circuit court in the administration of justice. Since there is no valid evidence to support the trial court’s finding, the order of the trial court finding the defendants guüty on Counts II and III of the citation must also be reversed.
*684For the foregoing reasons the judgment of the circuit court of Alexander County finding the defendants guilty of contempt of court is reversed.
Judgment reversed.
CARTER, J., concurs.