In this passage the devil faces one failure after another, and is constantly having to adjust his goal. First he aimed at the highest possible target.
The devil is allowed to do his worst, yet it makes no difference to the plan of God. Satan must be the most frustrated being in existence for though he tries his utmost to inflict real damage on the cause of God, he never succeeds. Somehow God absorbs the worst the devil can do and turns it instead into a means of glorifying his name. So Satan finds that he is always fighting against himself and doing harm to his own cause and promoting the kingdom of God. He deals with an omnipotent enemy who is not just one step ahead of him, but who has worked out the final endgame before Satan has even started. This is true in spite of the fact that Satan was probably the most intelligent creature ever made. But wisdom comes from God. It can only be retained by those who continue to trust in God and to submit their minds to his infinite wisdom.
Look at the way we are described. If we can keep to this description we are safe. If we just to keep to this description, God will uphold us and all things will work together for our eternal good. They are the people who keep the commandments of God – holiness – and have the testimony of Jesus Christ – witness. These are the twin great callings and duties of every believer: holiness and witness, purity and the gospel. If we keep those uppermost in our mind, and keep to our God-given culture – the word of God and worship and prayer – we will be all the way through to the end.