We study the inverse problem of determining both the source of a wave and its speed inside a medium from measurements of the solution of the wave equation on the boundary. This problem arises in photoacoustic and thermoacoustic tomography, and has important applications in medical imaging. We prove that if $c^{-2}$ is harmonic in $\omega \subset \R^3$ and identically 1 on $\omega^c$, where $\omega$ is a simply connected region, then a non-trapping wave speed $c$ can be uniquely determined from the solution of the wave equation on boundary of $\Omega \supset \supset \omega$ without the knowledge of the source. We also show that if the wave speed $c$ is known and only assumed to be bounded then, under mild assumptions on the set of discontinuous points of $c$, the source of the wave can be uniquely determined from boundary measurements. This is joint work with Christina Knox.