QuickLinks -- Click here to rapidly navigate through this document

Exhibit 10.31

STOCKHOLDER AGREEMENT

        This Stockholder Agreement (the "Agreement") is entered into as of
April 19, 2002 (the "Effective Date") by and among GRIC Communications, Inc., a
Delaware corporation (the "Company"), Asia Pacific Growth Fund III, L.P., a
Cayman entity ("Asia Pacific"), Vertex Technology Fund Ltd., Vertex Technology
Fund (II) Ltd. and Vertex Technology Fund (III) Ltd. (the later three being
entities formed under the laws of Singapore and collectively referred to as
"Vertex"), STT Ventures Ltd, an entity organized under the laws of Mauritius,
Green Dot Capital (BVI) Inc, an entity organized under the laws of the British
Virgin Islands, and Singapore Computer Systems Limited, an entity organized
under the laws of Singapore (STT Ventures Ltd, Green Dot Capital (BVI) Inc and
Singapore Computer Systems Limited, collectively "Vertex Assignees").
Hereinafter, the parties to the Agreement, other than the Company, will be
collectively referred to as the "Investors".

W I T N E S S E T H:

        WHEREAS, the Company and the Investors have entered into that certain
Amended and Restated Series A Preferred Stock and Warrant Purchase Agreement
(the "Series A Agreement") dated as of April 19, 2002 pursuant to which the
Company has agreed to sell to the Investors, and the Investors have agreed to
purchase from the Company, shares of the Company's Series A Preferred Stock (the
"Series A Preferred Stock") and warrants to purchase shares of Series A
Preferred Stock (the "Warrants"); and

        WHEREAS, the Company and the Investors deem it to be in their best
interests to provide for certain matters with respect to the governance of the
Company and desire to enter into this Agreement in order to effectuate that
purpose.

        NOW, THEREFORE, in consideration of the mutual agreements and
understandings set forth herein, the parties hereto hereby agree as follows:

        1)    Definitions.    As used in this Agreement, the following terms
shall have the meanings set forth below:

        a)    "Board" shall mean the board of directors of the Company.

        b)    "Change of Control" shall mean (a) any reorganization,
consolidation, merger or similar transaction or series of related transactions
(each, a "combination transaction")) in which the Company is a constituent
corporation or is a party if, as a result of such combination transaction, the
voting securities of the Company that are outstanding immediately prior to the
consummation of such combination transaction (other than any such securities
that are held by an "Acquiring Stockholder", as defined below) do not represent,
or are not converted into, securities of the surviving corporation of such
combination transaction (or such surviving corporation's parent corporation if
the surviving corporation is owned by the parent corporation) that, immediately
after the consummation of such combination transaction, together possess at
least a majority of the total voting power of all securities of such surviving
corporation (or its parent corporation, if applicable) that are outstanding
immediately after the consummation of such combination transaction, including
securities of such surviving corporation (or its parent corporation, if
applicable) that are held by the Acquiring Stockholder; or (b) a sale of all or
substantially all of the assets of the Company, that is followed by the
distribution of the proceeds to the Company's stockholders. For purposes of this
subsection 1(b), an "Acquiring Stockholder" means a stockholder or stockholders
of the Company that (i) merges or combines with the Company in such combination
transaction or (ii) owns or controls a majority of another corporation that
merges or combines with the Company in such combination transaction.

--------------------------------------------------------------------------------

        c)    "Common Stock" shall mean the common stock, par value $0.001 per
share, of the Company and any securities of the Company into which such Common
Stock may be reclassified, exchanged or converted.

        d)    "Common Stockholders" shall mean the holders of the Company's
Common Stock.

        e)    "Exchange Act" shall mean the Securities Exchange Act of 1934, as
amended, and the rules and regulations promulgated thereunder.

        f)    "Group" means two or more individuals and/or entities that are a
"person" (within the meaning of Section 13(d) of the Exchange Act) formed for
the purpose of acquiring, holding, voting or disposing of Common Stock and/or
Preferred Stock (as defined herein).

        g)    "Investors' Rights Agreement" shall mean that certain Investors'
Rights Agreement dated of even date herewith by and among the Company and the
Investors.

        h)    "Preferred Stock" shall mean any series of preferred stock, par
value $0.001 per share, of the Company and any securities of the Company into
which such Preferred Stock may be reclassified, exchanged or converted.

        i)    "SEC" shall mean the United States Securities and Exchange
Commission.

        j)    "Standstill Period" shall mean the period from the Effective Date
until the earliest to occur of the following: (i) the fifth anniversary of the
Effective Date, (ii) the date the Company enters into an agreement which, if
consummated, would result in a Change of Control of the Company, (iii) a third
party tender offer for the Company, (iv) a Change of Control of the Company, or
(v) a reduction of the collective beneficial ownership of the Common Stock
and/or Preferred Stock of the Company by the Investors and their respective
affiliates to below twenty percent (20%) of the Total Voting Power (as defined
below) of the Company.

        k)    "Total Voting Power" shall mean the total number of votes which
may be cast in the election of members of the Board if all securities entitled
to vote thereon are present and voted.

        l)    "Voting Agreement" shall mean that certain Amended and Restated
Voting Agreement dated of even date herewith by and among the Company, the
Investors and certain other Company stockholders.

        2)    Voting.    During the Standstill Period, each Investor (and their
respective transferees who are their affiliates ("Affiliated Transferees"))
shall cause all shares of Preferred Stock and Common Stock held by such Investor
or its Affiliated Transferees to be voted in favor of any of the following
proposals submitted to a vote of the Company's stockholders: (i) any transaction
contemplating a Change of Control to be effected pursuant to an agreement
approved by the Board (including any amendment to the Company's Certificate of
Incorporation required to effect any such transaction, so long as same does not
change the liquidation preference of the Series A Preferred Stock), provided
that the monetary value to be received pursuant to such Change of Control
transaction by any Investors or Affiliated Transferees is at least $3.32 per
share of Preferred Stock held immediately prior to the Change of Control, on an
as converted to Common Stock basis (such figure to be adjusted for stock splits,
stock dividends, recapitalizations and the like) and provided further that the
Investors and Affiliated Transferees shall not be required to provide any
representation or warranties in respect of the transaction, (ii) the sale and
issuance of Common Stock in a public offering (including any amendment to the
Company's Certificate of Incorporation required to effect any such transaction,
so long as same does not change the liquidation preference of the Series A
Preferred Stock), or (iii) an acquisition by the Company of another corporation
or entity utilizing Common Stock as the form of consideration; provided,
however, that this Section 2 shall only apply when the shares voted by the
stockholders of the Company (excluding the shares held by the Investors) in
favor of the proposal to

2

--------------------------------------------------------------------------------

implement one of the transactions described above constitute a majority of the
outstanding shares of Common Stock and Preferred Stock of the Company voting
together as a single class.

        3)    No Dissent.    During the Standstill Period (a) the Investors
shall not exercise any statutory dissenter's or appraisal rights with respect to
a Change of Control to be effected pursuant to an agreement approved by the
Board, and (b) Affiliated Transferees of Investors shall not exercise any
statutory dissenter's or appraisal rights with respect to any Change of Control
to be effected pursuant to an agreement approved by the Board; provided that,
with respect to the Affilated Transferees of Vertex, at least 1 of the directors
who represents Vertex on the Board has voted in favor of such transaction and
with respect to the Affilated Transferees of Asia Pacific, at least 1 of the
directors who represents Asia Pacific on the Board has voted in favor of such
transaction.

        4)    Standstill.    During the Standstill Period, the Investors and
their Affiliated Transferees shall not directly or indirectly, nor shall the
Investors or their Affiliated Transferees authorize or direct any of their
respective representatives (excluding directors who represent any Investor on
the Board acting in their capacity as members of the Board) to, in each case
unless specifically authorized to do so or consented to in writing in advance by
the Board:

        a)    acquire or agree, offer, seek or propose to acquire, or cause to
be acquired, beneficial ownership of any voting stock of the Company or any
options, warrants or other rights (including, without limitation, any
convertible or exchangeable securities) to acquire any voting stock of the
Company, except pursuant to the Investors' Rights Agreement, the Voting
Agreement or upon the exercise of any options, warrants or other rights
(including, without limitation, any convertible or exchangeable securities) held
by the Investors;

        b)    make, or in any way participate in, any "solicitation" of
"proxies" (as such terms are used in the proxy rules of the SEC) with respect to
the voting of any securities of the Company; provided, however, that the
limitation contained in this clause (b) shall not restrict the Investors from
communicating their views on any transaction proposed by the Company to the
stockholders of the Company;

        c)    deposit any securities of the Company held by such Investor in a
voting trust or subject any such securities to any arrangement or agreement with
any person;

        d)    form, join, or in any way become a member of a Group (involving
parties or entities other than Asia Pacific and/or Vertex, with the
understanding that Vertex and any of its affiliates may not form a Group that
includes Asia Pacific or any of Asia Pacific's affiliates and that Asia Pacific
and any of its affiliates may not form a Group that includes Vertex or any of
Vertex's affiliates) with respect to any voting securities of the Company;

        e)    seek to propose or propose, whether alone or in concert with
others, any tender offer, exchange offer, merger, business combination,
restructuring, liquidation, recapitalization or similar transaction involving
the Company;

        f)    nominate any person as a director of the Company who is not
nominated by the then incumbent directors, or propose any matter to be voted
upon by the stockholders of the Company, except for nominations of the
representatives of the Preferred Stock on the Board contemplated by the Voting
Agreement and/or the Certificate of Amendment to the Second Amended and Restated
Certificate of Incorporation of the Company (the "Certificate of Amendment") to
become effective on or about the Effective Date;

        g)    seek, either alone or in concert with others, to elect a majority
of the directors of the Board in order to control the policies of the Company;

        h)    sell securities of the Company to any person (other than an
Affiliated Transferee) that is known (without any duty of investigation) by the
selling party to be seeking control of the

3

--------------------------------------------------------------------------------

Company; provided that this clause shall not apply if Hong Chen or Lynn Ya-Lin
Liu has sold, or has entered into any agreement to sell his or her shares of
Common Stock to such party seeking control of the Company;

        i)    sell securities of the Company constituting more than twenty
percent (20%) of the Total Voting Power at a price that is more than ten percent
(10%) above the then current trading price of the Common Stock as most recently
reported in the Wall Street Journal ("Current Price"); provided that this clause
shall not apply if Hong Chen or Lynn Ya-Lin Liu has sold, or has entered into
any agreement to sell, a majority of his or her shares of Common Stock at a
price that is more than ten percent (10%) above the Current Price; or

        j)    publicly announce or disclose any intention, plan or arrangement
inconsistent with the foregoing restrictions.

        5)    Fiduciary Duties.    Notwithstanding anything set forth under this
Agreement with respect to an Investor that has representation on the Board,
nothing herein shall limit or change the fiduciary duties or rights of any
director of the Board acting in such capacity, or require such director to act
in a manner inconsistent with the fiduciary duties of a director of the Board.

        6)    General Provisions.    

        a)    Notices.    Any notice, request or other communication required or
permitted hereunder shall be in writing and shall be deemed to have been duly
given if personally delivered or if deposited in the U.S. mail by registered or
certified mail, return receipt requested, postage prepaid, as follows:

        i)    if to the Company, at:

GRIC Communications, Inc.
1421 McCarthy Boulevard
Milpitas, California 95035
Attention: David Teichmann, Esq.
Telephone: (408) 965-1309
Facsimile: (408) 435-8687

with a copy to:

Fenwick & West LLP
Two Palo Alto Square
Palo Alto, CA 94306
Attention: David Healy, Esq.
Telephone: (650) 494-0600
Facsimile: (650) 494-1417

        ii)    if to Asia Pacific, at:

Asia Pacific Growth Fund III, L.P.
156 University Avenue
Palo Alto, CA 94301
Attention: Mark Hsu
Telephone: (650) 838-8088
Facsimile: (650) 838-0801

with a copy to:

O'Melveny & Myers LLP
Embarcadero Center West

4

--------------------------------------------------------------------------------

275 Battery Street
San Francisco, CA 94111-3305
Attention: Peter Healy, Esq.
Telephone: (415) 984-8700
Facsimile: (415) 984-8701

        iii)  if to Vertex, at:

Vertex Technology Fund Ltd.
Vertex Technology Fund (II) Ltd.
Vertex Technology Fund (III) Ltd.
77 Science Park Drive
#02-15 Cintech III
Singapore Science Park
Singapore 118256
Attention: Kheng Nam Lee, President
Telephone: 011-65-777-0122
Facsimile: 011-65-777-1878 or 011-65-773-2628

and

Vertex Management, Inc.
Three Lagoon Drive, Suite 220
Redwood City, CA 94065
Attention: Hock Chuan Tam, Senior Vice President
Telephone: (650) 591-9300
Facsimile: (650) 591-5926

with a copy to:

Carr & Ferrell LLP
2225 E. Bayshore Road, Suite 200
Palo Alto, CA 94303
Attention: Barry Carr, Esq.
Telephone: (650) 812-3400
Facsimile: (650) 812-3444

        iv)  if to the other Investors, at:

STT Ventures Ltd
    Registered Office:
10 Frere Felix de Valois Street
Port Louis, Mauritius
Correspondence Address:
    51 Cuppage Road, # 10-11/17 Starhub Centre
Singapore 229469
Attention: Tee Beng Huat, Vice President, Business Development
Telephone: 65-6-723-8777
Facsimile: 65-6-720-7288

Green Dot Capital (BVI) Inc
    Registered Office:
P.O. Box 957
Offshore Incorporations Centre
Road Town, Tortola

5

--------------------------------------------------------------------------------

British Virgin Islands
    Correspondence Address:
c/o 8 Shenton Way, # 09-02
Temasek Tower
Singapore 068811
Attention: Ms. Ong Lay Peng
Telephone: 65-6-824-6818
Facsimile: 65-6-820-8090

and

Singapore Computer Systems Limited
7 Bedok South Road
Singapore 469272
Attention: Ms. Wendy Ng
Telephone: 65-6-827-3887
Facsimile: 65-6-827-3104

with a copy to:

Carr & Ferrell LLP
2225 E. Bayshore Road, Suite 200
Palo Alto, CA 94303
Attention: Barry Carr, Esq.
Telephone: (650) 812-3400
Facsimile: (650) 812-3444

Any party hereto (and such party's permitted successors, assigns or transferees)
may by notice so given provide and change its address for future notices
hereunder. Notice shall conclusively be deemed to have been given when
personally delivered or when deposited in the mail in the manner set forth
above.

        b)    Entire Agreement.    This Agreement constitutes and contains the
entire agreement and understanding of the parties with respect to the subject
matter hereof and supersedes any and all prior negotiations, correspondence,
agreements, understandings, duties or obligations between the parties respecting
the subject matter hereof.

        c)    Amendment; Waiver.    Any provision of this Agreement may be
amended and the observance thereof may be waived (either generally or in a
particular instance and either retroactively or prospectively) only with the
written consent of the Company, Asia Pacific, Vertex and the Investors (and/or
any of their permitted successors or assigns) holding shares of Series A
Preferred Stock and/or shares of Common Stock issued upon conversion thereof
representing and/or convertible into a majority of all the Investors' Shares (as
defined below). As used herein, the term "Investors' Shares" shall mean the
shares of Common Stock then issuable upon conversion of all then outstanding
shares of Series A Preferred Stock issued under the Series A Agreement and, in
the event any of the Warrants has been exercised, all shares of Common Stock
issuable upon conversion of Series A Preferred Stock issued upon exercise of
such Warrants. Any amendment or waiver effected in accordance with this
subsection 6(c) shall be binding upon each Investor, each permitted successor or
assignee of such Investor and the Company.

        d)    Governing Law.    This Agreement shall be governed by and
construed exclusively in accordance with the internal laws of the State of
California as applied to contracts made and to be performed entirely within the
State of California, excluding that body of law relating to conflict of laws and
choice of law.

6

--------------------------------------------------------------------------------

        e)    Severability.    If one or more provisions of this Agreement are
held to be unenforceable under applicable law, then such provision(s) shall be
excluded from this Agreement and the balance of this Agreement shall be
interpreted as if such provision(s) were so excluded and shall be enforceable in
accordance with its terms.

        f)    Third Parties.    Nothing in this Agreement, express or implied,
is intended to confer upon any person, other than the parties hereto (and their
successors and assigns), any rights or remedies under or by reason of this
Agreement.

        g)    Successors and Assigns.    The provisions of this Agreement shall
inure to the benefit of, and shall be binding upon, the successors and permitted
assigns of the parties hereto.

        h)    Counterparts.    This Agreement may be executed in counterparts,
each of which shall be deemed an original, but all of which together shall
constitute one and the same instrument.

[Remainder of this page intentionally left blank.]

7

--------------------------------------------------------------------------------

        IN WITNESS WHEREOF, the parties hereto have executed this Stockholder
Agreement as of the date and year first above written.

GRIC COMMUNICATIONS, INC.
 
ASIA PACIFIC GROWTH FUND III, L.P.
By:
/s/ Hong Chen

--------------------------------------------------------------------------------

 
By:
/s/ Ta-Lin Hsu

--------------------------------------------------------------------------------

Name:
Hong Chen

--------------------------------------------------------------------------------

 
Name:
Ta-Lin Hsu

--------------------------------------------------------------------------------

Title:
 
 
Title:
   

--------------------------------------------------------------------------------

   

--------------------------------------------------------------------------------

VERTEX TECHNOLOGY FUND LTD.
 
VERTEX TECHNOLOGY
FUND (II) LTD.
By:
/s/ Lee Kheng Nam

--------------------------------------------------------------------------------

 
By:
/s/ Lee Kheng Nam

--------------------------------------------------------------------------------

Name:
Lee Kheng Nam

--------------------------------------------------------------------------------

 
Name:
Lee Kheng Nam

--------------------------------------------------------------------------------

Title:
Attorney-in-Fact

--------------------------------------------------------------------------------

 
Title:
Attorney-in-Fact

--------------------------------------------------------------------------------

VERTEX TECHNOLOGY
FUND III LTD.
 
STT VENTURES LTD
By:
/s/ Lee Kheng Nam

--------------------------------------------------------------------------------

 
By:
/s/ Tee Beng Huat

--------------------------------------------------------------------------------

Name:
Lee Kheng Nam

--------------------------------------------------------------------------------

 
Name:
Tee Beng Huat

--------------------------------------------------------------------------------

Title:
Attorney-in-Fact

--------------------------------------------------------------------------------

 
Title:
         

--------------------------------------------------------------------------------

GREEN DOT CAPITAL (BVI) INC
 
SINGAPORE COMPUTER SYSTEMS
LIMITED
By:
/s/ Sim Mong Tee

--------------------------------------------------------------------------------

 
By:
/s/ Stephen Yeo

--------------------------------------------------------------------------------

Name:
Sim Mong Tee

--------------------------------------------------------------------------------

 
Name:
Stephen Yeo

--------------------------------------------------------------------------------

Title:
 
 
Title:
   

--------------------------------------------------------------------------------

   

--------------------------------------------------------------------------------

8

--------------------------------------------------------------------------------

[SIGNATURE PAGE TO GRIC COMMUNICATIONS, INC. STOCKHOLDER
AGREEMENT]

9

--------------------------------------------------------------------------------

EXHIBIT A

Schedule of Investors

Asia Pacific Growth Fund III, L.P.
156 University Avenue
Palo Alto, CA 94301
Attention: Mark Hsu
Telephone: (650) 838-8088
Facsimile: (650) 838-0801

Vertex Technology Fund Ltd.
Vertex Technology Fund (II) Ltd.
Vertex Technology Fund (III) Ltd.
77 Science Park Drive
#02-15 Cintech III
Singapore Science Park
Singapore 118256
Attention: Kheng Nam Lee, President
Telephone: 011-65-777-0122
Facsimile: 011-65-777-1878 or 011-65-773-2628
Email: leekn@vertex.st.com.sg

STT Ventures Ltd
    Registered Office:
10 Frere Felix de Valois Street
Port Louis, Mauritius
    Correspondence Address:
51 Cuppage Road, # 10-11/17
Starhub Centre
Singapore 229469
Attention: Tee Beng Huat
Telephone: 65-6-723-8777
Facsimile: 65-6-720-7288

Green Dot Capital (BVI) Inc
    Registered Office:
P.O. Box 957
Offshore Incorporations Centre
Road Town, Tortola
British Virgin Islands
    Correspondence Address:
c/o 8 Shenton Way
# 09-02 Temasek Tower
Singapore 068811
Attention: Ms. Ong Lay Peng
Telephone: 65-6-824-6818
Facsimile: 65-6-820-8090

Singapore Computer Systems Limited
7 Bedok South Road
Singapore 469272
Attention: Ms. Wendy Ng
Telephone: 65-6-827-3887
Facsimile: 65-6-827-3104

--------------------------------------------------------------------------------

QuickLinks

STOCKHOLDER AGREEMENT
W I T N E S S E T H
EXHIBIT A Schedule of Investors