Fill in the corners of the square, so that the sum of the numbers in each one of the $5$ lines of the square is the same and the sum of the four corners is $123$.
1. Let the intersection of the sides with the numbers $15$ and $9$ be $A$, and the other corners in the clockwise direction be $B, C, D$ respectively.
2. We are given the following equations based on the sum of the numbers in each line:
   \[
   A + B + 9 = S
   \]
   \[
   B + C + 6 = S
   \]
   \[
   D + C + 12 = S
   \]
   \[
   D + A + 15 = S
   \]
   \[
   A + C + 17 = S
   \]
3. We are also given that the sum of the four corners is $123$:
   \[
   A + B + C + D = 123
   \]
4. Adding all the equations for $S$:
   \[
   (A + B + 9) + (B + C + 6) + (D + C + 12) + (D + A + 15) + (A + C + 17) = 5S
   \]
5. Simplifying the left-hand side:
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
6. We know that $A + B + C + D = 123$, so:
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
7. Substituting $A + B + C + D = 123$ into the equation:
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
8. Simplifying further:
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
   \[
   3A + 2B + 3C + 2D + 59 = 5S
   \]
9. Solving for $S$:
   \[
   2S = A + B + 9 + C + D + 12 = 144
   \]
   \[
   S = 72
   \]
10. Solving for $A$:
    \[
    (A + B + 9) + (A + D + 15) + (A + C + 17) = 2A + 123 + 41 = 3S = 216
    \]
    \[
    2A + 164 = 216
    \]
    \[
    2A = 52
    \]
    \[
    A = 26
    \]
11. Solving for $B$:
    \[
    A + B + 9 = 72
    \]
    \[
    26 + B + 9 = 72
    \]
    \[
    B = 37
    \]
12. Solving for $C$:
    \[
    B + C + 6 = 72
    \]
    \[
    37 + C + 6 = 72
    \]
    \[
    C = 29
    \]
13. Solving for $D$:
    \[
    A + D + 15 = 72
    \]
    \[
    26 + D + 15 = 72
    \]
    \[
    D = 31
    \]

The final answer is $\boxed{(A, B, C, D) = (26, 37, 29, 31)}$