Their first chance came when Steve Finnan played David Edwards onside but, one-on-one, Liverpool keeper Charles Itandje made an impressive stop from the Luton forward.
There was drama at the other end too when Itandje somehow escaped without being penalised after colliding with Kayode Odejayi as he chased down a long ball on the edge of the Liverpool penalty area.
Devaney produced the cross of his life from out wide on the right and Foster rose highest to nod the ball past the flailing figure of Charles Itandje, who could only help it into the net.