It's not true that the wicked's treasures, or their millions in their bank accounts, came from the devil, and the income of the righteous comes from God. Everything comes from him. Satan promised Jesus the kingdoms of this world if he bowed down to him--and curiously Jesus didn't say Satan was lying when he said that.
But here's what I think happened--God allowed Satan some use of his properties to test Jesus. And doesn't the bible say that the thief comes only to steal, among other things? Satan probably stole it and God allowed him to for a moment.
It can seem too complicated but you can get more hidden treasures like this. Keep searching for mined power.