[znat' kak svoyi p'at' pal'tsev]

To know something as well as one's own five fingers.

To know something thoroughly; to be quite familiar with something.

Cf. To know something like the palm of one's hand.