Let $f(z)$ be analytic in a simply connected domain $D$ and on its boundary, the simple closed contour $C$. If $f(z)$ is injective on $C$, then $f(z)$ is injective on $D$.
If $z_0\in D$ is a point such that $f(z_0)\notin f(C)$ then we can use an argument principle to conclude $f(z_0) = f(z)$ then $z =z_0$ for $z\in D$. This is because by assumption, $f(C)$ is also a simple closed curve. But if there is a point $z\in C$ such that $f(z_0) =f(z)$ then the integrand in the argument principle is not well-defined so I can't use this method. I think the open mapping theorem and maximum modulus principle imply this cannot happen but I can't see the explicit contradiction. Please help.
Edit: There was a comment given by Aphelli which is incomplete but I wonder if it can be resolved: So the idea is using the argument principle with a slight modification on $C$. Since $f$ is holomorphic on $\overline{D}$, there is an open set $U\supset\overline{D}$ such that $f\in\mathcal{H}(U)$. Since $C$ is compact, we can find a simple close curve $C'\subset U$ enclosing $C$ as close as we want. Once we can show there is such $C'$ that $f$ is injective on $C'$ then we can apply the argument principle as before to prove the statement. The problem is the existence of such $C'$. Showing the existence of $C'$ such that $f'\neq 0$ on $C'$ is easy but this only ensures local injectivity on $C'$.