Fluid discontinuities, such as shock fronts and vortex sheets, can reflect waves and become unstable to corrugation. Analytical calculations of these phenomena are tractable in the simplest cases only, while their numerical simulations are biased by truncation errors inherent to discretization schemes. The author lays down a computational framework to study the coupling of normal modes (plane linear waves) through discontinuities satisfying arbitrary conservation laws, as is relevant to a variety of fluid mechanical problems. A systematic method is provided to solve these problems numerically, along with a series of validation cases. As a demonstration, it is applied to magnetohydrodynamic shocks and shear layers to exactly recover their linear stability properties. The straightforward inclusion of nonideal (dispersive, dissipative) effects notably opens a route to investigate how these phenomena are altered in weakly ionized plasmas.