The most common definition of what is and what is not acceptable in an armed conflict is The Hague Conventions of 1899 and 1907. It was later ammended by the Geneva Conventions.
It is a document much too long to sumarize completely. Here are just some examples of acts it forbids:
- intentionally targeting civilians, their property or civilian infrastructure which has no military value
- using civilians to protect military targets
- mistreating prisoners of war
- dressing troops as civilians
- using insignias of the enemy or of humanitarian organisations
- Attacking medics
- Having medics attack the enemy
- using weapons designed to cause unnecessary suffering or weapons of mass destruction
- ...and many more...
However, in the 21st century where armed conflicts happen less between states but more between states and paramilitary organisations, the applicability of these conventions became disputed. The United States military, for example, ignores several conventions in its war on terror (like not mistreating prisoners of war) stating that their enemy is not an organized state army, so the conventions do not apply.
The conventions also include many clauses which say that when the enemy violates the conventions, it is acceptable to also violate them. That means, for example, when a medic is carrying a rifle, enemy troops may fire at that medic, because he would not have been issued one when he wasn't supposed to use it. Or when the enemy intentionally uses civilians to protect military targets so that it can not be attacked without endangering civilians, killing the civilians together with that target is not considered a warcrime. This specific situation is explained in greater detail in the question "Does international regulation forbid a country to kill children in a conflict if the other part uses them as human shields?".