If you look what causes the shock, there must be an obstruction at the root of it. See the sketch below for a straight and an oblique compression shock:

![straight and oblique shock][1]

In case of the straight shock this can be a blunt body or an intake filled with slower moving air of higher pressure. In case of the oblique shock this is clearly the bend in the wall contour which forces the flow to change direction.

The index 1 denotes conditions ahead of the shock, and 2 those downstream of the shock. For weak straight shocks the product of the speed ahead of the shock $v_1$ and the speed past the shock $v_2$ equals the square of the speed of sound: $$v_1\cdot v_2 = a^2$$
If we call the local [Mach number][2] $Ma$, and if $Ma_1 > 1$, then $Ma_2$ must be smaller than 1, so the flow is always decelerated to subsonic speed by a straight shock. The same holds for the normal component of an oblique shock: It also becomes subsonic. Since the total energy of the gas doesn't change, its pressure, density and temperature rise when it is decelerated.

The incremental pressure change $\delta p$ due to the bend with an incremental angle of $\delta\vartheta$, expressed in terms of the undisturbed flow with the index $\infty$, is proportional to the change in the streamlines:
$$\delta p = -\frac{\rho_{\infty}\cdot v^2_{\infty}}{\sqrt{Ma^2_{\infty} - 1}}\cdot\delta\vartheta$$

[Gas pressure on a molecular level is the number and severity of particle collisions][3]. The air molecules experience more collisions on the downstream side of the shock, since air pressure is higher there. The average  direction of the additional collisions is indeed orthogonal to the shock, because it is the boundary between blissfully unaware molecules at ambient pressure ahead of the shock and their bruised brethren downstream which have just crossed that boundary. Once a molecule has passed the shock, the collisions are coming again equally from all sides and its speed does not change any more.

In subsonic speeds this pressure change can radiate in all directions and becomes a shallow pressure gradient. In supersonic speed, no information about the upcoming pressure change can travel forward, so the change is concentrated in the shock front.


  [1]: https://i.sstatic.net/TYi8X.png
  [2]: https://en.wikipedia.org/wiki/Mach_number
  [3]: http://en.wikipedia.org/wiki/Pressure