The longer leg of a right triangle is 3 cm longer than the shorter leg. The hypotenuse is 6 cm longer than the shorter leg. Find the side lengths of the triangle.