*664The^ opinion of the court was delivered by
Hoch, J.:This appeal presents, primarily, this question: May the owner of grain stored in a public warehouse (G. S. 1935, ch. 34, art. 2) whose grain has been destroyed by fire recover on a fire insurance policy issued to the warehouseman under section 34-236, G. S. 1935, although the fire had been caused, without connivance or knowledge of the owner, by the felonious act of the warehouseman?
Brief statement of the facts will suffice. F. L. Bunds was licensee and operator of a local public warehouse at Scranton, Kan. As such licensee he obtained a policy from the Millers National Insurance Company to cover loss by fire and other hazards both to his own property and to the grain of others stored in the warehouse.. The warehouse was destroyed or partially destroyed by fire and Bunds filed a claim, under the policy, for $9,715.92, covering among other losses that of the grain stored in the warehouse, and for which warehouse receipts had been issued. Pending action upon the claim Bunds admitted that he set fire to the elevator for the purpose of collecting the insurance, was prosecuted, pleaded guilty, was convicted, and given a prison sentence. Some time thereafter the insurance company, appellee here, filed its petition for a declaratory judgment, naming Bunds as defendant. After reciting the facts hereinbefore stated, it averred that an actual controversy existed between it and the defendant as to liability under the policy; that uncertainty existed owing to the fact that the defendant might bring action upon the policy at any time within five years and that on account of the delay its rights might be prejudiced by the disappearance of material witnesses or otherwise. Other averments made for the purpose of establishing a right to maintain the action for a declaratory judgment need not be recited. No question has been raised as to whether the case was a proper one for invoking the declaratory judgment statute and we will not discuss that question.
In its petition the insurance company asked that the policy be declared null and void. Separate motions were filed by the United States of America and Gus St. Louis as executor of the estate of Caroline Mohr, deceased, asking leave to intervene, as defendants. The motions were allowed and answers and cross-petitions substantially alike were filed. The averments covering matters not in issue need not be recited. The United States claimed as holder of warehouse receipts taken by the Commodity Credit Corporation, a fed*665eral agency, the grain so represented being valued at $8,461.74. St. Louis, executor, asserted ownership by the Mohr estate of grain valued at $1,313, represented by warehouse receipts. In the answers St. Louis admitted that Bunds unlawfully caused the fire, and the United States stated that it neither admitted nor denied it. Both answers denied any responsibility for Bunds’ unlawful act. Both cross petitions asked recovery on the ground that by virtue of the policy and the statute under which it was issued there was a valid contract between them and the plaintiff, and that they could not be held liable for the unlawful act of Bunds. Further recital of the allegations in support of a cause of action based upon that theory is unnecessary. Upon motion of the plaintiff the trial court struck out all parts of the cross petitions in which the intervenors asserted their right to recover under the policy in spite of the unlawful act of Bunds. From that order this appeal was taken.
The question may be divided into two parts: First, were appellants, as owners of the stored grain, entitled under any circumstances to bring action on the policy; second, if so entitled, is recovery barred by the act of Bunds which voided the policy as to him.
We have no difficulty with the first question. Our code of civil procedure provides:
“Every action must be prosecuted in the name of the real party in interest, except as otherwise provided in section 27.” (G. S. 1935, 60-401.)
Section 60-403 provides, in part, that “a person with whom or in whose name a contract is made for the benefit of another . . . may bring an action without joining with him the person for whose benefit it is prosecuted.” Appellee -concedes that if Bunds had collected the insurance he would have held the proceeds for the benefit of the appellants and other owners of the stored grain. Clearly the insurance contract, as far as the wheat involved is concerned, was for the benefit of appellants. Under section 60-403 Bunds might have maintained the action although they were the real parties in interest. But section 60-403 is permissive and not mandatory. (47 C. J. 38; Wilson Company v. Hartford Fire Insurance Co., 300 Mo. 1, 39, 254 S. W. 266.) Certainly the owner of stored grain, covered by insurance, is the real party in interest under the policy. As such he is entitled, as well as the person to whom the policy is directly issued, to bring action. (Annotation 61 A. L. R. 720; 26 C. J. 484.)
The second question is not free from difficulty. In an action on *666the policy by the owners of stored grain does the insurance carrier have available all defenses it would have had in an action by the warehouseman? Otherwise stated, do the owners, as plaintiffs, simply step into the shoes of the warehouseman?
At the outset it may be said that cited cases and others dealing with contracts between private persons relating to matters not affected with a public interest have little, if any, bearing upon the issue here. It may be conceded that as to such matters the general rule is that in an action by a third person in whose interest or for whose benefit a contract has been made, such person has no greater rights than those by whom the contract in his interest was made, unless subsequent to the execution of the contract and in reliance upon it, he has been led to alter his position to his disadvantage if the contract is voided. But we are not here dealing with a contract . unrelated to the public interest. We are dealing with a policy issued under specific statutory requirement. Accordingly the issue must be approached in the light of the terms and the intent of the statute.
It requires no citation of authority to support the proposition that warehouses maintained for the storage of goods and merchandise offered for such purpose are proper subjects for state regulation, as being affected with a public interest. Early in the history of this state the storage of grain in public elevators or warehouses became the subject of regulatory legislation. The history of such legislation is sketched in considerable detail in Kipp v. Goffe & Carkener, 144 Kan. 95, 101, 102, 58 P. 2d 102, and need not be repeated here. The present statute, chapter 194 of the Laws of 1931 (G. S. 1935, 34-223 to 34-2,103), is entitled “An Act to provide for storage of grain in state licensed warehouses and under state supervision and issuance of warehouse receipts therefor, and providing penalties for offenses thereunder, and repealing,” etc. Some provisions of the act, here pertinent, may be summarized as follows:
Public warehouse defined as an elevator or other building adjacent to a railroad in which grain is received for storage or transfer for the public;
State license required before transacting such business;
State inspection required before issuance of license to determine whether building is suitable for storage of grain;
Bond required by the applicant in such sum, not less than $5,000 nor more than $50,000, and at not less than 10 cents per bushel *667upon the capacity of the warehouse, as may be fixed by the chief inspector, the bond being conditioned upon “the faithful, performance of his duties” as a public warehouseman;
License to be posted in a conspicuous place in the office room of the warehouse;
All grain, suitable for storage, and tendered in the usual manner to be accepted up to capacity, without discrimination;
Warehouse receipts to be issued, embodying full information and terms as set out in the statute, including clear indication as to whether the receipt is negotiable or nonnegotiable.
Warehouseman required to keep all stored grain insured against fire and other hazards “for its full market value.”
Maximum charges fixed “for receiving, insuring, handling, storage and delivery of grain.”
In case of loss by fire and upon demand by holders of warehouse receipts warehouseman required to make settlement upon the basis of market value of the stored grain.
Various requirements as to drying, cleaning, and safekeeping of grain.
Extensive provisions as to transfer or negotiation of warehouse receipts, including various provisions in protection of the rights of purchasers for value in good faith of negotiable receipts.
These and other provisions of the statute which might be noted indicate how broadly and specifically the legislature has imposed regulation upon grain warehouses. In the light of such regulatory statutes the appellee issued its policy — -it cannot be heard to say otherwise. The rule is well established that in such a case the statute must be read into the contract. (85 A. L. R. 20, 28-32; 106 A. L. R. 516, 518.) J Although, as appellee contends, the case of Dunn v. Jones, 143 Kan. 218, 53 P. 2d 918, may not be persuasive on other aspects of this case it is clearly in point upon the proposition that the provisions of a statute providing for compulsory insurance in a matter affecting the public interest must be written into the policy, and that no provision of the policy can be effective in contravention of the statute. We are therefore only concerned, in this connection, with the question of what the nature of the policy is when construed in connection with the terms and clear intent of the statute.
We first consider briefly appellee’s contention that the policy protects no one’s interests except Bunds’ for the reason that it does *668not contain the words “for whom it may concern” or their equivalent. In the first place, the policy itself recites that it covers “grain . . . handled or used by the insured in their business, their own, or held by them in trust or on storage, if in' case of loss the insured is legally liable therefor.” In the second place it is too clear to require discussion that the primary purpose of the statute, in the matter of insurance, is to protect the public, the depositors of stored grain, and the bona fide holders of warehouse receipts. To hold that the policy does not cover the grain itself, or that it is only intended to indemnify Bunds against nlainis"against him by the storers of grain would distort the policy and undermine the statute. (29 Am. Jur. 214, 215; Wilson Company v. Hartford Fire Insurance Co., 300 Mo. 1, 254 S. W. 266; Utica Canning Co. v. Home Ins. Co., 116 N. Y. S. 934, 937, 938.)
Appellee further contends that since the statute provides that in case' of loss by fire the warehouseman shall make settlement with grain depositors on the basis of market value, and that the depositors have right of action on the warehouseman’s bond, those are the exclusive remedies and grain owners have no right of action against the -insurance carrier. Adoption of that view would result, practically, in leaving the public unprotected save by the general credit and good faith of the warehouseman and by the bond. We think it ■was clearly the legislative intent to provide greater protection than that. The bond is conditioned upon faithful performance of all the many duties imposed upon the licensee by the statute — proper handling and care of the grain, keeping the grain insured, etc. We are advised that in the instant case the amount of the bond is $'5,000— far less than the losses alleged by appellants, to say nothing of losses by other depositors. The maximum bond, under the statute, is for $50,000. The fact that the maximum bond would in countless cases be wholly inadequate coverage is another indication that the bond was not intended as the only public protection supplementary to the credit and good faith of the licensee — the latter being at times valueless. Again the fact that warehouse receipts are generally negotiable — as they were in the instant case — and that the receipts-— upon forms prescribed under the act — recite upon their face that the grain they represent is covered by fire insurance, is persuasive indication that the owners were not to be left solely to recovery from the licensee or upon the bond.
Another indication of legislative intent is that the bond may bé *669written on the basis of only ten cents a bushel, while the insurance must cover full market value.
■One further and significant provision of the statute is to be noted -^•the cost ■ of the insurance is in fact paid by the owners who store the grain. The statute specifically and properly provides for its inclusion in the warehouse fees. (G. S. 1935, 34-235.)
Neither appellants nor appellees have called our attention to cases involving precisely the situation here presented and our own research has discovered none. But the principle which we think is here controlling has been often stressed. The case of Ott v. American Fidelity & Casualty Co., 161 S. C. 314, 159 S. E. 635, 76 A. L. R. 4, involved a public liability policy given by a motor carrier under a statute similar to ours. The policy required as a condition for recovery that the assured give immediate written notice of an accident with fullest information then obtainable. In an action brought against it by an injured person the insurance company resisted upon the ground that no such notice had been given, and that it had no knowledge that the accident had occurred until summons was served. The court said:
“This position would undoubtedly be correct in a suit brought against the insurer by the insured, but the same rule would not necessarily apply in a suit by an injured member of the public. We must assume that the policy was intended not to evade, but to effectuate the purposes of the statute in compliance with which it was filed and it must be construed in the light of such statute.” (Cases cited.) (p. 317.)
There is equal reason, here, why a defense as against the licensee should not bar recovery by the owners of the grain. In the Ott case, supra, the court also called attention to the general principle that a policy issued under the statutory requirement, for protection of the public “must be construed most strongly against the insurer.”
Appellee argues that Farney v. Hauser, 109 Kan. 75, 198 Pac. 178, supports its contention that appellants have no right to sue upon the policy. We cannot agree. It was said in that case that it is the duty of the warehouseman, in case of loss, to collect the insurance not only on his own property but upon the “property entrusted or bailed to him.” Cases may readily be imagined where the depositors might have occasion to hold him personally liable for having failed to do so. But the fact that the warehouseman has a right and duty to collect does not preclude direct action by the real parties in interest.
..Before concluding we take note of section 34-2,103, G. S. 1935, tile ■ last paragraph of the act, which provides: “This act shall be *670liberally interpreted and construed to effectuate its general purpose.”
We briefly summarize. Grain warehouses have been impressed with a public interest and on that basis subjected to thoroughgoing regulation. Among the protective provisions is the requirement that grain be insured at full market value. This insurance is primarily for the benefit of those whose grain is received for storage and who pay the cost of carrying the insurance. Warehouse receipts are in most cases negotiable and holders are entitled to protection incident to negotiability.
Construing the warehouse contract, as we must, in connection with the above and other provisions of the statute, we are impelled to the conclusion that it establishes not only a contractual relationship between the insurance carrier and the warehouseman, but also between the carrier and those whose grain is covered by the policy. To hold otherwise would deny to holders of warehouse receipts the protection' which the legislature intended they should have and which the insurance carrier in effect agreed to when it issued the policy.’ It follows that the appellants were entitled to bring action upon the contract and that recovery is not barred by the felonious act of Bunds.
The judgment is reversed and the cause remanded for further proceedings in harmony with this opinion.