-The Secretary of Banking of Pennsylvania took possession of the South Philadelphia State Bank on Sept. 6, 1924, the bank being insolvent, due mainly, as it appears, to dishonest acts of employees. The Secretary of Banking proceeded to wind up the affairs of the bank. Among its assets was a bond of the defendant surety company indemnifying the bank against direct loss of money or property through dishonest acts of employees, the principal sum of this bond being $50,000. The instrument was executed on or about Aug. 31, 1920, and was annually renewed thereafter, so that it was duly in force at the time the bank was taken over by the State Banking Department. The contract of indemnity required the bank to give notice of a claim to the surety within ten days after the discovery of any dishonest act, and within three months after such discovery to furnish to the surety at its home office affirmative proof of loss with full particulars. It was further stipulated that legal proceedings for the recovery of loss under the bond could not be brought prior to the expiration of three months after the furnishing of such proof
On Sept. 17, 1920, the bank made application to the same surety company, this defendant, for a surety bond in favor of the Commonwealth of Pennsylvania to protect the Commonwealth against loss of moneys on deposit in the bank. In this application the bank covenanted that it would “at all times indemnify and keep indemnified the company and save it harmless from and *94against all claims, demands, liabilities, costs, charges and expenses of every kind and nature which it shall at any time sustain or incur, and as well from or against all orders, judgments and adjudications whatever by reason or in consequence of having executed said bond, and will pay over, reimburse and make good to the company, its successors and assigns, all sums and amounts of money to meet every claim, demand, liability, cost, charge, expense, suit, judgment or adjudication against it by reason of the execution of the bond applied for and before the company shall be required to pay thereunder.”
Upon this application the defendant executed its bond to the Commonwealth in the principal sum of $10,000, conditioned that the bank “shall from time to time, upon demand of the State Treasurer or other State officers by whom such deposit was made, pay over to him or them any part of the sums of money belonging to the said Commonwealth deposited with it,” etc.; and further conditioned that “in case of a breach of any of the conditions of the foregoing bond, the said surety holds itself bound as principal for any debts arising thereunder, in the amount aforesaid, and agrees to answer for the same without regard to and independently of any action taken against the said South Philadelphia State Bank of Philadelphia, Pa., and whether the said South Philadelphia State Bank be first pursued or not.” The bond contained a warrant authorizing any attorney of any court of record to appear and confess judgment against the surety company upon the filing of the bond or an attested copy thereof.
This bond was renewed periodically and was in full force when the bank was taken over on Sept. 6, 1924, as above stated.
On or prior to Sept. 17, 1924, the defendant surety, upon demand of the Commonwealth of Pennsylvania, paid to the State Treasurer the full amount of the Commonwealth’s deposit with the bank, amounting to $10,000 and interest. The surety company received from the State Treasurer a written assignment dated Sept. 12, 1924, but acknowledged on Sept. 17, 1924, of the deposit of the Commonwealth, in which assignment was incorporated a provision that the assignor, Commonwealth of Pennsylvania, did thereby “subrogate the said surety to all of its rights and remedies against the said bank with respect to said deposit.” We do not attach importance to this last provision, but recite it'here for what relevancy it may have.
Subsequently, on April 21, 1925, following demand made, suit was brought in the name of the bank by the Secretary of Banking against the defendant surety company to recover the principal sum of $50,000 of the bond first above referred to, and in the plaintiff’s statement of claim filed on the same day it was averred that the Secretary of Banking made discovery on or before Sept. 6, 1924, that the bank had sustained substantial loss in excess of the principal sum of the bond through the dishonest acts of certain named employees of the bank, and that on the same day, Sept. 6, 1924, the Secretary gave notice in writing, by registered mail, to the defendant of the said dishonest acts and the consequent loss to the bank and of the discovery of the same. It was further averred that on or before Nov. 29, 1924, the Secretary furnished to the defendant proper written proof of the loss to the bank as, a result of the said dishonest acts.
To this statement there was in due course filed by the defendant a supplemental affidavit of defence, wherein defendant admitted its liability on the $50,000 bond, but set up that it had met by payment since suit brought all of its liability except as to $10,000 thereof, against which it averred a set-off of an equal amount, based upon defendant having paid that sum to the Commonwealth of Pennsylvania on its bond to secure deposits as above set forth.
*95The defendant based its claim- to set off this sum not only upon the fact of payment of the loss by it as surety and the consequent right of subrogation, but also upon the covenant contained in the application for the bond, wherein the bank assumed an express obligation to save the defendant surety harmless from and against all claims and demands, and also to pay over to the surety any moneys necessary to meet every claim, demand or liability against the surety arising under the bond, the bank covenanting to make such payment “before the company shall be- required to pay thereunder.” Further, the defendant set up that the Commonwealth, as a depositor of the insolvent bank, was entitled to a priority of payment, and that to this preference or priority the surety was subrogated; that there were sufficient assets in the estate to pay in full the deposit of the Commonwealth as a claim having priority.
To this claim of set-off plaintiff filed a reply raising questions of law contending that (1) the Commonwealth had no priority over other depositors; (2) if such right to prior payment existed, it was peculiar to the sovereign and could not pass to the surety by subrogation; (3) defendant could not set off the payment to the Commonwealth because it was made after the principal became insolvent. Other defences were averred which we believe it unnecessary to recite. The reply was argued as a rule for judgment for want of a sufficient affidavit of defence, and the parties agreed that the court should enter final judgment for such party as it deemed entitled to prevail on the facts and the law.
The questions of law arising have been ably presented to us in two arguments and in excellent briefs. The defendant’s propositions, stated at greater length, are that the set-off is supportable by reason of:
First. The relation of principal and surety existing between the bank and the defendant, under which the surety is held to be entitled to set off against the demand of the principal any moneys due to it from the principal, or to retain out of moneys due the principal funds sufficient to indemnify it against any liability as surety for the principal, defendant contending that the bank, by reason of the covenants contained in the application for the bond to the Commonwealth, was at the moment of insolvency on Sept. 6, 1924, indebted to the defendant in such sum as was necessary to discharge the liability on the' bond of the Commonwealth, and that, in any event, this express liability of the bank to supply to the defendant as surety this sum- of $10,000 accrued or became a fixed liability at least no later than the moment when the surety became obligated to the bank on the bond sued on, to wit, the $50,000 bond.
The defendant argued from this that, while it was indebted originally to the plaintiff in the sum of $50,000 on the one bond, plaintiff was indebted to the defendant at the same moment, prior to or upon the happening of the insolvency, in the sum of $10,000, which latter sum the defendant declared its right to set-off under the authority of the Pennsylvania decisions and the general rule governing principal and surety, leaving the net obligation of the defendant as $40,000, which it is conceded has been discharged by payment.
Second. That the Commonwealth, as the sovereign, was entitled to priority of payment of its deposits in the plaintiff bank; that to this claim to priority the defendant, as surety, was subrogated both by rule of law and by express assignment; that sufficient funds were available to pay in full all claims having priority; that, therefore, defendant, by virtue of subrogation to the rights of the Commonwealth, its principal, was entitled to receive payment of $10,000 from the insolvent estate, and this right to receive $10,000 could be set off in this suit against the amount unpaid on the $50,000 bond.
*96Our discussion of the points raised will he in what seems to us the logical order. We are without doubt that in Pennsylvania, under the decisions of the Supreme Court, the Commonwealth, as the sovereign, has a right of priority of payment of at least all taxes or like claims when “settled.” This would appear to include only such obligations due the Commonwealth as are of record as liens or as may have been reduced to final and liquidated form by “settlement” by the appropriate officials. Should and does this common-law right to priority of payment extend to public moneys on deposit in a bank? Such a deposit is an obligation liquidated or fixed as an amount, and while it is not a matter of record in a tax office or upon the judgment indices, it is, nevertheless, clearly ascertained and indicated by the books of the bank, and no one has been misled as to the circumstances. It would appear from the decisions of our highest court that Pennsylvania is to be listed as a jurisdiction wherein the Commonwealth has priority even as to such a deposit.
The weight of authority outside of this state is distinctly in favor of such a principle of law. These cases of other jurisdiction base the right of the state to priority upon the prerogatives of the state as sovereign, acquired through the Revolution as successor to the King of England. There were certain rights in the King as a monarch which were contrary to our principles of republican government. These the state did not succeed to. There were other prerogatives that were inherent in his character as sovereign which were for the benefit of his subjects at large. These the states succeeded to, and among them was the priority of the sovereign over other creditors, because of the general public interest that the funds of the state should be protected for the benefit of all.
In the case of Com. v. Baldwin, 1 Watts, 54, Chief Justice Gibson recognizes that the Commonwealth of Pennsylvania succeeded to the latter class of prerogatives of the King in deciding that the lien of a judgment in favor of the Commonwealth is not lost by the lapse of time.
In Com. v. Lewis, 6 Binn. 266, Chief Justice Tilghman declared the State’s preference over individuals when he said, at page 271: “The State of Pennsylvania always took preference to individuals until the Act of 1794, which directs that debts due to the State from deceased persons shall be last paid. But as long as she held the preference, its propriety was never doubted; and even yet she takes a preference with regard to the estates of living debtors, for an account settled by the accounting officers of the Commonwealth becomes a lien on all the real estate of the debtor.”
The Act of 1794 provides that in decedents’ estates the Commonwealth should be paid last. This act, however, applies only to the estates of deceased debtors.
The right of the state to priority over other creditors has been adjudicated upon the principles set forth above in many jurisdictions. In New York the principle was recognized in the case of Carnegie Trust Co., 206 N. Y. 390, 46 L. R. A., N. S., 260; and the Supreme Court of the United States in the case of Marshall v. New York, 254 U. S. 380, conceded the priority of the State of New York and applied it in the case before it. The other states which have declared the priority are as follows: Maryland: State v. Bank of Maryland, 6 Gill & J. 226; Parlett v. Dugan, 85 Md. 407, 37 Atl. Repr. 36. Georgia: Robinson v. Bank of Darien, 18 Ga. 65. Tennessee: U. S. Fidelity and Guaranty Co. v. Rainey, 120 Tenn. 357. North Carolina: Hoke v. Henderson, 14 N. Car. 12. West Virginia: Woodyard v. Sayre, 90 W. Va. 295, 24 Am. Law Reps. 1497. Idaho: In re Bank of Nampa, 29 Idaho, 166, 157 Pac. R. 1117. Oregon: U. S. Fidelity and Guaranty Co. v. Bramwell, 108 *97Ore. 261, 32 Am. Law Reps. 829. There are many states in which the right is given by statute, so that the question of a common-law right does not arise. The only states in which we have found decisions holding that the state has not a preference by common law are New Jersey, South Carolina, Mississippi and Montana.
It will be noted from the cases cited above that the question of the state’s preference has been raised in a number of jurisdictions. In each of the eases where the point has come up for the first time, the decisions have been carefully considered and most of the authorities then existing have been cited. It is very interesting to note that in practically every case Booth & Flinn, Ltd., v. Miller, 237 Pa. 297, hereafter discussed, has been cited as authority for the proposition that in Pennsylvania the common-law preference of the Commonwealth over other creditors is the law of this State.
In that comparatively recent case, the Supreme Court of Pennsylvania said, on page 307: “The State, when acting in its sovereign capacity, occupies a position entirely different and superior to that of the citizen. It cannot be sued without its consent. The statute of limitations, without it is expressly so declared, cannot be invoked to defeat its claim as a creditor. It takes precedence over other creditors. It may forego its rights as a sovereign power and place itself on the same footing as one of its citizens, but unless the statutory language affecting the subject so declares, it will not be presumed. The State cannot be deprived of its rights as a sovereign by inference; it must be done by appropriate constitutional or legislative action:” Booth & Flinn, Ltd., v. Miller, 237 Pa. 297.
It is true the point in this case was not the preference of the Commonwealth upon a debt due it; however, the right is plainly recognized, and was used as an illustration to demonstrate that the Commonwealth, by reason of its sovereign powers, stands on a different footing from all its citizens. The case decided that a statute which gave the Commonwealth a prior lien upon the land of a hospital for the amount appropriated to the institution was not unconstitutional, though the lien would be superior to one which already existed upon the premises. In this connection, Shaeffer’s Estate (No. 1), 281 Pa. 138, decided in 1924, and hereafter considered at some length on the point next to be discussed, is of value.
We are also of opinion that such a right to priority of payment, if possessed by the Commonwealth, passes to a surety by way of subrogation, under the general rules of law applicable to principal and surety. And we can see no reason why it should not be so held. The reported cases are predominant in favor of the right of the surety to be subrogated to the preference of the state. In U. S. Fidelity and Guaranty Co. v. Carnegie Trust Co., 146 N. Y. Supp. 804, it was held that, under the New York law, a surety who pays the Commonwealth the amount of its deposit in a bank is subrogated to its right of preference. After reviewing the decisions, the court said the following with reference to the soundness of the rule which allows subrogation: “But, apart from the reported decisions, we consider that the plaintiff’s contention is wholly sound. It is familiar law that a surety paying the debt of his principal is entitled to be subrogated to all of the creditor’s rights, privileges, liens, judgments and mortgages, and that to enjoy the benefit of these, no assignment from the creditor is necessary. The surety, by the mere fact of payment, is put into the shoes of the creditor. If, in the case at bar, the state had had a lien, in the conventional sense, upon the assets of the Carnegie Trust Company, and the plaintiff, as surety, had paid the debt of the trust company, it would have been entitled upon the plainest principles to be subrogated to the state’s lien *98and to enforce the same: Memphis R. R. v. Dow, 120 U. S. 287, 7 Sup. Ct. Repr. 482, 30 L. Ed. 595; Sgobel v. Cappadonia, 8 N. Y. App. Div. 303, 40 N. Y. Supp. 946. The state’s absolute right to preference in the distribution of the. assets of the trust company, if not technically a first lien thereon, was equivalent to a lien and had all the effect which a specific lien would have had. If, as seems to be undoubted, the plaintiff would, upon payment, have succeeded to a lien, we can see no reason why it should not be held to have succeeded to the equivalent. No injustice will be done to the general creditors of the trust company by allowing plaintiff’s claim to a preference, as it merely continues in force the preferential right of a state, subject to which all creditors-become such, and it is to be borne in mind that plaintiff’s bond was not given for the benefit of any other creditor than the state” (page 807).
Some of the other authorities which recognize the right of subrogation will be found in 24 Am. Law Reps. 1510. They include cases in the Federal courts, Alabama, Georgia, Illinois, Maryland, Minnesota, Montana, New York, North Dakota, Virginia and West Virginia. Several more cases are cited in the note in 32 Am. Law Reps. 846; U. S. Fidelity and Guaranty Co. v. Bramwell, 295 Fed. Repr. 331 (1923), and Maryland Casualty Co. v. McConnell, 148 Tenn. 656 (1924). There are few decisions which hold that there is no right of subrogation. The principal one is that of Brown v. American Bonding Co., 210 Fed. Repr. 844, in which the Circuit Court for the Ninth Circuit reversed the lower court. There, however, the question of subrogation was not a necessary part of the decision of the court, since it held that the State of Montana had no preference, in any event, over other creditors. In so holding, the court relied mainly upon the decision of the Supreme Court of the United States to the effect that tfye basis of the United States’ priority was a statute and not the common law, and it was said to be inconceivable that the states could have a priority founded upon a sovereign right which the government of the entire country did not have. The reasoning of the court seems unsound, for it plainly overlooks the fact that the states in our system of government are the sovereigns, and that the Federal Government has only such sovereign powers as have been granted to it in the Constitution. Under such circumstances, it is impossible for the United States to have such common-law prerogatives as the right of preference over general creditors.
The case, however, which we view as almost controlling the one under consideration is the recent decision of the Supreme Court in Shaeffer’s Estate (No. 1), 281 Pa. 138 (1924). Shaeffer was a distiller of liquors; the Federal Government assessed a revenue tax against him. Landis was surety on Shaeffer’s bond and paid the amount of the tax to the Government, but immediately took steps to recover it from the Government. An agreement was then entered into between Shaeffer and Landis, whereby it was agreed that, should the money be recovered from the Government, Landis should receive interest and costs. Subsequently, the money was repaid by the Government. Shaeffer’s estate came on for settlement, and Landis’s administrator presented a claim for interest and counsel fee, which the Orphans’ Court allowed. Two questions came before the Supreme Court on appeal: (1) Whether Landis was entitled to recover interest and costs, and (2) whether his claim against the estate was entitled to a priority. The Supreme Court, in affirming the decree of the Orphans’ Court, answered both of these questions in the’ affirmative. Mr. Justice Kephart said as to the first question: “‘The rule is that, in the absence of a stipulation to pay interest or a statute allowing it, none can be recovered against the United States upon unpaid accounts or claims,’ . . . but where a party secondarily liable pays taxes due the Govern*99ment, a claim for interest against the principal is a matter of right. The surety on a bond given to the United States, who has paid the principal’s debt to the Government in a definite sum, has a liquidated claim against the principal for the amount paid, with interest from the date of payment.”
Concerning the second question, the opinion reads: “Appellee’s claim was rightfully allowed as a preference. The doctrine is well established that where, a surety pays the debt of his principal, he is subrogated in equity not only to the securities of the creditor, but to all his rights of priority: 25 Ruling Case Law, 1382, § 65; Com. v. Marsh, 149 Pa. 239. Where the surety on a distiller’s bond pays money to the Government on account of his principal, he is entitled to be subrogated to the rights of the Government and the claim is entitled to priority: Lewis’s Admin’r v. U. S. Fidelity and Guaranty Co., 144 Ky. 425; Reed v. Emory, 1 S. & R. 337, 37 Cyc., 426; Levin v. Fourth Street Bank, 277 Pa. 350, 355.”
If it is the law of this State that the Commonwealth is entitled to priority over other depositors, then Shaeffer’s Estate makes it clear that the surety who pays the amount of the Commonwealth’s claim is entitled to a similar priority.
However, were we to attempt to decide this case upon the basis of a right to priority of payment in the Commonwealth, we would meet this situation: The affairs of the failed bank are being liquidated by the Secretary of Banking under the direction of the Court of Common Pleas No. 1 of this county, which court, under the Banking Act of 1923, has exclusive jurisdiction to distribute the assets. While it does appear that the moneys in the hands of the Secretary — whose powers are the same as those possessed by a receiver in equity (section 29) — are sufficient to pay all preferred claims or priority claims in full, yet we have no means of ascertaining whether there may not be expenses of administration that will operate to reduce the assets to such a sum as will'make impossible full payment of such claims. Then, again, we doubt our power to, in effect, interfere with the Court of Common Pleas No. 1 in its distribution of the assets of the insolvent estate by the indirect method of allowing a set-off herein of such a sum as may be payable on the Commonwealth’s claim in distribution. For these reasons, we reject this basis of decision.
We find no difficulty, however, in concluding that the set-off should be allowed on the other grounds relied upon by the defendant, to wit, the right of a surety to offset against the principal’s demand moneys due to the surety from the principal, notwithstanding the apparent authority to the contrary found in U. S. Fidelity and Guaranty Co. v. Wooldridge, 45 U. S. Sup. Ct. Rep. 489, which case is clearly distinguishable on its agreed facts and which we will discuss in some detail hereafter.
The fact that the South Philadelphia State Bank specifically agreed in writing to hold harmless the defendant against all claims, demands and liabilities, etc., by reason of the deposit of $10,000 by the Commonwealth of Pennsylvania is a very material fact in this case. Instead of a liability implied by law, the South Philadelphia State Bank expressly agreed as to what the rights of defendant should be in connection with its obligation to pay the Commonwealth the amount of the bond. The obligation of the bank, which was taken over by the Secretary of Banking as he took over its assets, is a direct one — one which has existed in favor of defendant for a number of years. The application, far from being immaterial, as we see it, resolves this case into one of simple set-off, in which it is no longer necessary to resort to the legal doctrine of subrogation. We may agree that the status of the *100parties was fixed as of the date the Secretary of Banking took possession, but at that date the defendant had, as against the bank or the Secretary of Banking, the very rights which it is attempting to enforce in its set-off — the right to have paid over to it moneys in such amount as was necessary to meet the Commonwealth’s demand on the bond.
Defendant had the right to be paid $10,000 by the South Philadelphia State Bank as soon as there was any “liability . . . against it by reason of the execution of the bond.” When did a liability arise? Let us look at the bond given by defendant to the Commonwealth:
“The National Surety Company . . . does hereby bind itself . . . and becomes security to the Commonwealth of Pennsylvania for the payment of the amount of moneys of the said Commonwealth deposited in the South Philadelphia State Bank of Philadelphia. . . .
“And, further, the said surety hereby authorizes and empowers any attorney of record in Pennsylvania or elsewhere to appear for and confess judgment against it, in favor of the Commonwealth, upon the filing of this instrument, . . . for the sum of money as herein above set forth. . . .”
The defendant assumed an immediate liability on which judgment might at once have been entered against it in the prothonotary’s office. The condition of the bond of the South Philadelphia State Bank given to the Commonwealth was that it should pay over the amount of the deposit immediately upon demand.
Construing the two bonds together, it is manifest that the liability of defendant arose at the very latest when the bank was taken over by the Secretary of Banking. It was then that the bank became legally unable to pay over the amount of the Commonwealth’s deposit. It was not necessary that the State Treasurer should make a demand upon the bank; that would have been useless, and for that reason will not now be said to have been necessary. Moreover, the taking over of the bank by the Secretary of Banking amounted to a demand by all depositors, and the amount of the deposits then became due and payable.
“The general rule followed by the great weight of authority is that a depositor in an insolvent bank may set off his deposit therein against a bona fide indebtedness of his own to the bank:” 25 Am. Law Reps. 938. That this is the law of Pennsylvania appears in the following cases: Jordan v. Sharlock, 84 Pa. 366 (1877); Skiles v. Houston, 110 Pa. 254 (1885); Yardley v. Clothier, 1 Dist. R. 46 (1892); Jack v. Klepser, 196 Pa. 187 (1900).
Under these cases there can be no question that if the Secretary of Banking had sued the Commonwealth on any claim the bank had against it, the Commonwealth could have set off the amount of its deposit. This is precisely the question decided by the Supreme Court in Fisher v. Davis, 278 Pa. 129 (1923), which was a suit by the former Commissioner of Banking upon two promissory notes of the defendant, and the defendant, by way of defence, claimed a set-off in the amount of certain Liberty Bonds which he had delivered to the hank to be sold for his account. The set-off was allowed, and the Supreme Court affirmed, the court stating specifically that the allowance of a set-off of this character is in no sense a preference within the terms of any of the statutes governing the distribution of the assets of an insolvent.
When it is stated in the Practice Act of 1915 that a defendant may set off “any right or claim for which an action of assumpsit would lie,” the meaning unquestionably is that the debt or damages which can be set off as an independent counter-claim must be such as could be liquidated by a jury if the defendant were suing as plaintiff. The set-off here meets this requirement.
*101The defendant did not acquire rights or claims against the plaintiff after the bank was taken into possession different in quality or character from the rights or claims as they existed at the date the Secretary of Banking took possession. The Pennsylvania cases of Wagner v. Burnham, 224 Pa. 586 (1909), and Jack v. Klepser, 196 Pa. 187 (1900), are in point in this connection. In the first-cited case the plaintiff was the trustee in bankruptcy of a contractor who was in the midst of a building operation when he became insolvent. His trustee sued the owner of the property to recover money due the contractor on the operation, and the defendant set up a counter-claim in the amount of certain liens filed against the property by sub-contractors and paid by him subsequent to the adjudication in bankruptcy. The court there said: “It is strenuously contended by the plaintiff that the defendants’ claim was contingent, uncertain, was not provable against the bankrupt at the date of the adjudication in bankruptcy, and, therefore, cannot be allowed as a set-off. This view, however, we think, entirely overlooks the nature and character of the defendants’ claim as well before as at the time it was interposed as a set-off. At the date of the adjudication, the bankrupt was indebted to the subcontractors on the claims which were subsequently paid by the defendants. The primary liability for payment of these claims rested upon the bankrupt, and the claims could have been enforced against him to the extent of his liability to pay. By the law of this state, however, the sub-contractors had a lien against the property of the defendants for the work done and the materials furnished by them.” The set-off was allowed and the order of the lower court discharging the rule for judgment for want of a sufficient affidavit of defence was affirmed. To the same effect is the ease of In re Dillon, 100 Fed. Repr. 627 (Mass., 1900).
Jack v. Klepser, 196 Pa. 187 (1900), while differing slightly on its facts, is also authority for the proposition stated. This was an action by an assignee for the benefit of creditors against Klepser and Woodcock on their note for $1500. At the time of the assignment for the benefit of creditors, Woodcock, one of the defendants, and one Curry had a deposit in the plaintiff’s bank amounting to $1346. After the failure of the bank, Curry transferred his interest in the deposit to Woodcock, who then set off the full amount of the deposit against the note upon which he and Klepser were sued. In allowing this set-off, the court there said, at page 193: “No good reason appears for denying to Woodcock the right to set off the deposit in question against the note in suit. It constitutes an equitable and just defence, and there is in the cases since Tustin v. Cameron no visible obstruction to the allowance of it. We, therefore, concur in the conclusion arrived at in the clear and logical opinion of the learned judge of the court below.” This case is stronger on its facts than the case at bar, and supports the contention that defendant should be allowed to set off the amount of its payment to the Commonwealth, even though defendant’s right to direct payment or to subrogation be considered as not having accrued until after the failure of the bank.
The plaintiff assumes that the defendant had no rights against the bank until it made the payment of $10,000 to the Commonwealth. Since this payment was made subsequent to the taking of possession of the bank, it is argued that defendant did not acquire any rights by virtue of that payment. But undoubtedly the defendant had rights with reference to retaining a part of the money due the plaintiff bank under the $50,000 bond before the actual payment of the Commonwealth’s $10,000. Under the authorities, the defendant, as surety, had the right to retain out of the moneys due its principal $10,000 as a fund for its indemnity.
*102The case of Craighead v. Swartz, 219 Pa. 149, is authority to this effect. The rule is there recognized that where a principal has become insolvent, his surety may retain moneys of the principal to the amount of his indebtedness to the principal as a fund for his indemnity. The court in its decision discusses at length the principles of law under which the surety of an insolvent is entitled to subrogation and set-off. The court said, at page 152:
“If R. R. Craighead & Bro. on Feb. 5, 1905, being at that time insolvent, had brought suit against John W. Craighead on his three notes held by them, he could have interposed as a defence his liability as indorser on their protested paper held by the Farmers’ Trust Company. When a principal has become insolvent, the surety may retain the moneys of the principal or the amount of his indebtedness to the principal as a fund for his indemnity: 27 Am. & Eng. Ency. of Law (2nd ed.), 478. ‘A principal who is insolvent cannot collect a debt which the surety owes him without his indemnifying the surety:’ 1 Brandt on Suretyship and Guaranty (2nd ed.), § 227. See, also, Abbey v. Van Campen, 1 Freem. Ch. (Miss.) 273; Mattingly v. Sutton, 19 W. Va. 19; Walker v. Dicks, 80 N. C. 263; Merwin v. Austin, 58 Conn. 22. ‘The surety of an insolvent debtor cannot be compelled to pay a debt he owes his principal until he is released of his responsibility of suretyship, and may retain what he owes as a counter-claim against such surety:’ Scott v. Timberlake, 83 N. C. 382. In our own state, in Ross v. McKinny, 2 Rawle, 227, it was held that in an action to recover a legacy, the executor might demand a conditional verdict that would permit him to retain the legacy until he had been indemnified against a demand for which the testator was surety for the legatee. In Beaver v. Beaver, 23 Pa. 167, in an action by an administrator of an insolvent estate, it was held that the defendant was entitled to set off the amount paid on a note of decedent on which he was surety, although the payment was not made until after suit was brought, on the ground that the equity of set-off originated when the obligation to pay became absolute. It was there said: ‘As between principal and surety, courts of equity always lend their aid for the protection of the latter. As soon as the surety’s obligation to pay becomes absolute, he is entitled in equity to require the principal debtor to exonerate him, and he may file a bill to compel an exoneration, although the creditor has not demanded payment from him: Theobald’s Principal and Surety, 226; Nisbet v. Smith, 2 Bro. C. C. 579; Lee v. Rook, Mosely, 318; Story’s Equity, § 327.’ This was followed by Thompson v. McClelland, 29 Pa. 475. The defendant there, as surety of the legal plaintiff, who was insolvent, was allowed to set off the amount paid on a judgment recovered against him as surety, although such payment was made after the suit had been brought against him. In Miller & Reist v. Kreiter, to the use of Bomberger, 76 Pa. 78, Reist, the defendant below, indorsed a note made by Kreiter. Before his indorsement of this note, he had given Kreiter a non-negotiable note. This note Kreiter assigned to Bomberger, who brought suit upon it on Jan. 25, 1872. On April 6, 1872, judgment was recovered against Reist as indorser of Kreiter, and it was held that on Aug. 30, 1873, on the trial of the suit brought by Bomberger, Reist could set off the amount of the judgment recovered against him as Kreiter’s indorser. This court said: ‘As soon as the note was protested, June 10, 1871, and ReisUs liability as indorser became fixed and absolute, he was entitled to call upon the maker to exonerate him from such liability, and that even before demand was made upon him for payment: Beaver v. Beaver, 23 Pa. 167. His right of set-off, as against any claim Kreiter had against him, may be said to have originated from this period.’
*103“The set-off allowed by the court in this case was an equitable one, and even if it may not have been technically within our Defalcation Act, it was a good defence in our courts, administering equity under common-law proceedings. As to this, it is said in Hibert v. Lang, 165 Pa. 439: ‘In general, in order to support a set-off, there must be cross-demands between the same parties and in the same rights, such as would sustain mutual actions against each other; yet wherever there is the practicability of avoiding circuity of action and needless costs with safety and convenience to all parties (Gibson, C. J., in Tustin v. Cameron, 5 Whart. 379), or where there is a special equity to be subserved, and no equity of third parties to be injured, a set-off will be allowed upon equitable principles, though the case does not come within the language of the statute.’ ”
See, also, Condran v. Kennedy, 56 Pa. Superior Ct. 356, for a resumé of the law of set-off as to sureties.
The exact question presented in the case at bar was decided in the United States Circuit Court of Appeals for the Ninth Circuit in Fidelity and Deposit Co. of Maryland v. Duke, 293 Fed. Repr. 661 (1923), where the court said, on page 665:
“A bank may set off a depositor’s debt to it against its deposit debt to him, and the great weight of authority is that a depositor may set off his deposit credit against his debt to an insolvent bank: Scott v. Armstrong, 146 U. S. 499, 13 Sup. Ct. Repr. 148, 36 L. Ed. 1059; Puget Sound State Bank v. Washington Paving Co., 94 Wash. 504, 162 Pac. Repr. 870; cases in notes, 25 Am. Law Reps. 938. Doubtless, it will be conceded that set-off does not depend upon the variety of contract debt or upon the character of parties. Hence, a debt upon a contract of suretyship may be set off equally with a debt by contract of deposit, and a surety corporation for hire may assert set-off equally with any other character of surety. The general statute of Washington, in its provision for set-off or cross-demands, does not except, and so includes, sureties and debts to them: Rem. Codes, 1922, § 266.
“And in any such set-off is no preference, for only the excess is justly owing or assets to whom due, insolvent or not: Scott v. Armstrong, 146 U. S. 499, 13 Sup. Ct. Repr. 148, 36 L. Ed. 1059; St. Paul, etc., Co. v. Leck, 57 Minn. 87, 58 N. W. Repr. 826, 47 Am. St. Reps. 576. That defendant did not pay the bank’s debt to the treasurer until after liquidation commenced is immaterial, for the obligation to pay preceded that time, and, payment made, subrogation relates to the time of obligation assumed: Henningsen v. United States Fidelity Co., 143 Fed. Repr. 810, 74 C. C. A. 484.”
It will be noted from this case that the surety company’s right of subrogation was held to date back to the time of the execution and delivery of the bond to the obligee. An examination of the cases cited in the opinion in Craighead v. Swartz, 219 Pa. 149, will show that this principle is also applied in the doctrine of subrogation of sureties in the Pennsylvania law, and that sureties have been allowed to claim set-off even where they have paid the creditors after suit has been brought, because the liability of the surety existed before that time.
We have also the authority of the Supreme Court of the United States in the case of Prairie State Bank v. United States, 164 U. S. 227, from which we take the following, at pages 232, 239-40, from the opinion of the late Chief Justice White:
“The sole question, therefore, is whether the equitable lien, which the bank claims it has, without reference to the question of its subrogation, is paramount to the right of subrogation which unquestionably exists in favor of *104Hitchcock. In other words, the rights of the parties depend upon whether Hitchcock’s subrogation must be considered as arising from and relating back to the date of $he original contract, or as taking its origin solely from the date of the advance by him. . . .
“Applying the principles, which are so clearly settled by the foregoing authorities, to the case at bar, it is manifest that if the transaction in February, 1890, by which the Prairie Bank acquired its alleged lien on the fund, possessed the effect contended for by the bank, it would necessarily operate to alter and impair rights acquired by the surety under the original contract.
“Sundberg & Company could not transfer to the bank any greater rights in the fund than they themselves possessed. Their rights were subordinate to those of the United States and the sureties. Depending, therefore, solely upon rights claimed to have been derived in February, 1890, by express contract with Sundberg & Company, it necessarily results that the equity, if any, acquired by the Prairie Bank in the 10 per cent, fund then in existence and thereafter to arise was subordinate to the equity which had, in May, 1888, arisen in favor of the surety, Hitchcock. It follows that the Court of Claims did not err in holding that Hitchcock was entitled to the fund, and its judgment is, therefore, affirmed.”
The District Court of the United States for the Eastern District of Pennsylvania has in a very recent case, Wanner v. Louis Wanner, Jr., Inc., 300 Fed. Repr. 376 (1924), unmistakably recognized the principle that the right of the surety to subrogation dates back to the time of the making of the contract of suretyship. In that case the principal contractor had entered into a contract with the Government of the United States and, under the Act of Congress, had given a bond with sureties for the protection of those supplying labor and material. A sub-contractor brought suit against the contractor, which suit was continued by the receivers of the contractor and resulted in a judgment. Subsequently, the principal contractor and its sureties were compelled to pay certain persons who furnished labor and material to the subcontractor under the obligation of the bond. It was held that the payments so made under the bond were made as surety for the sub-contractor, and should be set off against the judgment recovered against the receiver of the insolvent contractor. The court said, on page 378: “As between principal and surety, courts of equity always lend their aid for the protection of the latter, and when a principal has become insolvent, as Wanner did in this case, and the surety has been compelled to pay his debt, the surety may retain the amount of his indebtedness to the principal as a fund for his indemnity. And, as soon as the surety’s obligation to pay becomes absolute, he is entitled in equity to compel exoneration, even though the creditor has not demanded payment from him, and equity applies the right of set-off wherever there is the practicability of avoiding circuity of action, or where there is a special equity to be subserved and no equity of third parties to be injured: Craighead v. Swartz, 219 Pa. 149, 67 Atl. Repr. 1003; Thompson v. McClelland, 29 Pa. 475, where the defendant, as surety of the legal plaintiff, was allowed to set off the amount paid on a judgment recovered against him as surety, although such payment was made after suit had been brought against him. The claimant here cannot be held to have been estopped from setting up its claim of set-off in the suit in equity against the insolvent because it failed to do so in the suit at law, for it does not appear that either Wanner or its receivers, as the plaintiffs in that suit, were, by reason of Linker’s failure to set up the set-off, induced to injuriously alter their position. Drexel v. Berney, 122 U. S. 241, 14 Sup. Ct. Repr. 710, 38 L. Ed. 565; Scott v. Armstrong, 146 U. S. *105499, 13 Sup. Ct. Repr. 148, 36 L. Ed. 1059, are authorities for the propositions above stated and for the ordinary rule of set-off in cases of insolvency that, where the mutual obligations have grown out of the same transactions, insolvency on the one hand justifies the set-off of the debt due on the other.”
Counsel for the plaintiff herein relies very strongly upon the hereinbeforementioned case of U. S. Fidelity and Guaranty Co. v. Wooldridge, 45 Sup. Ct. Repr. 489, deeming it “an exactly analogous case.” The opinion therein was written by Mr. Justice Holmes, and was handed down on May 11, 1925. Were we in accord with counsel’s view as to the analogy, we would be assuming a very heavy burden to attempt to justify a conclusion opposite to the one reached by so learned and eminent a jurist. However, we do not regard the Wooldridge decision as controlling — first, for the reason that the matter was submitted to the court substantially in the form of a case stated, which limited the consideration of the court to the rights of the defendant surety company acquired “by way of subrogation or assignment.” This is quite expressly stated in Mr. Justice Holmes’s opinion in the following language: “Thus the answer and the agreement confine the issue before us to the rights of the defendant guaranty company by way of subrogation or assignment.”
The suit was instituted by the receiver of the National Bank of Cleburne, Texas, against the Guaranty Company to recover the principal sum of a bond given by the company to indemnify the bank against loss through the fraud of its officers or employees. The bank became insolvent through the fraud of its president, a receiver being appointed on Nov. 1, 1921. The suit was instituted on April 14, 1922. The surety company pleaded in set-off that on Aug. 24, 1921, it became surety for the bank upon another bond to the Gulf, Colorado & Sante Fe Railway Company, conditioned upon payment by the bank to the railway company of the company’s deposits in the bank, and that on Jan. 16,1922, it had paid to the railway company $23,312.51, and as matter of law became subrogated to the rights of the company against the bank, and, in addition, took an assignment of such rights, which assignment was approved by the plaintiff on Feb. 1st. An agreement of the parties was filed that the facts alleged were true and that the only question for the court was “whether or not, under the facts alleged, the defendant is entitled as against the plaintiff to set off the demand it holds as assignee or subrogee of the Gulf, Colorado & Sante Fe Railway Company.” As has been stated, the court construed this agreement as confining the issue to the rights in the surety company “by way of subrogation or assignment.” Judgment was entered in the District Court for the plaintiff, and this was affirmed by the Circuit Court of Appeals, and later by the Supreme Court in the opinion we are now discussing.
A distinction is, therefore, apparent. In the case now before us the surety company is seeking to set off an obligation running directly from the insolvent bank to it, based upon an express contract by the bank to pay over certain moneys to the surety for its indemnification, in advance of any payment being made by the surety to the obligee of the bond, the Commonwealth. Hence, the surety is not relying upon rights acquired either after insolvency of the principal or by subrogation or assignment, or upon a right arising only out of the usual implied obligation of a principal to reimburse or indemnify the surety. No reference appears in the Wooldridge decision to indicate that either the trial court or the appellate courts considered such implied obligation of the principal; no argument upon such question may have been made. The case was not decided upon the simple issue of set-off as between principal and surety, but turned upon the right passing to the surety from *106the railway company by way of subrogation or assignment, the court holding that all that the railway company had was a right to share with other unsecured creditors in the assets of the bank, and this was all that was acquired by the surety through subrogation or assignment.
At bar we have, as stated, a very substantial additional right vested in the surety before insolvency of the bank through the covenants of the application for the bond, and we are not limited by an agreed statement of the facts and the questions of law that overlooks any material element of the controversy.
We found our conclusion that judgment should be entered for the defendant upon the ordinary rules of law governing a claim of set-off and the clearly-declared law applicable to the relation of principal and surety.
For the reasons indicated, final judgment has been entered in favor of the defendant and against the plaintiff on the set-off to the balance of the plaintiff’s claim not already paid.