As per the teachings of Siddhartha Gautama (Buddhism), craving is said to be the cause of all suffering that one experiences in human existence. The extinction of this craving leads one to ultimate happiness, or Nirvana. Nirvana means "cessation", "extinction" of suffering. It is also known as "Awakening" or "Enlightenment". As per the teaching of Gautama Buddha, suffering is an inevitable part of life as we know it & the cause of this suffering is attachment to, or craving for worldly pleasures of all kinds. The suffering ends when the craving and desire ends, or one is freed from all desires.
In "Bhagwat Gita" Arjuna asks "Lord Krishna" a very pertinent question,“What makes a person do the wrong thing, even when he/she knows, it’s wrong and don’t want to do it?”
Lord Sri Krishna tells Arjuna that: It is Desire & Lust only which makes a person do the wrong thing, even when he/she knows, it’s wrong and don’t want to do it.
When we desire something then we are empowered by a powerful emotion to get it which clouds our reasoning. Our passionate desires clouds our mind and senses & it distorts our perception and reasoning. It is our relentless passionate desire to enjoy the material pleasures that it leads us to commit Sin. Desire covers our reasoning like smoke covers fire, or dust covers a mirror. Due to this blurred reasoning & our passionate hankering for desires, we do commit Sin in our life.
Below are verses of "Bhagwat Gita" in which "Arjuna" asks "Lord Krishna" about the same:
atha kena prayukto ’yam
papam charati purushah
anicchann api varsneya
balad iva niyojitah" (Bhagwat Gita: Chapter Three verse 36)
"Arjuna said: O Sri Krishna, by what is one impelled to sinful acts, even unwillingly, as if engaged by force?"
kama esa krodha esa
viddhy enam iha vairinam" (Bhagwat Gita: Chapter Three verse 37)
"Sri Krishna said: It is desire & lust only, Arjuna, which is born of contact with the material mode of passion and later transformed into wrath, and which is the all-devouring sinful enemy of this world."
yathadarso malena cha
tatha tenedam avrtam" (Bhagwat Gita: Chapter Three verse 38)
"Sri Krishna said: As fire is covered by smoke, as a mirror is covered by dust, or as the embryo is covered by the womb, the living entity is similarly covered by different degrees of this lust."
"avrtam jnanam etena
duspurenanalena cha" (Bhagwat Gita: Chapter Three verse 39)
"Sri Krishna said: Thus the wise living entity’s pure consciousness becomes covered by his eternal enemy in the form of lust, which is never satisfied and which burns like fire."
"tasmat tvam indriyany adau
papmanam prajahi hy enam
jnana-vijnana-nasanam" (Bhagwat Gita: Chapter Three verse 41)
"Sri Krishna said: Therefore, O Arjuna, in the very beginning curb this great symbol of sin (lust) by regulating the senses, and slay this destroyer of knowledge and self-realization."
"evam buddheh param buddhva
jahi satrum maha-baho
kama-rupam durasadam" (Bhagwat Gita: Chapter Three verse 43)
"Sri Krishna said: Thus knowing oneself to be transcendental to the material senses, mind and intelligence, O Arjuna, one should steady the mind by deliberate spiritual intelligence and thus—by spiritual strength—conquer the desires & lust which is the insatiable enemy."
From the above verses of "Bhagwat Gita" it is very clear that it is the individual's Desire, Lust & constant feeding of one's senses that a person commits sinful activities. Due to such constant craving for desires, one's intelligence gets covered with ignorance, just like a mirror is covered by the dust & one is not able to see the things in right perspective. So we should not constantly hanker to satisfy our desires, rather we should control these desires.