In response to your inquiry, the grand Ayatullah Khamenei says: “Investing in the banks of countries with non-Islamic governments is permissible per se, given that it doesn’t strengthen them politically and economically such that they will use it against Muslims and Islam, and in any case other than mentioned, it is impermissible.” 
In response to another question that asks about what the ruling is on transactions in banks that are located in Muslim countries but have to do with oppressing governments, or are linked to and are affiliated with kafir governments, or linked with private Muslim or non-Muslim institutes, he says: “Halal Islamic transactions [transactions that are acknowledged in Islamic law] with these banks are permissible, only transactions that have to do with getting interest from Islamic banks and institutes is impermissible, unless their capital belongs to non-Muslims.” 
Therefore, investing and depositing money and buying and selling stocks in non-Islamic banks in which the capital therein belongs to non-Muslims are all permissible given that the abovementioned conditions are observed.
For further information, see:
Obtaining interest from non-Islamic banks and working in them, Question 3179 (website: 3425) .