We have developed a workflow for computing the seismic-wave moduli dispersion and attenuation due to squirt flow in a numerical model derived from a micro X-ray computed tomography image of cracked (through thermal treatment) Carrara marble sample. To generate the numerical model, the image is processed, segmented, and meshed. The finite-element method is adopted to solve the linearized, quasistatic Navier-Stokes equations describing laminar flow of a compressible viscous fluid inside the cracks coupled with the quasistatic Lamé-Navier equations for the solid phase. We compute the effective P- and S-wave moduli in the three Cartesian directions for a model in dry conditions (saturated with air) and for a smaller model fully saturated with glycerin and having either drained or undrained boundary conditions. For the model saturated with glycerin, the results indicate significant and frequency-dependent P- and S-wave attenuation and the corresponding dispersion caused by squirt flow. Squirt flow occurs in response to fluid pressure gradients induced in the cracks by the imposed deformations. Our digital rock-physics workflow can be used to interpret laboratory measurements of attenuation using images of the rock sample.