<PAGE>

                                                                    EXHIBIT 10.4



                                 VERIFONE, INC.

                              AMENDED AND RESTATED 

                          EMPLOYEE STOCK PURCHASE PLAN 



              Adopted by the Board of Directors on January 25, 1990
                   Approved by the Stockholders June 22, 1990
               Amended by the Board of Directors on March 21, 1994
                    Approved by the Stockholders May 11, 1994
       Amended and Restated by the Board of Directors on January 23, 1997




     1.   PURPOSE. 

          (a)  The purpose of the Plan is to provide a means by which employees 
of VeriFone, Inc., a Delaware corporation (the "Company"), and its Affiliates, 
as defined in subparagraph 1(b), which are designated as provided in 
subparagraph 2(b), may be given an opportunity to purchase stock of the Company.

          (b)  The word "Affiliate" as used in the Plan means any parent 
corporation or subsidiary corporation of the Company, as those terms are defined
in Sections 424(e) and (f), respectively, of the Internal Revenue Code of 1986, 
as amended (the "Code").

          (c)  The Company, by means of the Plan, seeks to retain the services 
of its employees, to secure and retain the services of new employees, and to 
provide incentives for such persons to exert maximum efforts for the success of
the Company.

          (d)  The Company intends that the rights to purchase stock of the 
Company granted under the Plan be considered options issued under an "employee 
stock purchase plan" as that term is defined in Section 423(b) of the Code.

     2.   ADMINISTRATION. 

          (a)  The Plan shall be administered by the Board of Directors (the 
"Board") of the Company unless and until the Board delegates administration to a
Committee, as provided in subparagraph 2(c).  Whether or not the Board has 
delegated administration, the Board shall have the final power to determine all 
questions of policy and expediency that may arise in the administration of the 
Plan.

          (b)  The Board shall have the power, subject to, and within the 
limitations of, the express provisions of the Plan:

<PAGE>

               (i)   To determine when and how rights to purchase stock of the 
Company shall be granted and the provisions of each offering of such rights 
(which need not be identical).

               (ii)  To designate from time to time which Affiliates of the 
Company shall be eligible to participate in the Plan.

               (iii) To construe and interpret the Plan and rights granted
under it, and to establish, amend and revoke rules and regulations for its 
administration.  The Board, in the exercise of this power, may correct any 
defect, omission or inconsistency in the Plan, in a manner and to the extent it 
shall deem necessary or expedient to make the Plan fully effective.

               (iv)  To amend the Plan as provided in paragraph 13.

               (v)   Generally, to exercise such powers and to perform such 
acts as the Board deems necessary or expedient to promote the best interests of 
the Company.

          (c)  The Board may delegate administration of the Plan to a Committee 
composed of not fewer than two (2) members of the Board (the "Committee").  If 
administration is delegated to a Committee, the Committee shall have, in 
connection with the administration of the Plan, the powers theretofore possessed
by the Board, subject, however, to such resolutions, not inconsistent with the 
provisions of the Plan, as may be adopted from time to time by the Board. The 
Board may abolish the Committee at any time and revest in the Board the 
administration of the Plan.

     3.   SHARES SUBJECT TO THE PLAN.

          (a)  Subject to the provisions of paragraph 12 relating to adjustments
upon changes in stock, the stock that may be sold pursuant to rights granted 
under the Plan shall not exceed in the aggregate one million four hundred eighty
thousand (1,480,000) shares of the Company's $.01 par value common stock (the 
"Common Stock").  If any right granted under the Plan shall for any reason 
terminate without having been exercised, the Common Stock not purchased under 
such right shall again become available for the Plan.

          (b)  The stock subject to the Plan may be unissued shares or 
reacquired shares, bought on the market or otherwise.  

     4.   GRANT OF RIGHTS; OFFERING.

          The Board or the Committee may from time to time grant or provide for 
the grant of rights to purchase Common Stock of the Company under the Plan to 
eligible employees (an "Offering") on a date or dates (the "Offering Date(s)") 
selected by the Board or the Committee.  Each Offering shall be in such form and
shall contain such terms and conditions as the Board or the Committee shall deem
appropriate.  If an employee has more than one right outstanding under the Plan,
unless he or she otherwise indicates in agreements

<PAGE>

or notices delivered hereunder:  (1) each agreement or notice delivered by that 
employee will be deemed to apply to all of his or her rights under the Plan, and
(2) a right with a lower exercise price (or an earlier-granted right, if two 
rights have identical exercise prices), will be exercised to the fullest 
possible extent before a right with a higher exercise price (or a later-granted 
right, if two rights have identical exercise prices) will be exercised.  The 
provisions of separate Offerings need not be identical, but each Offering shall 
include (through incorporation of the provisions of this Plan by reference in 
the Offering or otherwise) the substance of the provisions contained in 
paragraphs 5 through 8, inclusive.

     5.   ELIGIBILITY. 

          (a)  Rights may be granted only to employees of the Company or, as the
Board or the Committee may designate as provided in subparagraph 2(b), to 
employees of any Affiliate of the Company.  Except as provided in subparagraph 
5(b), an employee of the Company or any Affiliate shall not be eligible to be 
granted rights under the Plan, unless, on the Offering Date, such employee has 
been in the employ of the Company or any Affiliate for such continuous period 
preceding such grant as the Board or the Committee may require, but in no event 
shall the required period of continuous employment be equal to or greater than
two (2) years.  In addition, unless otherwise determined by the Board or the 
Committee and set forth in the terms of the applicable Offering, no employee of 
the Company or any Affiliate shall be eligible to be granted rights under the 
Plan, unless, on the Offering Date, such employee's customary employment with 
the Company or such Affiliate is at least twenty (20) hours per week and at 
least five (5) months per calendar year.

          (b)  The Board or the Committee may provide that, each person who, 
during the course of an Offering, first becomes an eligible employee of the 
Company or designated Affiliate will, on a date or dates specified in the 
Offering which coincides with the day on which such person becomes an eligible 
employee or occurs thereafter, receive a right under that Offering, which right 
shall thereafter be deemed to be a part of that Offering.  Such right shall have
the same characteristics as any rights originally granted under that Offering, 
as described herein, except that:

               (i)   the date on which such right is granted shall be the 
"Offering Date" of such right for all purposes, including determination of the 
exercise price of such right; 

               (ii)  the Purchase Period (as defined below) for such right 
shall begin on its Offering Date and end coincident with the end of such 
Offering; and 

               (iii) the Board or the Committee may provide that if such person 
first becomes an eligible employee within a specified period of time before the 
end of the Purchase Period (as defined below) for such Offering, he or she will 
not receive any right under that Offering.

<PAGE>

          (c)  No employee shall be eligible for the grant of any rights under 
the Plan if, immediately after any such rights are granted, such employee owns 
stock possessing five percent (5%) or more of the total combined voting power or
value of all classes of stock of the Company or of any Affiliate.  For purposes 
of this subparagraph 5(c), the rules of Section 424(d) of the Code shall apply 
in determining the stock ownership of any employee, and stock which such 
employee may purchase under all outstanding rights and options shall be treated 
as stock owned by such employee.

          (d)  An eligible employee may be granted rights under the Plan only if
such rights, together with any other rights granted under "employee stock 
purchase plans" of the Company and any Affiliates, as specified by Section 
423(b)(8) of the Code, do not permit such employee's rights to purchase stock of
the Company or any Affiliate to accrue at a rate which exceeds twenty-five 
thousand dollars ($25,000) of fair market value of such stock (determined at the
time such rights are granted) for each calendar year in which such rights are 
outstanding at any time.

     6.   RIGHTS; PURCHASE PRICE.

          (a)  On each Offering Date, each eligible employee, pursuant to an 
Offering made under the Plan, shall be granted the right to purchase the number 
of shares of Common Stock of the Company purchasable with up to fifteen percent 
(15%) of such employee's Earnings (as defined in Section 7(a)) during the period
which begins on the Offering Date (or such later date as the Board determines 
for a particular Offering) and ends on the date stated in the Offering, which 
date shall be no more than twenty-seven (27) months after the Offering Date (the
"Purchase Period").  In connection with each Offering made under this Plan, the 
Board or the Committee shall specify a maximum number of shares which may be 
purchased by any employee as well as a maximum aggregate number of shares which 
may be purchased by all eligible employees pursuant to such Offering.  In 
addition, in connection with each Offering which contains more than one Exercise
Date (as defined in the Offering), the Board or the Committee may specify a 
maximum aggregate number of shares which may be purchased by all eligible 
employees on any given Exercise Date under the Offering.  If the aggregate
purchase of shares upon exercise of rights granted under the Offering would 
exceed any such maximum aggregate number, the Board or the Committee shall make 
a pro rata allocation of the shares available in as nearly a uniform manner as 
shall be practicable and as it shall deem to be equitable.

          (b)  The purchase price of stock acquired pursuant to rights granted 
under the Plan shall be not less than the lesser of:

               (i)   an amount equal to eighty-five percent (85%) of the fair 
market value of the stock on the Offering Date; or

               (ii)  an amount equal to eighty-five percent (85%) of the fair 
market value of the stock on the Exercise Date.

<PAGE>

     7.   PARTICIPATION; WITHDRAWAL; TERMINATION.

          (a)  An eligible employee may become a participant in an Offering by 
delivering a participation agreement to the Company within the time specified in
the Offering, in such form as the Company provides.  Each such agreement shall 
authorize payroll deductions of up to fifteen percent (15%) of such employee's 
Earnings during the Purchase Period.  "Earnings" is defined as the total 
compensation paid to an employee, including all salary, wages (including amounts
elected to be deferred by the employee, that would otherwise have been paid, 
under any cash or deferred arrangement established by the Company), overtime 
pay, commissions, bonuses, and other remuneration paid directly to the employee,
but excluding profit sharing, the cost of employee benefits paid for by the 
Company, education or tuition reimbursements, imputed income arising under any 
Company group insurance or benefit program, traveling expenses, business and 
moving expense reimbursements, income received in connection with stock options,
contributions made by the Company under any employee benefit plan, and similar 
items of compensation, and such other inclusions and exclusions as shall be 
determined by the Board from time to time with respect to one or more Offerings.
The payroll deductions made for each participant shall be credited to an account
for such participant under the Plan and shall be deposited with the general 
funds of the Company.  A participant may reduce, increase or begin such payroll 
deductions after the beginning of any Purchase Period only as provided for in 
the Offering.  A participant may make additional payments into his or her 
account only if specifically provided for in the Offering and only if the 
participant has not had the maximum amount withheld during the Purchase Period.

          (b)  At any time during a Purchase Period a participant may terminate 
his or her payroll deductions under the Plan and withdraw from the Offering by 
delivering to the Company a notice of withdrawal in such form as the Company 
provides.  Such withdrawal may be elected at any time prior to the end of the 
Purchase Period.  Upon such withdrawal from the Offering by a participant, the 
Company shall distribute to such participant all of his or her accumulated 
payroll deductions (reduced to the extent, if any, such deductions have been 
used to acquire stock for the participant) under the Offering, without interest,
and such participant's interest in that Offering shall be automatically 
terminated.  A participant's withdrawal from an Offering will have no effect 
upon such participant's eligibility to participate in any other Offerings under 
the Plan but such participant will be required to deliver a new participation 
agreement in order to participate in subsequent Offerings under the Plan.

          (c)  Rights granted pursuant to any Offering under the Plan shall 
terminate immediately upon cessation of any participating employee's employment 
with the Company or an Affiliate, for any reason, and the Company shall 
distribute to such terminated employee all of his or her accumulated payroll 
deductions (reduced to the extent, if any, such deductions have been used to 
acquire stock for the terminated employee), under the Offering, without 
interest. 

<PAGE>

           (d)  Rights granted under the Plan shall not be transferable, and 
shall be exercisable only by the person to whom such rights are granted.

     8.   EXERCISE.  

          (a)  On each exercise date, as defined in the relevant Offering (an 
"Exercise Date"), each participant's accumulated payroll deductions (without any
increase for interest) will be applied to the purchase of whole shares of stock 
of the Company, up to the maximum number of shares permitted pursuant to the 
terms of the Plan and the applicable Offering, at the purchase price specified 
in the Offering.  No fractional shares shall be issued upon the exercise of 
rights granted under the Plan.  The amount, if any, of accumulated payroll 
deductions remaining in each participant's account after the purchase of shares 
which is less than the amount required to purchase one share of stock on the 
final Exercise Date of an Offering shall be held in each such participant's 
account for the purchase of shares under the next Offering under the Plan, 
unless such participant withdraws from such next Offering, as provided in 
subparagraph 7(b), or is no longer eligible to be granted rights under the Plan,
as provided in paragraph 5, in which case such amount shall be distributed to 
the participant after said final Exercise Date, without interest.  The amount, 
if any, of accumulated payroll deductions remaining in any participant's account
after the purchase of shares which is equal to the amount required to purchase 
whole shares of stock on the final Exercise Date of an Offering shall be 
distributed in full to the participant after such Exercise Date, without 
interest.

          (b)  No rights granted under the Plan may be exercised to any extent 
unless the Plan (including rights granted thereunder) is covered by an effective
registration statement pursuant to the Securities Act of 1933, as amended (the 
"Securities Act").  If on an Exercise Date of any Offering hereunder the Plan is
not so registered, no rights granted under the Plan or any Offering shall be 
exercised on said Exercise Date and all payroll deductions accumulated during 
the purchase period (reduced to the extent, if any, such deductions have been 
used to acquire stock) shall be distributed to the participants, without 
interest. 

     9.   COVENANTS OF THE COMPANY.

          (a)  During the terms of the rights granted under the Plan, the 
Company shall keep available at all times the number of shares of stock required
to satisfy such rights.

          (b)  The Company shall seek to obtain from each regulatory commission 
or agency having jurisdiction over the Plan such authority as may be required to
issue and sell shares of stock upon exercise of the rights granted under the 
Plan.  If, after reasonable efforts, the Company is unable to obtain from any 
such regulatory commission or agency the authority which counsel for the Company
deems necessary for the lawful issuance and sale of stock under the Plan, the 
Company shall be relieved from any liability for failure to issue and sell stock
upon exercise of such rights unless and until such authority is obtained.

<PAGE>

     10.  USE OF PROCEEDS FROM STOCK.

          Proceeds from the sale of stock pursuant to rights granted under the 
Plan shall constitute general funds of the Company.

     11.  RIGHTS AS A STOCKHOLDER.

          A participant shall not be deemed to be the holder of, or to have any 
of the rights of a holder with respect to, any shares subject to rights granted 
under the Plan unless and until certificates representing such shares shall have
been issued.

     12.  ADJUSTMENTS UPON CHANGES IN STOCK.
 
          (a)  If any change is made in the stock subject to the Plan, or 
subject to any rights granted under the Plan (through merger, consolidation, 
reorganization, recapitalization, stock dividend, dividend in property other 
than cash, stock split, liquidating dividend, combination of shares, exchange of
shares, change in corporate structure or other transaction not involving the 
receipt of consideration by the Company), the Plan and outstanding rights will 
be appropriately adjusted in the class(es) and maximum number of shares subject 
to the Plan and the class(es) and number of shares and price per share of stock 
subject to outstanding rights.  Such adjustments shall be made by the Board or 
the Committee, the determination of which shall be final, binding and 
conclusive.  (The conversion of any convertible securities of the Company shall 
not be treated as a "transaction not involving the receipt of consideration by 
the Company.")

          (b)  In the event of:  (1) a dissolution or liquidation of the Company
or sale of all or substantially all of the Company's assets; (2) a merger or 
consolidation in which the Company is not the surviving corporation; (3) a 
reverse merger in which the Company is the surviving corporation but the shares 
of the Company's Common Stock outstanding immediately preceding the merger are 
converted by virtue of the merger into other property, whether in the form of 
securities, cash or otherwise; or (4) any other capital reorganization in which 
more than fifty percent (50%) of the shares of the Company entitled to vote are 
exchanged, then, as determined by the Board in its sole discretion (i) any 
surviving corporation may assume outstanding rights or substitute similar rights
for those under the Plan, (ii) such rights may continue in full force and 
effect, or (iii) participants' accumulated payroll deductions may be used to 
purchase Common Stock immediately prior to the transaction described above and 
the participants' rights under the ongoing Offering terminated.  

     13.  AMENDMENT OF THE PLAN.

          (a)  The Board at any time, and from time to time, may amend the Plan.
However, except as provided in paragraph 12 relating to adjustments upon changes
in stock, no amendment shall be effective unless approved by the stockholders of
the Company within twelve (12) months before or after the adoption of the 
amendment, where the amendment will:

<PAGE>

          (i)  Increase the number of shares reserved for rights under the Plan;

         (ii)  Modify the provisions as to eligibility for participation 
in the Plan (to the extent such modification requires stockholder approval in 
order for the Plan to obtain employee stock purchase plan treatment under 
Section 423 of the Code); or 

        (iii)  Modify the Plan in any other way if such modification 
requires stockholder approval in order for the Plan to obtain employee stock 
purchase plan treatment under Section 423 of the Code.

It is expressly contemplated that the Board may amend the Plan in any respect 
the Board deems necessary or advisable to provide eligible employees with the 
maximum benefits provided or to be provided under the provisions of the Code and
the regulations promulgated thereunder relating to employee stock purchase plans
and/or to bring the Plan and/or rights granted under it into compliance 
therewith.

          (b)  Rights and obligations under any rights granted before amendment 
of the Plan shall not be impaired by any amendment of the Plan, except with the 
consent of the person to whom such rights were granted.

     14.  TERMINATION OR SUSPENSION OF THE PLAN.

          (a)  The Board may suspend or terminate the Plan at any time.  Unless 
sooner terminated, the Plan shall terminate upon the issuance of all of the 
shares of Common Stock reserved under the Plan.  No rights may be granted under
the Plan while the Plan is suspended or after it is terminated.

          (b)  Rights and obligations under any rights granted while the Plan is
in effect shall not be impaired by suspension or termination of the Plan, except
with the consent of the person to whom such rights were granted.

     15.  EFFECTIVE DATE OF PLAN.

          The Plan shall become effective as determined by the Board, but no 
rights granted under the Plan shall be exercised to allow the issuance of more 
than one million shares of Common Stock (as adjusted pursuant to paragraph 12) 
under the Plan unless and until the Plan has been approved by the stockholders 
of the Company.