  We explore 4d Yang-Mills gauge theories (YM) living as boundary conditions of
5d gapped short/long-range entangled (SRE/LRE) topological states.
Specifically, we explore 4d time-reversal symmetric pure YM of an SU(2) gauge
group with a second-Chern-class topological term at $\theta=\pi$
(SU(2)$_{\theta=\pi}$ YM), by turning on background fields for both the
time-reversal (i.e., on unorientable manifolds) and 1-form center global
symmetry. We find four classes of time-reversal and Lorentz symmetry-enriched
SU(2)$_{\theta=\pi}$ YM, labeled by $(K_1, K_2)$: $K_1=0,1$ specifies Kramers
singlet/doublet Wilson line and new mixed higher 't Hooft anomalies; $K_2=0,1$
specifies boson/fermionic Wilson line and a new Wess-Zumino-Witten-like
counterterm. Higher anomalies indicate that to realize all higher $n$-global
symmetries locally on $n$-simplices, the 4d theory becomes a boundary of a 5d
higher-symmetry-protected topological state (SPTs, as an invertible topological
quantum field theory (TQFT) or a cobordism invariant in math, or as a 5d
higher-symmetric interacting topological superconductor in condensed matter).
By dynamically gauging the 1-form symmetry, we transform a 5d bulk SRE SPTs
into an LRE symmetry-enriched topologically ordered state (SETs); thus we
obtain the 4d SO(3)$_{\theta=\pi}$ YM-5d LRE-higher-SETs coupled system with
higher-form gauge fields. We further derive new exotic anyonic statistics of
extended objects such as 2-worldsheet of strings and 3-worldvolume of branes,
physically characterizing the 5d SETs. We discover triple and quadruple link
invariants associated with the 5d higher-gauge TQFTs, hinting at a relation
between non-supersymmetric 4d pure YM and topological links in 5d. We provide
4d-5d lattice simplicial complex regularizations and bridge to 4d quantum spin
liquids. We constrain gauge dynamics by higher anomalies and a higher
symmetry-extension method.
