first, it means taking security against (only) unbelievers or tyrants to protect yourself, money, family, country from death or a big harm
It's not between believers.
It's not where no harm will happen to you
It's just saying words, no actions
It harms no body else

3|28|Let not the believers take disbelievers for their friends in preference to believers. Whoso doeth that hath no connection with Allah unless (it be) that ye but guard yourselves against them, taking (as it were) security. Allah biddeth you beware (only) of Himself. Unto Allah is the journeying.

An example,
if a Muslim lives in a country like Burma, where they burn Muslims alive, it's ok for a muslim to say that he is no longer a muslim to avoid burning, but under one circumstance, his heart is still content with Faith. But if he insists on his saying that he is a muslim with no regard to the punishment, it will be better.

Allah said,16|106|Whoso disbelieveth in Allah after his belief save him who is forced thereto and whose heart is still content with Faith but whoso findeth ease in disbelief: On them is wrath from Allah. Theirs will be an awful doom.