In its essence, the formation of a government is a social compact entered into by a group of people wherein a balance is formed between the demands for the greater good of society as a whole and the welfare, happiness and freedom of the individual. Thomas Hobbes, in his book Leviathan, believes that individuals are by their nature selfish and chaotic, and they need to be kept under control by an absolute monarch. People trade individual liberty for the stability a monarch brings. From a psychological perspective, day-to-day stability is important—not just from the standpoint of eliminating chaos. It is important to create a reliable steady-state where people can have faith that things will work the same way tomorrow that they did today. This need for consistency is often expressed in terms like "tradition," creating a continuity across generations that is comforting.
The problem with tradition, especially in the USA, is that it's often not the definition of human rights that are debated, but rather the definition of human. Throughout history, rhetoric has been used to exclude women, Native Americans, slaves, and immigrants from being considered fully human and thus deserving of rights like the ability to vote, to hold property, to move about freely, etc. The country was in fact built on a compromise that allowed slave-holding states to continue that practice in exchange for ratifying the Constitution. When Thomas Jefferson wrote of "life, liberty and the pursuit of happiness" in the Declaration of Independence, he was referring to white, male landowners first and foremost.
When individuals exercise their freedoms in ways that upend tradition, they disturb the old order of things. The press is blamed for printing unpleasant truths. Some religions are considered dangerous, especially if it's a religion tied to a particular ethnic group. When someone from a minority group commits a heinous crime, there have been times when mobs ignored due process and took the law into their own hands.
There are also times when actual threats become magnified. When drug use became a serious problem in the USA, the War on Drugs curtailed a number of individual rights. For example, mandatory drug testing can be considered to violate the 4th Amendment of the Constitution (the right to avoid illegal search and seizure), yet the threat of drug-related violence was such that many Americans stated that they were willing to give up these civil liberties if it meant winning the War on Drugs. The attack on 9/11 led to a restriction of individual rights with regard to travel, but the tragedy was such that many Americans were willing to do this if it meant greater security.
Security is at the heart of the conflict between liberties and those who would choose to restrict those liberties. The average person may be more concerned with visceral threats like terrorism or drug-related crime than more abstract liberties like freedom of the press. If the state using surveillance on its citizens can catch more criminals, many are willing to give up the abstract concept of privacy if this fear can be addressed.
If outside forces feel threatening to peoples' way of life, fear is a common reaction. If a minority group that has traditionally had few rights fights to claim its own liberties, this can be seen as a threat to the way of life of the majority. Historical imbalances, combined with commonly perceived threats and prejudices, are frequent enough to account for this level of mass cognitive dissonance regarding security and freedom.