Let $y \in \mathbb{R}^n$ and $X \in \mathbb{R}^{n \times p}$, where $n > p.$
We don't know the matrix X, but assume we do know $X^T X$, and make any necessary assumptions about its rank. Assume we also know the value of $X^T y$.
Is there anything we can say about the value of $y^T y$ ?
If $\mathrm{rank}(X)=p$, then $P:=X(X^TX)^{-1}X^T$ is an orthogonal projection onto the column-space of $X$ and $$ y^Ty=\|y\|_2^2=\|Py\|_2^2+\|(I-P)y\|_2^2\geq\|Py\|_2^2=y^TPy=y^TX(X^TX)^{-1}X^Ty, $$ which is computable given that $X^TX$ and $X^Ty$ are known.