A shibboleth is a linguistic marker that is characteristic of members of a group, which is used by another group to identify members of the first group. Such identification typically has bad consequences for the members thus identified.
The story behind the word is recorded in the biblical Book of Judges. The word shibboleth in ancient Hebrew dialects meant ‘ear of grain’ (or, some say, ‘stream’). Some groups pronounced it with a sh sound, but speakers of related dialects pronounced it with an s.
In the story, two Semitic tribes, the Ephraimites and the Gileadites, have a great battle. The Gileadites defeat the Ephraimites, and set up a blockade across the Jordan River to catch the fleeing Ephraimites who were trying to get back to their territory. The sentries asked each person who wanted to cross the river to say the word shibboleth. The Ephraimites, who had no sh sound in their language, pronounced the word with an s and were thereby unmasked as the enemy and slaughtered.