  We consider the wave equation $(\p_t^2-\Delta_g)u(t,x)=f(t,x)$, in $\R^n$,
$u|_{\R_-\times \R^n}=0$, where the metric $g=(g_{jk}(x))_{j,k=1}^n$ is known
outside an open and bounded set $M\subset \R^n$ with smooth boundary $\p M$. We
define a deterministic source $f(t,x)$ called the pseudorandom noise as a sum
of point sources, $f(t,x)=\sum_{j=1}^\infty a_j\delta_{x_j}(x)\delta(t)$, where
the points $x_j,\ j\in\Z_+$, form a dense set on $\p M$. We show that when the
weights $a_j$ are chosen appropriately, $u|_{\R\times \p M}$ determines the
scattering relation on $\p M$, that is, it determines for all geodesics which
pass through $M$ the travel times together with the entering and exit points
and directions. The wave $u(t,x)$ contains the singularities produced by all
point sources, but when $a_j=\lambda^{-\lambda^{j}}$ for some $\lambda>1$, we
can trace back the point source that produced a given singularity in the data.
This gives us the distance in $(\R^n, g)$ between a source point $x_j$ and an
arbitrary point $y \in \p M$. In particular, if $(\bar M,g)$ is a simple
Riemannian manifold and $g$ is conformally Euclidian in $\bar M$, these
distances are known to determine the metric $g$ in $M$. In the case when $(\bar
M,g)$ is non-simple we present a more detailed analysis of the wave fronts
yielding the scattering relation on $\p M$.
