<PAGE>

                                                                  Exhibit 10.40e
                                   EXHIBIT E
                                   ---------

                   FORM OF LEGAL OPINION OF COMPANY COUNSEL
<PAGE>

                    SHEPPARD, MULLIN, RICHTER & HAMPTON LLP
      A LIMITED LIABILITY PARTNERSHIP INCLUDING PROFESSIONAL CORPORATIONS

                               ATTORNEYS AT LAW
                               SEVENTEENTH FLOOR
                            FOUR EMBARCADERO CENTER
                     SAN FRANCISCO, CALIFORNIA  94111-4106

WRITER'S DIRECT LINE      TELEPHONE (415) 434-9100  OUR FILE NUMBER
    (415) 434-9100                 ----------         SYI-61968
                          FACSIMILE (415) 434-3947

                                March 10, 2000


Ward North America Holding, Inc.
610 West Ash Street, Suite 1500
San Diego, CA 92101

          Re:   Securities Purchase Agreement
                -----------------------------

Ladies and Gentlemen:

          We have acted as counsel to Anchor Pacific Underwriters, Inc., a
Delaware corporation (the "Company"), in connection with that certain Securities
Purchase Agreement (the "Agreement") dated March 9, 2000, between the Company
and Ward North America Holding, Inc. ("Ward"). This letter is delivered pursuant
to Section 5.1(h) of the Agreement.

          In the preparation of this opinion, we have examined originals or
copies of such documents and instruments as we have deemed appropriate,
including the following:

          A. The Agreement;

          B. The Registration Rights Agreement dated March 9, 2000, between the
             Company and Ward (the "Registration Rights Agreement");

          C. The Investor Rights Agreement dated March 9, 2000, between the
             Company and Ward (the "Investor Rights Agreement");

          D. The Convertible Promissory Note and Loan Agreement dated March
             9,2000, between the Company and Ward (the "Note");

          E. The Certificate of Designations of Series A Convertible Preferred
             Stock of Anchor Pacific Underwriters, Inc. dated March 9, 2000 (the
             "Certificate of Designations");


LOS ANGELES    *    ORANGE COUNTY   *     SAN DIEGO    *     SAN FRANCISCO
<PAGE>

SHEPPARD, MULLIN, RICHTER & HAMPTON LLP

     Ward North America Holding, Inc.
     March 10, 2000
     Page 2

               F. The Certificate of Amendment to the Certificate of
                  Incorporation of the Company (the "Certificate of Amendment");

               G. A copy of the Amended and Restated Certificate of
                  Incorporation of the Company, as filed with the Secretary of
                  State of the State of Delaware;

               H. A copy of the Bylaws of the Company, certified by an officer
                  of the Company;

               I. A copy of the resolutions of the shareholders of the Company
                  approving the Certificate of Amendment certified by an officer
                  of the Company; and

               J. A copy of the resolutions of the directors of the Company,
                  certified by an officer of the Company.

               The Agreement, the Registration Rights Agreement, the Investor
     Rights Agreement, and the Note are hereinafter collectively referred to as
     the "Transaction Documents."

               In rendering the opinions set forth below, we have assumed:

               a. The genuineness of all signatures (other than those signed by
     or on behalf of the Company), the authenticity of all documents submitted
     to us as originals, the conformity to the originals of all documents
     submitted to us as copies, and the authenticity of all such originals.

               b. The due authorization, execution and delivery of the
     Transaction Documents by and on behalf of Ward.

               c. That the Transaction Documents are the legal, valid and
     binding obligation of Ward, and that Ward has all requisite power and
     authority and has taken any and all action necessary to be taken by Ward to
     execute and deliver the Transaction Documents.

               Based upon the foregoing, and subject to the assumptions,
     exceptions, qualifications and limitations set forth herein, we are of the
     opinion that:

               1. The Company is a corporation duly organized, validly existing
<PAGE>

SHEPPARD, MULLIN, RICHTER & HAMPTON LLP

     Ward North America Holding, Inc.
     March 10, 2000
     Page 3

          and in good standing under the laws of the State of Delaware. The
          Company has the corporate power and authority to own its properties
          and assets, to carry on its business as presently conducted, and to
          enter into the Transaction Documents and perform its obligations
          thereunder, including without limitation the sale and issuance of the
          shares of Series A Preferred Stock being purchased by the Ward.

               2.  Except as disclosed in the schedules to the Agreement, the
          Company is duly qualified to do business as a foreign corporation and
          is in good standing in each other state in which the nature of its
          activities or of its properties owned or leased makes such
          qualification necessary, except to the extent that failure to so
          qualify would not have a material adverse effect on the Company.

               3.  Each of the Transaction Documents has been duly authorized by
          all necessary corporate action on the part of the Company and has been
          duly executed and delivered by the Company.

               4.  Each of the Transaction Documents is a legal, valid and
          binding obligation of the Company enforceable against it in accordance
          with its term except as the enforceability thereof may be subject to
          or limited by (a) bankruptcy, insolvency, reorganization, arrangement,
          moratorium, or other similar laws relating to or affecting rights of
          creditors and (b) general equitable principles, regardless of whether
          the issue of enforceability is considered in a proceeding in equity or
          at law.

               5.  The authorized capital stock of the Company consists of (a)
          16,000,000 shares of Common Stock (the "Common Stock") of which
          4,710,055 shares are issued and outstanding, and (b) 2,000,000 shares
          of Preferred Stock (the "Preferred Stock"), none of which are
          outstanding. All presently outstanding shares of the Company's capital
          stock have been duly authorized and validly issued, and are fully paid
          and nonassessable. Except as disclosed in or contemplated by the
          Agreement or the exhibits and schedules delivered in connection
          therewith, there are, to our current actual knowledge, (x) no
          outstanding subscriptions, warrants, options, calls, claims,
          commitments, convertible securities or other agreements or
          arrangements under which the Company is or may be obligated to issue
          shares of its capital stock, and (y) no preemptive or similar rights
          to subscribe for or to purchase capital stock of the
<PAGE>

SHEPPARD, MULLIN, RICHTER & HAMPTON LLP

     Ward North America Holding, Inc.
     March 10, 2000
     Page 4

          Company.

               6.  Subject to the Delaware Secretary of State accepting for
          filing the Certificate of Designations, the shares of Series A
          Preferred Stock to be issued to Ward pursuant to the Agreement have
          been duly authorized and, when issued and paid for in accordance with
          the terms of the Agreement will be validly issued, fully paid and
          nonassessable.

               7.  Based in part upon the representations of Ward contained in
          the Agreement the offer, sale, issuance and delivery of the shares of
          Series A Preferred Stock to Ward under the circumstances contemplated
          by the Agreement are exempt from the registration requirements of the
          Securities Act of 1933, as amended (the "Securities Act"), and the
          qualification requirements of the California Corporate Securities Law
          of 1969, as amended.

               8.  The execution and delivery of the Transaction Documents and
          the performance by the Company of their respective terms (a) will not
          breach or result in a violation of the Company's Amended and Restated
          Certificate of Incorporation or Bylaws, or any Judgment, order or
          decree of any court or arbitrator, known to us, to which the Company
          is a party or is subject (b) is neither prohibited by, nor subjects
          the Company to, a fine, penalty or similar sanction under, nor will
          result in the creation of any lien, charge or encumbrance upon any of
          the assets of the Company pursuant to, any statute or regulation of
          the type which are typically applicable to transactions similar to
          those transactions contemplated by the Agreement, (c) will not
          constitute a material breach of the terms, conditions or provisions
          of, or constitute a default under, or result in the creation of any
          lien, charge or encumbrance upon any of the assets of the Company
          pursuant to, any contract, undertaking, indenture or other agreement
          or instrument identified in Schedule 2.7 to the Agreement.

               9.  No consent approval or authorization of, or designation,
          declaration or filing with, any governmental authority is required in
          connection with the valid execution, delivery and performance by the
          Company of the Transaction Documents, other than such consents,
          approvals, designations, declarations or filings as have been made or
          obtained on or before the date hereof or which are not required to be
          made or obtained until after the date hereof.
<PAGE>

SHEPPARD, MULLIN, RICHTER & HAMPTON LLP

     Ward North America Holding, Inc.
     March 10, 2000
     Page 5

               10.   Except as disclosed in the Agreement or the exhibits and
          schedules delivered in connection therewith, there is, to our current
          actual knowledge, no action, suit or proceeding pending against the
          Company or its properties in any court or before any governmental
          authority or agency, or arbitration board or tribunal (a) which seeks
          to restrain, enjoin, prevent the consummation of, or otherwise
          challenge the Agreement or any of the transactions contemplated
          thereby, or (b) which, if adversely determined, could have a material
          adverse effect on the Company or its business or properties.

               Our opinion set forth above is subject to the qualification that
     certain further corporate actions must be taken by the Company to enable it
     to perform fully all of its obligations under the Transaction Documents. As
     noted above, the Certificate of Designations must be filed with the
     Secretary of State of Delaware. The Certificate of Amendment must also be
     filed with the Secretary of State of Delaware, which may not be done until
     at least 20 days after the Company has distributed an information statement
     to its shareholders. Finally, before additional shares of Series A
     Preferred Stock can be issued upon the conversion of the Note, the
     directors of the Company must adopt resolutions designating additional
     shares of such stock, and an appropriate document must be filed with the
     Secretary of State of Delaware.

               Our opinion set forth above speaks only as of the due hereof and
     is based solely upon the existing laws of the State of California, the
     General Corporation Law of the State of Delaware (the "DGCL") and the
     federal laws of the United States, and we express no opinion, and none
     should be inferred, as to any other laws. We are not passing upon the
     applicability of the law of any states to the Agreement, and our opinions
     above are limited to the substantive state laws of the State of California,
     the DGCL and the federal laws of the United States. We disclaim any
     obligation to update this opinion letter for events occurring after the
     date of this opinion letter.

               This opinion letter is provided at your request and solely to you
     for use in connection with the transactions provided for in the Agreement.
     This opinion letter may not be relied upon by any other person or for any
     other purpose, nor may it be quoted from or referred to, or copies
     delivered to any other person, without our prior written consent

                           Very truly yours,

                           /s/ Sheppard, Mullin, Richter & Hampton LLP