SB 6.17.29

dehināṁ deha-saṁyogād
 dvandvānīśvara-līlayā
sukhaṁ duḥkhaṁ mṛtir janma
 śāpo ’nugraha eva ca
Synonyms: 
dehinām — of all those who have accepted material bodies; deha-saṁyogāt — because of contact with the material body; dvandvāni — dualities; īśvara-līlayā — by the supreme will of the Lord; sukham — happiness; duḥkham — distress; mṛtiḥ — death; janma — birth; śāpaḥ — curse; anugrahaḥ — favor; eva — certainly; ca — and.
Translation: 
Because of the actions of the Supreme Lord’s external energy, the living entities are conditioned in contact with material bodies. The dualities of happiness and distress, birth and death, curses and favors, are natural by-products of this contact in the material world.
Purport: 

In Bhagavad-gītā we find, mayādhyakṣeṇa prakṛtiḥ sūyate sa-carācaram: the material world works under the direction of the goddess Durgā, the material energy of the Lord, but she acts under the direction of the Supreme Personality of Godhead. This is also confirmed in the Brahma-saṁhitā (5.44):

sṛṣṭi-sthiti-pralaya-sādhana-śaktir ekā
 chāyeva yasya bhuvanāni bibharti durgā

Durgā — the goddess Pārvatī, the wife of Lord Śiva — is extremely powerful. She can create, maintain and annihilate any number of universes by her sweet will, but she acts under the direction of the Supreme Personality of Godhead, Kṛṣṇa, not independently. Kṛṣṇa is impartial, but because this is the material world of duality, such relative terms as happiness and distress, curses and favors, are created by the will of the Supreme. Those who are not nārāyaṇa-para, pure devotees, must be disturbed by this duality of the material world, whereas devotees who are simply attached to the service of the Lord are not at all disturbed by it. For example, Haridāsa Ṭhākura was beaten with cane in twenty-two bazaars, but he was never disturbed; instead, he smilingly tolerated the beating. Despite the disturbing dualities of the material world, devotees are not disturbed at all. Because they fix their minds on the lotus feet of the Lord and concentrate on the holy name of the Lord, they do not feel the so-called pains and pleasures caused by the dualities of this material world.