  We present an analytical model capable of describing two-photon ionization of
atoms with attosecond pulses in the presence of intermediate and final isolated
autoionizing states. The model is based on the finite-pulse formulation of
second-order time-dependent perturbation theory. It approximates the
intermediate and final states with Fano's theory for resonant continua, and it
depends on a small set of atomic parameters that can either be obtained from
separate \emph{ab initio} calculations, or be extracted from few selected
experiments. We use the model to compute the two-photon resonant photoelectron
spectrum of helium below the N=2 threshold for the RABITT (Reconstruction of
Attosecond Beating by Interference of Two-photon Transitions) pump-probe
scheme, in which an XUV attosecond pulse train is used in association to a weak
IR probe, obtaining results in quantitative agreement with those from accurate
\emph{ab initio} simulations. In particular, we show that: i) Use of finite
pulses results in a homogeneous red shift of the RABITT beating frequency, as
well as a resonant modulation of the beating frequency in proximity of
intermediate autoionizing states; ii) The phase of resonant two-photon
amplitudes generally experiences a continuous excursion as a function of the
intermediate detuning, with either zero or $2\pi$ overall variation.
