A listening device or eavesdropping devices was a device that allowed people to eavesdrop on conversations. A conversation that was overheard using such a device was said to be bugged. Legal use of such devices required the party being recorded to be aware of the recording. (DS9: "Crossfire")
In 2268, when asked by James T. Kirk how he knew who Kirk was, Jojo Krako explained that he had all of Bela Okmyx's communications bugged and that he couldn't make a date with a woman without him being aware of it. (TOS: "A Piece of the Action")
In 2364, using a tricorder, Natasha Yar confirmed there were no listening devices or other worrisome items present in a hall on Angel I. (TNG: "Angel One")
In 2371, after hearing Chakotay's attempt to contact Kathryn Janeway and Tom Paris through their combadges, Terla described the badges as eavesdropping devices, then confiscated them even as Janeway corrected her. (VOY: "Time and Again")
In 2372, Odo detected a Ferengi eavesdropping device in Deep Space 9's wardroom. When he showed it to Quark, Quark claimed to have been searching for it all over. Odo then surmised that Quark planned to sell information about Shakaar Edon's meeting. Quark then brought up the illegality of eavesdropping on a private conversation without the consent of one of the parties involved. Odo questioned why else Quark would possess an expensive listening device other than for the purpose of illegally listening to Shakaar's private conversations, prompting Quark to explain that it was for the purpose of monitoring his brother Rom's sleep with it, as Rom occasionally stopped breathing in the night. Not believing a word of the Ferengi's excuse, Odo dropped the device in a bowl of punch, rendering it useless. (DS9: "Crossfire")
Deep Space 9's brig contained eavesdropping devices. In 2373, Miles O'Brien turned them off so he and Rom could speak freely without Odo overhearing them. (DS9: "The Assignment")
In 2381, the Scrubble emissary presented Captains Carol Freeman and Maier with what he called a "sacred Scrubble totem" as a gesture of friendship. However, Ensign D'Vana Tendi discovered that the totem contained a listening device which was to be used to uncover Starfleet intelligence. (LD: "Mining The Mind's Mines")