Let
$ R_x = \begin{bmatrix} 1 && 0 && 0 \\ 0 && c_1 && - s_1 \\ 0 && s_1 && c_1 \end{bmatrix} $
where $c_1 = \cos \theta_1 , s_1 = \sin \theta_1 $
$R_y = \begin{bmatrix} c_2 && 0 && s_2 \\ 0 && 1 && 0 \\ -s_2 && 0 && c_2 \end{bmatrix} $
where $c_2 = \cos \theta_2 , s_2 = \sin \theta_2 $
$R_z = \begin{bmatrix} c_3 && -s_3 && 0 \\ s_3 && c_3 && 0 \\ 0 && 0 && 1 \end{bmatrix} $
where $c_3 = \cos \theta_3 , s_3 = \sin \theta_3 $, then
$R_x R_y R_z = \begin{bmatrix} 1 && 0 && 0 \\ 0 && c_1 && - s_1 \\ 0 && s_1 && c_1 \end{bmatrix}\begin{bmatrix} c_2 && 0 && s_2 \\ 0 && 1 && 0 \\ -s_2 && 0 && c_2 \end{bmatrix} \begin{bmatrix} c_3 && -s_3 && 0 \\ s_3 && c_3 && 0 \\ 0 && 0 && 1 \end{bmatrix} $
And this reduces to
$ R_x R_y R_z = \begin{bmatrix} c_2 c_3 && - c_2 s_3 && s_2 \\ s_1 s_2 c_3 + c_1 s_3 && - s_1 s_2 s_3 + c_1 c_3 && - s_1 c_2 \\ - c_1 s_2 c_3 + s_1 s_3 && c_1 s_2 s_3 + s_1 c_3 && c_1 c_2 \end{bmatrix} $
And this is to equal a given rotation matrix $R$ given by
$ R = \begin{bmatrix} R_{11} && R_{12} && R_{13} \\ R_{21} && R_{22} && R_{23} \\
R_{31} && R_{32} && R_{33} \end{bmatrix} $
Comparing the third column in both matrices, we deduce that
$ s_2 = \sin \theta_2 = R_{13} $
So that $\theta_2 = \sin^{-1}(R_{13}) $ or $\theta_2 = \pi - \sin^{-1}(R_{13} ) $
From the second and third components of the third column in each matrix, we deduce that corresponding to each of the two possible values of $ \theta_2$ we have
$\theta_1 = \text{atan2} \left( \dfrac{ R_{33} }{c_2} , -\dfrac{ R_{23} }{c_2} \right) $
And from the first row in each matrix, we have
$ \theta_3 = \text{atan2} \left( \dfrac{R_{11}}{ c_2 } , - \dfrac{R_{12}}{c_2} \right) $
Therefore, for each rotation matrix $\in SO(3)$, we can find two factorizations $R_x(\theta_1) R_y(\theta_2) R_z(\theta_3)$ for it.