Make signatures canonical with S <= order/2
Adding signature check for S <= order/2