
904 P.2d 312 (1995)
79 Wash.App. 612
Steven DANZIG, an individual, Appellant,
v.
Jeffrey DANZIG and Jane Doe Danzig, husband and wife, d/b/a Jeffrey Danzig, Attorney at Law, P.S., a Washington corporation, Respondents and Cross Appellants.
Nos. 14057-1-III, 14118-7-III.
Court of Appeals of Washington, Division Three, Panel Two.
October 31, 1995.
Reconsideration Denied by Majority December 12, 1995.
*313 Barry E. Ryan, Kambra Lee Mellergaard, Spokane, for Appellant.
Eugene I. Annis, Bryce J. Wilcox, Lukins & Annis, Spokane, for Respondents.
MUNSON, Judge.
Steven Danzig appeals the dismissal of his contract claim against Jeffrey Danzig, Jeffrey's wife, and Jeffrey's law firm on a CR 12(b)(6) motion. Jeffrey, together with his wife and law firm, cross-appeal the trial court's order that he pay $89,000 of a legal fee into the registry of the court pending the investigation of the propriety of the fee. Jeffrey contends the court did not have jurisdiction to enter the order and that the order amounts to an unconstitutional taking of property. Jeffrey also argues Steven does not have standing to respond to his cross appeal. We hold Steven did state a claim upon which relief could be granted and reverse the dismissal of his claim. We hold the trial court lacked jurisdiction to order Jeffrey to pay the fee into the court registry and reverse the trial court's order.
In his complaint, Steven states he is not a lawyer and that Jeffrey is a lawyer, licensed in the State of Washington. Steven alleges Jeffrey approached him in January 1992 with a business proposition: for every client Steven steered into Jeffrey's office, Steven would receive one-third of any fee received. Steven states he accepted the offer and directed clients to Jeffrey. In each case, Jeffrey directed him to submit a billing statement making it appear as though he was billing for his time at an hourly rate. The total amount of the bill never deviated appreciably from one-third of the total fee. In each case, he was paid by Jeffrey.[1]
Steven maintains he directed a client to Jeffrey in March 1993; Jeffrey breached the agreement and refused to pay him. Steven states the one-third of the fee due him is about $89,000.
The trial court found the alleged contract was illegal and unenforceable under Washington law and dismissed Steven's claim with prejudice. Even though it dismissed Steven's claim, the trial court was concerned with the propriety of Jeffrey's fee and ordered him to pay $89,000 into the court registry pending an investigation of the fee. Jeffrey moved for reconsideration, but the motion *314 was denied. The trial court did, however, stay its order compelling Jeffrey to pay, pending this appeal.

The Appeal
Steven contends the trial court erred in granting Jeffrey's motion to dismiss under CR 12(b)(6). Under CR 12(b)(6), a defendant may move to dismiss where the plaintiff's pleadings do not state a claim upon which relief may be granted. Dismissal should be granted only where "it appears, beyond doubt, that the plaintiff can prove no set of facts in support of his claim which would entitle him to relief." Berge v. Gorton, 88 Wash.2d 756, 759, 567 P.2d 187 (1977). Facts alleged in the complaint must be accepted as true for purposes of the motion. Berge, 88 Wash.2d at 759, 567 P.2d 187. This court reviews de novo a dismissal under CR 12(b)(6). Cutler v. Phillips Petroleum Co., 124 Wash.2d 749, 755, 881 P.2d 216 (1994), cert. denied, ___ U.S. ___, 115 S.Ct. 2634, 132 L.Ed.2d 873 (1995).
As a general rule, contracts which are illegal or against public policy will not be enforced by the courts. See Golberg v. Sanglier, 96 Wash.2d 874, 883, 639 P.2d 1347, 647 P.2d 489 (1982). That rule, however, is subject to an exception where a court determines the parties are not in pari delicto, that is, they are not equally culpable. In those cases, a court may choose to enforce a contract despite the fact it is illegal or against public policy. As the court noted in Golberg, "in pari delicto" is only a label, and the decision to enforce a contract contrary to public policy requires more than just a weighing of fault and requires consideration of public policy. Golberg, 96 Wash.2d at 883, 639 P.2d 1347, 647 P.2d 489. As the court stated in Tri-Q, Inc. v. Sta-Hi Corp., 63 Cal.2d 199, 404 P.2d 486, 498, 45 Cal.Rptr. 878, 890 (1965):
Where, by applying the [general] rule, the public cannot be protected because the transaction has been completed, where no serious moral turpitude is involved, where the defendant is the one guilty of the greatest moral fault, and where to apply the rule will be to permit the defendant to be unjustly enriched at the expense of the plaintiff, the rule should not be applied.
Under the alleged contract, Steven was to serve as a "runner" who solicited clients for Jeffrey. Such a contract would be illegal, as to the lawyer, under RCW 9.12.010, Washington's barratry statute. In part, the statute provides that "every person, being an attorney or counselor at law, who shall personally, or through the agency of another, solicit employment as such attorney, in any suit pending or prospective ... shall be guilty of a misdemeanor...." RCW 9.12.010. The alleged agreement is also in violation of RPC 7.2(c) which states a "lawyer shall not give anything of value to a person for recommending the lawyer's services...." Agreements which violate the Rules of Professional Conduct are contrary to public policy. See Belli v. Shaw, 98 Wash.2d 569, 578, 657 P.2d 315 (1983); Walsh v. Brousseau, 62 Wash.App. 739, 815 P.2d 828 (1991).
Although Jeffrey argues RCW 9.12.010 criminalizes Steven's conduct, we would disagree. He cites to cases from other jurisdictions in which courts have refused to provide a remedy for breach of a contract to procure clients for an attorney. See Van Bergh v. Simons, 286 F.2d 325 (2d Cir.1961); Landi v. Arkules, 172 Ariz. 126, 835 P.2d 458 (App.1992); Dugas v. Summers, 339 So.2d 934 (La.Ct.App.1976), writ denied, 341 So.2d 1132 (1977); American Civil Liberties Union/Eastern Missouri Fund v. Miller, 803 S.W.2d 592 (Mo.), cert. denied, 500 U.S. 943, 111 S.Ct. 2239, 114 L.Ed.2d 481 (1991); Plumlee v. Paddock, 832 S.W.2d 757 (Tex.Ct. App.1992). The statutes at issue in those cases criminalized the conduct of the runner as well as that of the attorney. In contrast, the relevant language of RCW 9.12.010 clearly only addresses the conduct of attorneys. Likewise, the Rules of Professional Conduct apply only to those admitted to practice law in the State of Washington. In both cases, the prohibitions apply only to Jeffrey's conduct, not Steven's.
Jeffrey argues that Steven's admission in his complaint that he submitted billing statements falsely detailing hours worked is evidence of moral fault. Jeffrey maintains a reasonable person should have deduced the alleged contract was improper. While Steven's statement may be evidence of moral fault on his part, he may yet be able to prove *315 facts in support of his claim which entitle him to relief.
If a promisee is excusably ignorant of facts or of legislation of a minor character, of which the promisor is not excusably ignorant and in the absence of which the promise would be enforceable, the promisee has a claim for damages for its breach but cannot recover damages for anything he has done after he learns of the facts or legislation.
Restatement (Second) of Contracts § 180 (1979). Further, "[s]uch ignorance is more likely to be excusable where the legislation is of a local, specialized or technical nature and where the other party may be assumed to have knowledge as to such matters." Restatement (Second) of Contracts § 180 cmt. a (1979). Both RCW 9.12.010 and RPC 7.2(c) are specialized in that they address only the conduct of members of the legal profession. As an attorney, Jeffrey may be assumed to have knowledge of such matters.
Here, the conduct proscribed by RCW 9.12.010 and RPC 7.2(c) has already occurred. Refusing to enforce the sole remaining task under the alleged contract, payment of money, would not further protect the public. Jeffrey argues public policy would best be served by sending a message to potential runners that their efforts will not be rewarded. Knowing that disclosure of their unethical acts would almost certainly lead to disciplinary proceedings would serve a strong disincentive to attorneys considering an agreement like that at issue here. These issues cannot be resolved on a CR 12(b)(6) motion.
Finally, Jeffrey argues he did virtually all the work resulting in the fee at issue. However, if Steven's allegations are true, Jeffrey would not have even had the client if not for Steven's efforts.
Taken as true, the allegations in Steven's complaint state a claim upon which relief may be granted. The trial court erred in granting the CR 12(b)(6) motion to dismiss. Whether Steven can support those allegations in further proceedings remains to be seen.

The Cross-Appeal
Jeffrey contends the trial court did not have jurisdiction to order him to pay the $89,000 into the court registry. Jurisdiction over the subject matter of an action is a prerequisite to the exercise of judicial power. In re Buehl, 87 Wash.2d 649, 655, 555 P.2d 1334 (1976). "[T]he essential elements of jurisdiction are said to be three: (1) the court must have cognizance of the class of cases to which the one to be adjudicated belongs; (2) the proper parties must be present; and (3) the point decided must be, in substance and effect, within the issues before the court." State ex rel. New York Casualty Co. v. Superior Court, 31 Wash.2d 834, 840, 199 P.2d 581 (1948).
Jeffrey concedes the court had jurisdiction over Steven's contract claim. He argues, however, that once the court found Steven's claims devoid of merit and had dismissed the suit, it went beyond the issues before it when it ordered him to pay the money into the registry of the court. Although Steven argues the order arises from the issues in his complaint, the trial court's oral opinion[2] indicates the basis for the order was its concern over the propriety of the fee in the underlying case. In essence, the trial court was concerned with attorney discipline.
All lawyers admitted to practice in Washington are subject to the Rules for Lawyer Discipline (RLD), and jurisdiction for that purpose continues even if the lawyer no longer practices law in this state. RLD 1.2. Responsibility for the administration of lawyer discipline lies exclusively with the Supreme Court. RLD 2.1; see also RCW 2.48.060. That does not mean, however, that our lower courts are without authority over attorneys who appear before them. In Hahn v. Boeing Co., 95 Wash.2d 28, 34, 621 P.2d 1263, 20 A.L.R.4th 846 (1980), the court stated:
[A] superior court lacks authority to conduct disciplinary proceedings. It has, of course, the authority and duty to see to the ethical conduct of attorneys in proceedings before it. Upon proper grounds, it can disqualify an attorney. It has the power to punish for contempt. But as to matters *316 which do not affect those proceedings, the disciplinary power rests exclusively in this court....
(Citations omitted. Italics ours.) A superior court's power includes ordering disgorgement of an attorney's fee when the attorney has breached his or her ethical duties in the proceeding before the court. Eriks v. Denver, 118 Wash.2d 451, 462-63, 824 P.2d 1207 (1992).
Although a judge has an obligation to take or initiate disciplinary measures against an attorney when he or she becomes aware of unprofessional conduct by the attorney, CJC Canon 3(B)(3), the Superior Court's order here exceeded its authority. The fee at issue was not earned in the proceeding before the Superior Court, but in an earlier unrelated case.[3] The court's order was not an attempt to fashion a proper remedy as it had dismissed the case. Nor was the court "policing" the conduct of an attorney in an action before it. Rather, the court was concerned with disciplining Jeffrey for conduct relating to the case in which the fee was earned. The Superior Court did not have authority to do so; that power rests exclusively with the Supreme Court. Thus, the Superior Court did not have cognizance of this type of case. Further, the issue of attorney discipline was not, in substance or effect, within the issues raised by Steven's complaint. Consequently, the Superior Court lacked jurisdiction to enter the order and, to the extent the order compels Jeffrey to pay into the court registry, the order is void.
Because we hold the Superior Court lacked jurisdiction to enter the order, we do not consider Jeffrey's arguments the order resulted in an unconstitutional taking or that Steven lacked standing to respond to the appeal.
We reverse that portion of the trial court's order dismissing Steven's claim and remand for further proceedings. We reverse for lack of jurisdiction that portion of the court's order compelling Jeffrey to pay $89,000 into the registry of the court.
SWEENEY, J., concurs.
THOMPSON, C.J., dissents.
THOMPSON, Chief Judge, dissenting.
I agree the trial court's order compelling Jeffrey to pay $89,000 into the registry of court must be reversed. However, I would affirm the dismissal of Steven's claim.
As the majority recognizes, contracts which are illegal or which are connected with an illegal act are against public policy and are unenforceable. Golberg v. Sanglier, 96 Wash.2d 874, 883, 639 P.2d 1347, 647 P.2d 489 (1982). Contracts may also be unenforceable as against public policy independent of any statute prohibiting their subject matter. Belli v. Shaw, 98 Wash.2d 569, 578, 657 P.2d 315 (1983) (contract violating former CPR DR 2-107 contrary to public policy and unenforceable); Walsh v. Brousseau, 62 Wash.App. 739, 815 P.2d 828 (1991) (contract violating RPC 7.2(c) contrary to public policy and unenforceable); Wright v. Corbin, 190 Wash. 260, 267, 67 P.2d 868 (1937) (contracts "obnoxious to the pure administration of justice, or ... injurious to the interest of the public" can be declared illegal because against public policy).
The contract between Steven and Jeffrey should not be enforced because it is contrary to RPC 7.2(c). It is contrary to RCW 9.12.010. Further, it is contrary to the general public policy of this state which disapproves of the brokerage of lawyer services. See Goodier v. Hamilton, 172 Wash. 60, 19 P.2d 392 (1933) (layperson's contract with insurance agent to locate attorney who would secure a certificate from state board of public works void as against public policy).
The policy behind the nonenforcement of illegal contracts and contracts against public policy is to protect the public, not to protect or punish either party to the contract. Lewis v. Davis, 145 Tex. 468, 199 S.W.2d 146, 151 (1947). Accordingly, courts generally leave the parties as they find them. Plumlee v. Paddock, 832 S.W.2d 757, 758 (Tex.Ct.App. 1992). That is just where Steven and Jeffrey *317 should be left. While application of the doctrine of "in pari delicto" is appropriate in exceptional cases such as Golberg, its application here is misplaced. Steven is not only presumed to know the law which made Jeffrey's actions illegal, his own acts in aiding and abetting Jeffrey in those illegal acts should not be rewarded. Further, by his own assertion, Steven completed and submitted hourly time sheets for services he never performed.
It is with some hesitation that I reach this conclusion, which enables a lawyer, who himself violates the law and the Rules of Professional Conduct, to urge his own violation as a defense to a suit for monies owing. However, we cannot allow use of our courts to enforce such illegal contracts and thereby infer approval of the brokering of legal services. Further, there is little doubt that any inequity generated by a decision not to allow Steven to enforce the contract will be remedied in subsequent litigation and hearings between the offending lawyer and others who are not parties to this litigation.
NOTES
[1]  We believe this arrangement has been made known to the Washington State Bar Association.
[2]  We look to the trial court's oral opinion because its written order commands Jeffrey to pay the money to the registry "for the reasons stated in the Court's oral opinion...."
[3]  The record does not indicate which court, or which judge, decided the underlying case. Jeffrey does indicate that it was not decided by this judge, and Steven does not contest the statement.
