<PAGE>   1
                                                                    EXHIBIT 10.4

                              CONSULTING AGREEMENT

         THIS CONSULTING AGREEMENT made and entered into effective as of March
1, 2001 ("Effective Date") by and between CyberGuard Corporation, Florida
corporation with principal place of business located at 2000 W. Commercial
Blvd., Fort Lauderdale, FL 33309, U.S.A. ("Company"), and David R. Proctor, an
individual residing at 8119 Chalk Knoll Drive, Austin, TX 78735 ("Consultant");

     WHEREAS, subject to the terms and conditions hereinafter set forth, the
Company wishes to retain the services of the Consultant, and the Consultant is
willing to provide consulting services to the Company.

         NOW, THEREFORE, in consideration of the premises and the mutual
promises and covenants contained herein and other good and valuable
consideration, and intending to be legally bound hereby, the parties hereto
agree as follows:

         1.       TERM. Subject to the provisions for termination hereinafter
                  set forth, the Company hereby engages the Consultant, and the
                  Consultant hereby accepts such engagement by the Company, as a
                  consultant, on the basis as an independent contractor, for a
                  term commencing on the Effective Date and continuing for one
                  (1) year ("Term"). This Agreement will terminate upon
                  expiration of the Term and may be renewed only upon both
                  parties' written agreement.

         2.       DUTIES. During the Term, the Consultant shall perform such
                  services and complete such duties hereunder (i) as are
                  assigned to him by the Chief Executive Officer of the Company
                  ("CEO") and (ii) that are outside of the scope of the
                  Consultant's duties as the Chairman, or a member, of the
                  Company's Board of Directors.

         3.       FEES. During the Term and for the due and faithful performance
                  of the services contemplated by this Agreement, the Company
                  will pay the Consultant a fee in the amount of one thousand
                  U.S. dollars ($1,000.00) ("Fee") for each day the Consultant
                  provides services hereunder, as assigned by the CEO; provided,
                  however that the Consultant obtains a written approval from
                  the CEO prior to commencing any services hereunder. In support
                  of the Fees to be paid, the Consultant will submit appropriate
                  supporting documentation and monthly billing/invoice
                  documents.

         4.       EXPENSES. The Company will reimburse the Consultant for his
                  reasonable and necessary business expenses related to the
                  performance of duties hereunder. In support of expenses to be
                  reimbursed, the Consultant will submit appropriate supporting
                  documentation and receipts in accordance with Company policy
                  and monthly billing/invoice documents.

         5.       INDEPENDENT CONTRACTOR. The Consultant shall be and remain
                  only an independent contractor. Nothing contained herein shall
                  be deemed or construed to create any association, partnership,
                  joint venture, employer/employee relationship. The Consultant
                  shall not be eligible to participate in any benefit plans,
                  programs or arrangements made available to employees of the
                  Company. The Consultant expressly acknowledges and agrees that
                  he will not be treated and will not seek to be treated as an
                  employee of the Company for any purpose.

         6.       TERMINATION OF AGREEMENT. This Agreement may be terminated by
                  either party hereto at anytime upon thirty (30) days prior
                  written notice to the other party. This Agreement may be
                  terminated by the Company, and such termination will be
                  immediate, if the Company states as cause for the termination:
                  a material breach of this Agreement; or an act of gross
                  negligence or willful misconduct by the Consultant; or the
                  commission of a felony or other act that constitutes a
                  material breach of reasonable business ethics by the
                  Consultant ("Cause").





                                       1
<PAGE>   2

7.       LIMITATION OF LIABILITY. Notwithstanding anything to the contrary, in
         no event shall CyberGuard's aggregate liability for damages arising
         from or in connection with this Agreement exceed the amount of the Fees
         payable by CyberGuard to Consultant under this Agreement during the
         three (3) month period preceding the date a claim arises.
         Notwithstanding anything to the contrary, in no event shall CyberGuard
         be liable for any indirect, incidental, consequential, special,
         punitive or exemplary damages arising out of or in connection with this
         Agreement.

8.       MISCELLANEOUS.

         (a)      The invalidity or unenforceability of any particular
                  provisions of this Agreement shall not affect the other
                  provisions hereof; and this Agreement shall be construed in
                  all respects as if such invalid or unenforceable provisions
                  were omitted.

         (b)      This Agreement constitutes and expresses the entire agreement
                  of the parties with respect to the subject matter hereof and
                  supersedes and cancels all prior negotiations, discussions,
                  agreements and understandings relating to such subject matter.
                  This Agreement may not be modified or amended except by an
                  instrument in writing executed by both parties hereto.

         (c)      This Agreement shall be binding upon the parties hereto, their
                  heirs, legal representatives, successors, and assigns and
                  shall not be assignable by either party, except upon prior
                  written consent by both parties to this Agreement, except that
                  the Company may assign its rights and delegate its duties
                  hereunder to any business entity with which the Company
                  engages in merger, share exchange, assets sale, or similar
                  corporate transaction.

         (d)      All required or permitted notices, requests, demands and other
                  communications hereunder shall be in writing and shall be
                  deemed effectively given on the day of delivery if delivered
                  by hand, or on the third day after mailing if mailed within
                  the continental United States by first class certified mail,
                  return receipt requested, postage prepaid.

         (e)      This Agreement shall be governed by the law of the State of
                  Florida and the exclusive jurisdiction and venue for resolving
                  any disputes hereunder shall be the courts located in Broward
                  County, State of Florida.

         (f)      Failure by either party at any time to enforce any obligation
                  by the other party, to claim a breach of any term of this
                  Agreement or to exercise any power agreed to hereunder will
                  not be construed as a waiver of any right, power or obligation
                  under this Agreement, will not affect any subsequent breach,
                  and will not prejudice either party as regards any subsequent
                  action.

         (g)      The provisions of this Agreement that by their nature and
                  content are intended to survive the performance hereof, shall
                  so survive and continue beyond any completion or termination
                  of this Agreement.

IN WITNESS WHEREOF, the parties hereto have executed this Agreement the day and
year first above written.



CYBERGUARD CORPORATION                       CONSULTANT


By:
   ------------------------------            -----------------------------------
   Scott J. Hammack, CEO                     David R. Proctor





                                       2