The usual duality theory cannot be applied to infinite dimensional problems because the underlying constraint set mostly has an empty interior and the constraints are possibly nonlinear. In this paper we present an infinite dimensional nonlinear duality theory obtained by using new separation theorems based on the notion of quasi-relative interior, which, in all the concrete problems considered, is nonempty. We apply this theory to solve the until now unsolved problem of finding, in the infinite dimensional case, the Lagrange multipliers associated to optimization problems or to variational inequalities. As an example, we find the Lagrange multiplier associated to a general elasticâ€“plastic torsion problem.