We study discrete symmetries of Dijkgraaf-Witten theories and their gauging in the framework of (extended) functorial quantum field theory. Non-abelian group cohomology is used to describe discrete symmetries and we derive concrete conditions for such a symmetry to admit 't Hooft anomalies in terms of the Lyndon-Hochschild-Serre spectral sequence. We give an explicit realization of a discrete gauge theory with 't Hooft anomaly as a state on the boundary of a higher-dimensional Dijkgraaf-Witten theory. This allows us to calculate the 2-cocycle twisting the projective representation of physical symmetries via transgression. We present a general discussion of the bulk-boundary correspondence at the level of partition functions and state spaces, which we make explicit for discrete gauge theories.