proverb

It takes one to know one.

Theme: character Keyword: name

suggests that

people may recognize certain traits in others because they possess those traits themselves, often said in response to an insult.

Example

When one habitual gossip accused another of gossiping, the reply was that it takes one to know one.