First, because the parabola must pass through the point (1,2) you must have that
Second, since the given line with slope 5 is to be tangent to the parabola at point (1,2) you must also have that
In other words, you have a system of two linear equations for a and b. - Solve it. - Done!