Context. Sulfur monoxide (SO) is known to be a good shock tracer in molecular clouds and protostar environments, but its abundance is difficult to reproduce, even with state-of-the-art astrochemical models. Aims. We investigate the properties of the observed SO emission in the protoplanetary disk of AB Auriga, a Herbig Ae star of 2.4 M⊙ in mass, located at 156 pc. The AB Aur system is unique because it exhibits a dust trap and at least one young putative planet orbiting at about 30 au from the central star. Methods. We reduced ALMA archival data (projects 2019.1.00579.S, 2021.1.00690.S, and 2021.1.01216.S) and analyzed the three detected SO lines (SO 65 − 54, 67 − 56 and 56 − 45). We also used C17O and C18O 2–1 data to complement the interpretation of the SO data. Results. For the three SO lines, the maximum SO emission in the ring is not located in the dust trap. Moreover, the inner radius of the SO ring is significantly larger than the CO emission inner radius, ∼160 au versus ∼90 au. The SO emission traces gas located in part beyond the dust ring. This emission likely originates from shocks at the interface of the outer spirals, observed in CO and scattered light emission, as well as those in the molecular and dust ring. Also, SO is detected within the cavity, at a radius of ∼20 − 30 au and with a rotation velocity compatible with the protoplanet P1. We speculate that this SO emission originates from accretion shocks onto the circumplanetary disk of the putative protoplanet P1. Conclusions. These observations confirm that SO is a good tracer of shocks in protoplanetary disks and could serve as a powerful new tool for detecting embedded (proto)planets.