This work deals with the study of the analytical relations between porosity of cancellous bone and its mechanical properties. The Stieltjes representation of the effective shear complex modulus of cancellous bone is exploited to recover porosity. The microstructural information is contained in the spectral measure in this analytical representation. The spectral function can be recovered from the effective measurements over a range of frequencies. The problem of reconstruction of the spectral measure is very ill-posed. Regularized algorithm is derived to ensure stability of the results. The proposed method does not use any specific assumptions about the microgeometry of bone. The approach does not rely on correlation analysis, it uses analytical relationships. For validation purposes, complex shear modulus over a range of frequencies was calculated by the finite element method using micro-computed tomography (micro-CT) images of human cancellous bone. The calculated values were used in numerical algorithm to recover bone porosity. At the microlevel, bone was modeled as a heterogeneous medium composed of trabeculae tissue and bone marrow treated as transversely isotropic elastic and isotropic viscoelastic materials, respectively. Recovered porosity values are in excellent agreement with true porosity found from the corresponding micro-CT images.