We study the sub-Riemannian structure determined by a left-invariant distribution of rank 2 on a step 3 Carnot group of dimension 5. We prove the conjectured cut times of Yu. Sachkov for the sub-Riemannian Cartan problem. Along the proof, we obtain a comparison with the known cut times in the sub-Riemannian Engel group, and a sufficient (generic) condition for the uniqueness of the length minimizer between two points. Hence we reduce the optimal synthesis to solving a certain system of equations in elliptic functions.