Some technology companies have a service department, like an online music service, that generates profit for it. People buy songs from this store and also pay money to listen to continuous streams of music at a fixed monthly subscription fee. Is it permissible to invest in stocks of this company? If one already has the stocks, should they sell them because of obligatory principle?
It is not permissible to invest in companies that generate part of their profits from unlawful transactions unless it is a small ratio like 1% of the whole or less, for example. Even then, the small ratio (i.e., the profit earned from unlawful transactions) cannot be owned and should be given to needy people.