There are many such idioms, not so many proverbs that I can think of.
Maybe the most famous proverb on keeping silent is from ScriptureProverbs 17:28:
Even a fool, when he holds his peace, is counted wise: and he that shuts his lips is esteemed a man of understanding.
It's repeated in various parts of Scripture in different phrasing. I think it's the basis of the familiar
It is better to be silent and be thought a fool, than to speak and remove all doubt.
The following is attributed to Confucius:
Silence is a true friend who never betrays.
In addition to the idioms @Dan Bron mentions, there is also flying under the radar, originally meaning avoiding detection, but now meaning avoiding negative attention as well.
However, even wise people often embrace silence, and there is a saying in teaching that no question is a stupid question. How can one learn if one doesn't ask questions?