In fact, the conversation was anything but friendly. Mr. Sechin, for his part, now contends that Mr. Ulyukayev had solicited a bribe to smooth approvals for an oil deal. In Mr. Ulyukayev’s telling, he had accepted the gift basket of sausages and a bag of wine only to later discover, to his surprise, $2 million in cash tucked in among the other goodies.
In a late-night raid in November, agents arrested Mr. Ulyukayev, whom Mr. Putin quickly fired from his post.
The exchange, analysts say, is a worrying sign for the political climate in Russia. At worst, they say, the case could signal a return to Soviet-era traditions, under which service in the ministries was a tightrope walk over the gulag.
Indeed, the detention of Mr. Ulyukayev was the first arrest of a sitting minister in the post-Soviet period, the newspaper Novaya Gazeta reported. He faces 15 years in prison if convicted. The newspaper described the operation as intended to “minimize the influence of the so-called liberals in the government.”
“This is very unfortunate for the elite,” Valery D. Solovei, an historian at the Moscow State Institute for International Relations, said of the episode, which Mr. Ulyukayev has insisted was a “provocation,” or setup.
His was not the first career to suffer. In 2015, Vladimir I. Yakunin, a longtime associate of Mr. Putin’s and the director of the national railway, was ousted after failing to win support for costly state subsidies for the railways.
Mr. Sechin also figured in a high-profile clash with a prominent private businessman, Vladimir P. Yevtushenkov, who was confined to house arrest for months during the dispute.
Before his arrest, Mr. Ulyukayev and Mr. Sechin had disagreed on another deal, the sale of $11 billion in stock in Rosneft to Glencore, the commodity trader, and the Qatar Investment Authority, the country’s sovereign wealth fund. Mr. Ulyukayev had objected to the use of Russian state funds to prop up the deal, but in the end a government bank, VTB, financed it.
The two men had been locked in a long struggle. Mr. Sechin, a close aide to Mr. Putin, has advocated for Russia to return to a state-dominated economy, particularly in the oil industry.
Mr. Ulyukayev, a protégé of Yegor Gaidar, the late architect of post-Soviet privatizations and an advocate of free-market economics, represented a liberal wing, but appears to have lost the debate.
Now gaunt looking, and wearing denim shirts, Mr. Ulyukayev attends hearings in the Zamoskvoretsky court, where he sits at a cheap, hardwood veneer table and listens to a parade of agents from the Federal Security Service, or F.S.B., testify against him.
Mr. Sechin says that the former minister had, some weeks before the conversation, solicited the bribe with a gesture, during a game of pool, by holding up two fingers, for $2 million, signaling his price.
Mr. Sechin has accused Mr. Ulyukayev of seeking the bribe in exchange for dropping objections to the state oil company’s acquisition of a recently nationalized midsize oil producer, Bashneft. The sale was billed as a privatization; Mr. Ulyukayev had objected that it could not be a privatization if a state company bought it.
In a sting operation coordinated with the F.S.B., the main successor agency to the K.G.B., Mr. Sechin arranged the fateful meeting with Mr. Ulyukayeva in an office at the oil company’s headquarters.
It was not just that Mr. Ulyukayev had obstructed Mr. Sechin’s efforts to expand the state oil company, said Igor M. Bunin, the president of the Center for Political Technologies. He had fallen from favor by delivering depressing economic assessments to Mr. Putin, also helping to seal his fate.
“We have a tsarist system,” Mr. Bunin said. “You cannot upset the president by saying, ‘Your plans are leading to disaster.’ ”
Still, not all has gone in Mr. Sechin’s favor. The hearings, widely expected to be closed, have instead been mostly open to journalists, exposing cartoonish details of Mr. Sechin’s sting operation, such as the basket of sausages.
In the transcripts, published by MediaZona, a Russian news portal, Mr. Sechin appears to know that his nemesis will soon be arrested and vanish into the penal colonies, and seems to toy with him on pivotal issues that have divided the economic policy elite in Russia for years.
He discusses the success of Rosneft in terms of volumes of oil produced, falling back on a Soviet-era fascination with tons of production, whether steel, coal or oil, regardless of its market value.
Mr. Ulyukayev interjects that investors, who can buy shares in Rosneft on the London Stock Exchange, value the company at only a fraction of other oil companies.
“The asset is worth exactly half as much as comparable” companies, he says. In short, Russia’s most important company is not a market success.
Mr. Sechin brushes aside this objection, and then notes the gifts he has prepared. “Take the basket,” Mr. Sechin says, adding, “That’s all, good luck and thank you very much.”
“Goodbye,” Mr. Ulyukayev says.
At a recent court hearing, one of the F.S.B. agents who had organized the sting, Aleksei Kalugin, said he stopped the minister’s car and discovered the bag held not sausage or wine, but stacks of $100 bills still wrapped in bank ribbons.
Russian news media outlets have pointed out that Mr. Ulyukayev had little choice but to accept the gifts, as Mr. Sechin, an avid hunter, is well known for pressing his handmade wild boar sausage on business partners and officials. They come packaged with an artisanal brand name, “From Ivanych,” a reference to Mr. Sechin’s middle name, the business newspaper Vedomosti reported.
The Russian edition of Forbes has reported on Mr. Sechin’s yearslong practice of giving sausages to oil industry executives and government officials. A German chef prepares the links. “The assortment includes 16 types of kielbasa, meatloaf and hot dogs,” the magazine reported. “Most often, the dishes prepared from the hunting trophies of Sechin are sent as gifts to partners and friends of Rosneft.”
Mr. Sechin, the report said, hunts boars from blinds and moose in a traditional Russian hunt in which gamekeepers herd an animal from the forest into a predesignated firing area. “The task for the hunter is to not miss the moment.”