After the collapse of the Soviet Union, he became the Minister of Security and Home Affairs of the Russian SFSR (December 1991 - January 1992).
General Director of the Federal Security Agency of the RSFSR (January 1992).
Barannikov initiated the transfer of power under the responsibility of the Interior Ministry to individual republics and ordered the militia to stay away from the political chaos engulfing the capital.
During the Russian Constitutional Crisis in September–October 1993, he tried to mediate between Boris Yeltsin and Supreme Soviet, who wanted to drag him to her side by nominating him as the Minister of Security.
He was arrested and imprisoned for several months, soon after his release he died of a heart attack on July 22, 1995.