Document:

<PAGE>

                                                                    Exhibit 10.5

PATENT AND PATENT
APPLICATION SECURITY AGREEMENT

         This Patent and Patent Application Security Agreement (the " PATENT
SECURITY AGREEMENT") is made the 1st day of September, 2004, by Dynamics
Research Corporation, a Massachusetts corporation with its principal executive
offices at 60 Frontage Road, Andover, Massachusetts 01810 (the "COMPANY"), and
Brown Brothers Harriman & Co., with offices at 40 Water Street, Boston,
Massachusetts 02109, as administrative agent for itself and for each of the
other Lenders (defined below) as may become parties to the Loan Agreement
(defined below) (the "Agent").

                                    RECITALS

         WHEREAS, pursuant to the Second Amended and Restated Loan Agreement
dated as of the date hereof (as same may be amended, modified or replaced from
time to time, the "LOAN AGREEMENT"), made by and among the Company and certain
affiliates of the Company (singly, a "BORROWER" and collectively, the
"BORROWERS"), the Agent, as administrative agent for a syndicate of Lenders (the
"LENDERS"), BankNorth, N.A., as Documentation Agent, KeyBank National
Association and Fleet National Bank, a Bank of America company, each as
Co-Syndication Agents, and such Lenders, the Agent and the Lenders have agreed
to make certain loans (hereinafter, the "LOANS") available to the Borrowers;

         WHEREAS, under a certain Security Agreement of even date herewith (as
same may be amended, modified or replaced from time to time, the "SECURITY
AGREEMENT"), the Borrowers have created a security interest in each such
Borrower's assets to secure the liabilities and obligations of the Borrowers to
the Agent and the Lenders (as defined in the Loan Agreement) (hereinafter, the
"LIABILITIES");

<PAGE>

         WHEREAS, as a condition, among others, to the continuation of the
credit facilities contemplated by the Loan Agreement, and to further secure the
Liabilities, the parties hereto shall execute this Patent Security Agreement.

         NOW THEREFORE, for good and valuable consideration, the receipt and
sufficiency of which are acknowledged, the Company and the Agent agree as
follows:

1.       To secure the Liabilities, the Company hereby grants a security
         interest in favor of the Agent for the benefit of the Lenders, with
         power of sale, in and to the following and all proceeds thereof:

         a.       All of the Company's now owned or existing or hereafter
                  acquired or arising letters patent, patent applications, and
                  the inventions and improvements therein disclosed, and any and
                  all divisions, reissues and continuations of said letters
                  patent including, without limitation the patents listed on
                  EXHIBIT A annexed hereto and made a part hereof, together with
                  any goodwill connected with and symbolized by any such
                  patents.

         b.       All renewals of any of the foregoing.

         c.       All income, royalties, damages and payments now and hereafter
                  due and/or payable under and with respect to any of the
                  foregoing, including, without limitation, payments under all
                  licenses entered into in connection therewith and damages and
                  payments for past or future infringements or dilutions
                  thereof.

         d.       The right to sue for past, present and future infringements
                  and dilutions of any of the foregoing.

         e.       All of Company's rights corresponding to any of the foregoing
                  throughout the world.

         All of the foregoing letters patent, patent applications described in
         Subsection a, together with the items respectively described in
         Subsections b through and including e are hereinafter individually
         and/or collectively referred to as the "Patents".

2.       Until this Patent Security Agreement is terminated, the Company shall
         undertake the following with respect to each Patent to the extent
         prudent in the exercise of its reasonable business judgment and
         provided that any failure to do so does not have a material adverse
         effect on the Company and its subsidiaries on a consolidated basis:

         a.       Pay all renewal fees and other fees and costs associated with
                  maintaining the Patents and with the processing of the
                  Patents.

         b.       At Company's sole cost, expense, and risk, pursue the prompt,
                  diligent, processing of each Application for Registration
                  which is the subject of the foregoing assignment and not
                  abandon or delay any such efforts.

                                     - 2 -

<PAGE>

         c.       At Company's sole cost, expense, and risk, take any and all
                  action which Company deems desirable to protect the Patents,
                  including, without limitation, but subject to Company's
                  discretion, the prosecution and defense of infringement
                  actions.

3.       Upon the occurrence of any Event of Default (as defined in the Loan
         Agreement), and until such Event of Default is cured, the Agent acting
         in its own name or in that of the Company may (but shall not be
         required to) act in the Company's place and stead and/or in the Agent's
         own right in connection with the obligations set forth in Section 2,
         above.

4.       The Company represents and warrants that:

         a.       The Patents listed on EXHIBIT A include all of the registered
                  Patents now owned by the Company.

         b.       No liens, claims or security interests have been granted by
                  the Company to any person or entity in such Patents other than
                  to the Agent or as otherwise permitted pursuant to the Loan
                  Agreement.

5.       In order to further secure the Liabilities:

         a.       The Company shall give the Agent written notice (with
                  reasonable detail) within thirty (30) days following the
                  occurrence of any of the following:

                  i.       The Company obtains rights to any new patents or
                           patent applications (other than Company's right to
                           sell products containing the patents of others in the
                           ordinary course of Company's business).

                  ii.      The Company becomes entitled to the benefit of any
                           patents or patent applications, whether as licensee
                           or licensor (other than Company's right to sell
                           products containing the patents of others in the
                           ordinary course of Company's business).

                  iii.     The Company enters into any new patent license
                           agreement.

         b.       The provisions of this Patent Security Agreement shall
                  automatically apply to any such additional property or rights
                  described in a, above, all of which shall be deemed to be and
                  treated as "Patents" within the meaning of this Patent
                  Security Agreement.

         c.       The Company hereby authorizes the Agent to modify this
                  agreement by amending EXHIBIT A to include any future patents
                  or patent applications, written notice of which is so given,
                  provided, however, the modification of said EXHIBIT A shall
                  not be a condition to the creation or perfection of the
                  security interest and Patent Security Agreement created
                  hereby.

6.       Upon the occurrence and during the continuance of any Event of Default
         (as defined in the Loan Agreement), the Agent may exercise all rights
         and remedies of a secured party under the Uniform Commercial Code as
         adopted in Massachusetts (Massachusetts

                                     - 3 -

<PAGE>

         General Laws, Chapter 106), with respect to the Patents, in addition to
         which the Agent, subject to the terms of the Loan Agreement, may sell,
         license, assign, transfer, or otherwise dispose of the Patents. Any
         person may conclusively rely upon an affidavit of an officer of the
         Agent that an Event of Default and demand has occurred and is
         continuing and that the Agent is authorized to exercise such rights and
         remedies.

7.       Effective upon the occurrence and during the continuance of any Event
         of Default (as defined in the Loan Agreement) the Company hereby
         irrevocably constitutes and designates the Agent as and for the
         Company's attorney in fact:

         a.       To exercise any of the rights exercisable and powers
                  referenced in Section 2.

         b.       To execute all and singular such instruments, documents, and
                  papers as the Agent determines to be appropriate in connection
                  with the exercise of such rights and remedies and to cause the
                  sale, license, assignment, transfer, or other disposition of
                  the Patents.

         The within grant of a power of attorney, being coupled with an
         interest, shall be irrevocable until the within Patent Security
         Agreement is terminated.

8.       Any use by the Agent of the Patents as authorized hereunder in
         connection with the exercise of the Agent's right and remedies under
         the within Patent Security Agreement and the Loan Agreement shall be
         coextensive with Company's rights thereunder and with respect thereto
         and without any liability for royalties or other related charges from
         the Agent to the Company.

9.       The Agent hereby grants to the Company the right, prior to notice from
         the Agent following the occurrence and during the continuance of an
         Event of Default (as defined in the Loan Agreement), to sue for past,
         present and future infringement of the Patents including the right to
         seek injunctions and/or money damages, in an effort by the Company to
         protect the Patents against encroachment by third parties. The Company
         shall notify the Agent in writing of any such suit for enforcement of
         the Patents against a particular party. All reasonable costs arising in
         connection with any such suit for enforcement shall be borne by the
         Company.

10.      Following the earlier to occur of (x) the Collateral Release Event (as
         defined in the Loan Agreement), or (y) the payment and satisfaction of
         all Liabilities, and the termination of any obligation of the Agent or
         any Lender to provide loans or financial accommodations under the
         credit facility contemplated by the Loan Agreement, this Patent
         Security Agreement shall terminate and the Agent shall promptly execute
         and deliver to the Company, at the Company's cost and expense, all such
         instruments as the Company reasonably may request to evidence such
         termination and to the extent, if any, necessary to re-vest in the
         Company full title to the Patents and the associated goodwill, subject
         to any disposition thereof which may have been made by Agent pursuant
         hereto or pursuant to the Loan Agreement.

11.      The Company shall, at the request of the Agent, do any and all acts and
         execute any and all documents reasonably required by the Agent in
         connection with the protection, preservation, and enforcement of the
         Agent's rights hereunder.

                                     - 4 -

<PAGE>

12.      The Company shall, upon demand, reimburse the Agent for all reasonable
         costs and expenses incurred by the Agent in the exercise of any rights
         hereunder (including, without limitation, reasonable fees and expenses
         of counsel).

13.      This Patent Security Agreement is intended to be supplemental of the
         Security Agreement. All provisions of the Security Agreement shall
         apply to the Patents, and the Agent shall have the same rights with
         respect to any and all Patents granted the Agent to secure the
         Liabilities hereunder as thereunder. In the event of a conflict between
         this Patent Security Agreement and the Security Agreement, the terms of
         this Patent Security Agreement shall control with respect to the
         Patents, and the Security Agreement shall control with respect to all
         other Collateral (as defined in the Loan Agreement).

                  [remainder of page left intentionally blank]

                                     - 5 -

<PAGE>

         IN WITNESS WHEREOF, the Company and the Agent respectively have caused
this Patent Security Agreement to be executed by officers duly authorized so to
do on the date first above written.

Dynamics Research Corporation               Brown Brothers Harriman & Co.,
                    (The "Company")                                (The "Agent")

By_________________________________         By________________________________

Title______________________________         Title_____________________________

                                     - 6 -

<PAGE>

                          COMMONWEALTH OF MASSACHUSETTS

County of Suffolk

         Then personally appeared before me _______________ who acknowledged
that such person is the duly authorized __________ of Dynamics Research
Corporation, and that such person executed the foregoing instrument as his free
act and deed on its behalf.

         Witness my hand and seal this _____ day of September, 2004.

                                               _________________________________
                                                            , Notary Public
                                                   My Commission Expires:

                          COMMONWEALTH OF MASSACHUSETTS

County of Suffolk

         Then personally appeared before me _________________, who acknowledged
that such person is the duly authorized Vice President of Brown Brothers
Harriman & Co., and that such person executed the foregoing instrument as his
free act and deed on its behalf.

         Witness my hand and seal this _____ day of September, 2004.

                                               _________________________________
                                                            , Notary Public
                                                   My Commission Expires:

                                     - 7 -

<PAGE>

                                    EXHIBIT A

Company's now owned or existing or hereafter acquired or arising registered
patents and patent applications, including, without limitation:

<TABLE>
<CAPTION>
   PATENT NO.                               TITLE TO PATENT
   ----------                               ---------------
<S>                    <C>
 (1)  6,567,429        Wide area multi-service broadband network
 (2)  6,387,724        Method of fabricating silicon-on-insulator sensor having
                       oxide sensing surface
 (3)  6,212,672        Software development system with an executable
                       working model in an interpretable intermediate modeling
                       language
 (4)  6,128,113        Transparent optical communications switch
 (5)  5,119,111        Edge-type printhead with contact pads
 (6)  5,081,471        True edge thermal printhead
 (7)  5,077,564        Arcuate edge thermal print head
 (8)  4,978,972        Modular thermal print head and method of fabrication
 (9)  4,954,225        Method for making nozzle plates
(10)  4,912,468        Non-linear error correction system
(11)  4,881,087        Printhead structure and method of fabrication
(12)  4,875,281        Method of fabricating a printhead
(13)  4,839,001        Orifice plate and method of fabrication
(14)  4,810,852        High-resolution thermal printhead and method of fabrication
</TABLE>

                                     - 8 -<PAGE>

                                                                    Exhibit 10.6

TRADEMARK AND TRADEMARK
APPLICATION SECURITY AGREEMENT

         This Trademark and Trademark Application Security Agreement (the "TM
SECURITY AGREEMENT") is made as of the 1st day of September, 2004, by Dynamics
Research Corporation, a Massachusetts corporation with its principal executive
offices at 60 Frontage Road, Andover, Massachusetts 01810 (the "COMPANY"), and
Brown Brothers Harriman & Co., with offices at 40 Water Street, Boston,
Massachusetts 02109, as administrative agent for itself and for each of the
other Lenders (defined below) as may become parties to the Loan Agreement
(defined below) (the "AGENT").

                                    RECITALS

         WHEREAS, pursuant to the Second Amended and Restated Loan Agreement
dated as of the date hereof (as same may be amended, modified or replaced from
time to time, the "LOAN AGREEMENT"), made by and among the Company and certain
affiliates of the Company (singly, a "BORROWER" and collectively, the
"BORROWERS"), the Agent, as administrative agent for a syndicate of Lenders (the
"LENDERS"), BankNorth, N.A., as Documentation Agent, KeyBank National
Association and Fleet National Bank, a Bank of America company, each as
Co-Syndication Agents, and such Lenders, the Agent and the Lenders have agreed
to make certain loans (hereinafter, the "LOANS") available to the Borrowers;

         WHEREAS, under a certain Security Agreement of even date herewith (as
same may be amended, modified or replaced from time to time, the "SECURITY
AGREEMENT"), the Borrowers have created a security interest in each such
Borrower's assets to secure the liabilities and obligations of the Borrowers to
the Agent and the Lenders (as defined in the Loan Agreement) (hereinafter, the
"LIABILITIES");

<PAGE>

         WHEREAS, as a condition, among others, to the continuation of the
credit facilities contemplated by the Loan Agreement, and to further secure the
Liabilities, the parties hereto shall execute this TM Security Agreement.

         NOW THEREFORE, for good and valuable consideration, the receipt and
sufficiency of which are acknowledged, the Company and the Agent agree as
follows:

1.       To secure the Liabilities, the Company hereby grants a security
         interest in favor of the Agent for the benefit of each of the Lenders,
         with power of sale, in and to the following and all proceeds thereof:

         a.       All of the Company's now owned or existing or hereafter
                  acquired or arising trademarks, trade registrations, trademark
                  applications, service marks, registered service marks and
                  service mark applications including, without limitation, the
                  trademarks, registered trademarks, trade mark applications,
                  service marks, registered service marks and service mark
                  applications listed on EXHIBIT A annexed hereto and made a
                  part hereof, together with any goodwill connected with and
                  symbolized by any such trademarks, trademark applications,
                  service marks, registered service marks or service mark
                  applications.

         b.       All renewals of any of the foregoing.

         c.       All income, royalties, damages and payments now and hereafter
                  due and/or payable under and with respect to any of the
                  foregoing, including, without limitation, payments under all
                  licenses entered into in connection therewith and damages and
                  payments for past or future infringements or dilutions
                  thereof.

         d.       The right to sue for past, present and future infringements
                  and dilutions of any of the foregoing.

         e.       All of Company's rights corresponding to any of the foregoing
                  throughout the world.

         All of the foregoing trademarks, registered trademarks and trademark
         applications, and service marks, registered service marks and service
         mark applications described in Subsection a, together with the items
         respectively described in Subsections b through and including e are
         hereinafter individually and/or collectively referred to as the
         "TRADEMARKS".

2.       Until this TM Security Agreement is terminated, the Company shall
         undertake the following with respect to each Trademark to the extent
         prudent in the exercise of its reasonable business judgment and
         provided that any failure to do so does not have a material adverse
         effect on the Company and its subsidiaries on a consolidated basis:

                                     - 2 -

<PAGE>

         a.       Pay all renewal fees and other fees and costs associated with
                  maintaining the Trademarks and with the processing of the
                  Trademarks.

         b.       At Company's sole cost, expense, and risk, pursue the prompt,
                  diligent processing of each Application for Registration which
                  is the subject of the foregoing assignment and not abandon or
                  delay any such efforts.

         c.       At Company's sole cost, expense, and risk, take any and all
                  action which Company deems desirable to protect the
                  Trademarks, including, without limitation, but subject to
                  Company's discretion, the prosecution and defense of
                  infringement actions.

3.       Upon the occurrence of any Event of Default (as defined in the Loan
         Agreement), and until such Event of Default is cured, the Agent acting
         in its own name or in that of the Company may (but shall not be
         required to) act in the Company's place and stead and/or in the Agent's
         own right in connection with the obligations set forth in Section 2,
         above.

4.       The Company represents and warrants that:

         a.       The Trademarks listed on EXHIBIT A include all of the
                  registered trademarks, Federal trademark applications,
                  registered service marks and Federal service mark applications
                  now owned by the Company.

         b.       No liens, claims or security interests have been granted by
                  the Company to any person or entity in such Trademarks other
                  than to the Agent or as otherwise permitted pursuant to the
                  Loan Agreement.

5.       In order to further secure the Liabilities:

         a.       The Company shall give the Agent written notice (with
                  reasonable detail) within thirty (30) days following the
                  occurrence of any of the following:

                  i.       The Company obtains rights to any new registered
                           trademarks, registered service marks or service mark
                           applications, (other than Company's right to sell
                           products containing the trademarks of others in the
                           ordinary course of Company's business)

                  ii.      The Company becomes entitled to the benefit of any
                           registered trademarks, trademark applications,
                           trademark licenses, trademark license renewals,
                           service marks, registered service marks, service mark
                           applications, service mark licenses or service mark
                           license renewals whether as licensee or licensor
                           (other than Company's right to sell products
                           containing the trademarks of others in the ordinary
                           course of Company's business).

                  iii.     The Company enters into any new trademark license
                           agreement or service mark license agreement.

         b.       The provisions of this TM Security Agreement shall
                  automatically apply to any such additional property or rights
                  described in a, above, all of which shall be

                                     - 3 -

<PAGE>

                  deemed to be and treated as "Trademarks" within the meaning of
                  this TM Security Agreement.

         c.       The Company hereby authorizes the Agent to modify this
                  agreement by amending EXHIBIT A to include any future
                  trademarks, registered trademarks, trademark applications,
                  service marks, registered service marks and service mark
                  applications, written notice of which is so given, provided,
                  however, the modification of said EXHIBIT A shall not be a
                  condition to the creation or perfection of the security
                  interest and TM Security Agreement created hereby.

6.       Upon the occurrence and during the continuance of any Event of Default
         (as defined in the Loan Agreement), the Agent may exercise all rights
         and remedies of a secured party under the Uniform Commercial Code as
         adopted in Massachusetts (Massachusetts General Laws, Chapter 106),
         with respect to the Trademarks, in addition to which the Agent, subject
         to the terms of the Loan Agreement, may sell, license, assign,
         transfer, or otherwise dispose of the Trademarks. Any person may
         conclusively rely upon an affidavit of an officer of the Agent that an
         Event of Default and demand has occurred and is continuing and that the
         Agent is authorized to exercise such rights and remedies.

7.       Effective upon the occurrence and during the continuance of any Event
         of Default (as defined in the Loan Agreement), the Company hereby
         irrevocably constitutes and designates the Agent as and for the
         Company's attorney in fact:

         a.       To exercise any of the rights exercisable and powers
                  referenced in Section 2.

         b.       To execute all and singular such instruments, documents, and
                  papers as the Agent determines to be appropriate in connection
                  with the exercise of such rights and remedies and to cause the
                  sale, license, assignment, transfer, or other disposition of
                  the Trademarks.

         The within grant of a power of attorney, being coupled with an
         interest, shall be irrevocable until the within TM Security Agreement
         is terminated.

8.       Any use by the Agent of the Trademarks as authorized hereunder in
         connection with the exercise of the Agent's right and remedies under
         the within TM Security Agreement and the Loan Agreement shall be
         coextensive with the Company's rights thereunder and with respect
         thereto and without any liability for royalties or other related
         charges from the Agent to the Company.

9.       The Agent hereby grants to the Company the right, prior to notice from
         the Agent following the occurrence and during the continuance of an
         Event of Default (as defined in the Loan Agreement), to sue for past,
         present and future infringement of the Trademarks including the right
         to seek injunctions and/or money damages, in an effort by the Company
         to protect the Trademarks against encroachment by third parties. The
         Company shall notify Agent in writing of any such suit for enforcement
         of the trademarks against a particular party. All reasonable costs
         arising in connection with any such suit for enforcement shall be borne
         by the Company.

10.      Following the earlier to occur of (x) the Collateral Release Event (as
         defined in the Loan Agreement), or (y) the payment and satisfaction of
         all Liabilities, and the termination of

                                     - 4 -

<PAGE>

         any obligation of the Agent or any Lender to provide loans or financial
         accommodations under the credit facility contemplated by the Loan
         Agreement, this TM Security Agreement shall terminate and the Agent
         shall promptly execute and deliver to the Company, at the Company's
         cost and expense, all such instruments as the Company reasonably may
         request to evidence such termination and to the extent, if any,
         necessary to re-vest in the Company full title to the Trademarks and
         the associated goodwill, subject to any disposition thereof which may
         have been made by the Agent pursuant hereto or pursuant to the Loan
         Agreement.

11.      The Company shall, at the request of the Agent, do any and all acts and
         execute any and all documents reasonably required by the Agent in
         connection with the protection, preservation, and enforcement of the
         Agent's rights hereunder.

12.      The Company shall, upon demand, reimburse the Agent for all reasonable
         costs and expenses incurred by the Agent in the exercise of any rights
         hereunder (including, without limitation, reasonable fees and expenses
         of counsel).

13.      This TM Security Agreement is intended to be supplemental of the
         Security Agreement. All provisions of the Security Agreement shall
         apply to the Trademarks and the Agent shall have the same rights with
         respect to any and all Trademarks granted the Agent to secure the
         Liabilities hereunder as thereunder. In the event of a conflict between
         this TM Security Agreement and the Security Agreement, the terms of
         this TM Security Agreement shall control with respect to the
         Trademarks, and the Security Agreement shall control with respect to
         all other Collateral (as defined in the Loan Agreement).

                  [remainder of page left intentionally blank]

                                     - 5 -

<PAGE>

         IN WITNESS WHEREOF, the Company and the Agent respectively have caused
this TM Security Agreement to be executed by officers duly authorized so to do
on the date first above written.

Dynamics Research Corporation                Brown Brothers Harriman & Co.,
                        (The "Company")                          (The "Agent")

By_________________________________            By_______________________________

Title______________________________            Title____________________________

                                     - 6 -

<PAGE>

                          COMMONWEALTH OF MASSACHUSETTS

County of Suffolk

         Then personally appeared before me ________________ who acknowledged
that such person is the duly authorized _________ of Dynamics Research
Corporation and that such person executed the foregoing instrument as his free
act and deed on its behalf.

         Witness my hand and seal this _____ day of September, 2004.

                                               _________________________________
                                                              , Notary Public
                                                      My Commission Expires:

                          COMMONWEALTH OF MASSACHUSETTS

County of Suffolk

         Then personally appeared before me __________________, who acknowledged
that such person is the duly authorized _____________________ of Brown Brothers
Harriman & Co., and that such person executed the foregoing instrument on its
behalf.

         Witness my hand and seal this _____ day of September, 2004.

                                               _________________________________
                                                            , Notary Public
                                                    My Commission Expires:

                                     - 7 -

<PAGE>

                                    EXHIBIT A

                               U.S. Registrations

                           Mark            Registration No.
                           ----            ----------------

                                     - 8 -

Source: [{"source": "alea-institute/alea-institute/kl3m-data-edgar-agreements/train-00071-of-00352.parquet"}, [{"source": "alea-institute/alea-institute/kl3m-data-edgar-agreements/train-00071-of-00352.parquet"}]]