See http://web.mit.edu/zoya/www/SVM.pdf
"Pick an arbirary point $x_1$ to lie on line $w^Tx+b=−1$. Then, the closest point on line $w^Tx+b= 1$ to $x_1$ is the point $x_2=x_1+λw$ (since the closest point will always lie on the perpendicular; recall that the vector $w$ is perpendicular to both lines). "
Why should w be perpendicular to both lines? Whats the maths behind this?
In general for the line with equation $w^{T}x + b = c,$ the vector $w$ is a normal vector for the line. To see this, let $x$ and $y$ be two points on the line. Then substituting both points into the equation and subtracting the two results gives \begin{equation*} 0 = w^{T}(x - y) = (x - y)\cdot w. \end{equation*}