When the Messenger of Allah ﷺ passed away and Abu Bakr became caliph, some of the Arabs reverted to disbelief.Umar
said, "How can you fight these people, when the Messenger of Allah ﷺ has said, 'I have been commanded to fight people until they declare that there is no god but Allah. Whoever says it has secured his wealth and life from me, except by its rightful claim, and his reckoning is with Allah'?"
لما توفي رسول الله ﷺ، وكان أبو بكر رضي الله عنه، وكفر من كفر من العرب، فقال عمر رضي الله عنه: كيف تقاتل الناس؟ وقد قال رسول الله ﷺ: أمرت أن أقاتل الناس حتى يقولوا: لا إله إلا الله، فمن قالها فقد عصم منى ماله ونفسه إلا بحقه، وحسابه على الله.
Bukhari narrated it in the Book of Zakat (1399) and Muslim in the Book of Faith (20), both of them through Zuhri, who said, Ubaydullah bin Abdullah bin Utba bin Masud told us that Abu Hurairah said, then he related it. The wording given here is that of Bukhari.