Bot Sentry is a Pidgin (libpurple) plugin to prevent Instant Message (IM) spam. It allows you to ignore IMs unless the sender is in your Buddy List, the sender is in your Allow List, or the sender correctly answers a question you have predefined.
Z. Chu, S. Gianvecchio, H. Wang, and S. Jajodia. Conference, 2010 Annual Computer Security Applications Conference (ACSAC 2010), Austin, TX, USA - December 06 - 10, 2010, page 21--30. New York, NY, USA, ACM, (2010)