Chinese President Xi Jinping, seen here at the Great Hall of the People in Beijing in January 2015, is meeting with top American tech leaders in Seattle before his state visit to the White House. Reuters/Fred Dufour/Pool

SHANGHAI -- China’s President Xi Jinping is demanding that staff of the state security apparatus give their “absolute loyalty” to the Communist Party and its leaders – following a series of scandals that have shaken the leadership, and led to questions about the dedication of some officials to the party’s cause.

At a meeting held in recognition of state security staff at the Great Hall of the People in Beijing, Xi described them as “nameless heroes” who had done the country many services. But he added that China was now facing a “new historical situation,” with more “unpredictable risk factors,” and was in the midst of an "important period" as the party sought to toughen rules on its members’ behavior. In such circumstances, he said, agents must maintain their loyalty to the party, and a “resolute faith” in its leadership. The security establishment, he stressed, must be “pure, trustworthy and devoted.”

Such a highly publicized meeting with officers of the normally secretive security apparatus is unusual in China. It comes in the wake of the scandal surrounding former security chief Zhou Yongkang, who is now awaiting trial on charges of bribery, abuse of power and revealing state secrets. He is also said to have engaged in “unofficial political activity," which some analysts have interpreted as confirming rumors that Zhou sought to block Xi’s ascent to power in 2012, though there is no independent corroboration of this.

Observers say the president, who is also the party leader, has been consolidating his power since Zhou's downfall with a shakeup of the leadership of the security establishment. The former deputy minister of state security, Ma Jian, also came under investigation earlier this year, accused of serious legal violations.

But Xi’s reference to “risks” in the current period may be a reminder that not everyone in the party is necessarily happy with his cleanup campaign, including a tough crackdown on corruption, which has led to the arrests of thousands of officials, and has restricted others’ access to what many used to see as the perks of the job. Not only have officials been told to avoid banquets, use their official cars less and lead less lavish lifestyles, they have also been ordered to declare their assets. Indeed a pilot program launched recently in Shanghai, requiring the families of medium-ranking officials and above to give up any business interests, is expected to be implemented around the country in the near future.

Anxiety about the loyalty of officials is emphasized in an article published in the latest edition of an Communist Party journal, Seeking Truth (Qiushi), which laments that many senior local officials have wavered in their faith in the party, and are inconsistent in their attitudes, insufficiently motivated and lacking in moral awareness.

Shanghai news website The Paper reported that the article, written by Wang Yanwen, the head of the Communist Party’s propaganda department in Jiangsu, one of eastern China’s wealthiest provinces, noted that some progress had been made in cleaning up the party. Still, it warned that “some senior officials” were now "having doubts" as to whether “Marxism is still effective, whether they still want communism, whether socialism should still be implemented, and whether the leadership of the party should still be maintained.” Wang said this meant these officials were often slack in their work and “lazy in innovating and getting things done.” Indeed, she said some “would rather do nothing at all in order to keep out of trouble.”

Wang also complained that some officials were arrogant, with little interest in the problems of ordinary people. She said they only cared about winning praise from their superiors – and so undertook “white elephant projects” that were only about “image” and “face." Wang added that said some officials only listened to praise and "didn’t want to hear the truth," sought personal gain and exchanged power for money.

She said such people had forgotten the party’s basic aims – and the fact that power should be a “responsibility, not a pleasure.” She called for a new morality, in which officials would embrace self-sacrifice and sharing the people’s burden, would be “pure and honorable” and would avoid “vulgar tastes.”

Wang’s article is the latest evidence that the current Communist Party leadership, which came to power in 2012, is looking more seriously at problems that have dogged the party's image for many years. It is also in line with Xi's campaign to encourage party officials to present a humble face to citizens who have grown tired of official corruption and excess. However, it also hints at the scale of the challenges facing the party – and another article, published in the newspaper of the Central Commission for Disciplinary Inspection, the party body in charge of the anti-corruption campaign, also warned of the problem that many officials were, as it put it, “two-faced.”

It said there was now a "shockingly" long list of officials who had publicly been very outspoken against corruption, but in reality were corrupt themselves. As an example, it referred to Wan Qingliang, a former party secretary of the major southern city of Guangzhou, who was put under investigation last year on corruption charges. It said Wan had turned out to be “rotten to his soul.”

The article said that, in the end, such “two-faced” people were doomed to failure, since they “cannot avoid being unmasked by the party and the people.” It called for better education of officials, in order to prevent such ills in the future, and greater scrutiny of their behavior.

The Communist Party, however, still explicitly rejects the separation of party and state powers that some critics say would stem corruption -- and it has recently also launched a series of campaigns aimed at rooting out what it sees as overly liberal Western ideas, which it believes have led some officials – and many citizens – to lose faith in traditional socialist values. Given the serious problems with party discipline acknowledged by various officials in a number of recent articles, it remains to be seen just how effective the morality campaign will be.