In Ukraine, Ukrainians generally defend their country using a certain part of Western weapons. But this does not mean at all that Russia is now at war with NATO. If we proceed from this position, then we can also say that Ukraine is at war with both Iran and North Korea, because Russia has been using the weapons of these countries on Ukrainian territory for a long time.
You are comparing apples and oranges.
Iran, China and Russia has had relations for a long time. There has been many military cooperation as well. For example in the past 20+ years Iran and Russia have been fighting the US-backed terrorists including ISIS in Syria and Iraq. There have been many military exercises as well with China and Russia like the joint drills in Indian ocean and elsewhere ensuring the security of global trade routes.
There is obviously weapons sales among these countries according to international laws as well. After all over 90 countries are customers of advanced Iranian drones among a lot of other things (in the past one of those 90 countries has been Ukraine by the way purchasing certain artillery shell calibers only Iran manufactures). Iran doesn't dictate how they should use what they purchase and is not responsible for how they use it either.
That is not the same with Ukraine. Any weapons sent to Ukraine is not a sale, it is a hand out with a condition attached on how they are allowed to use these weapons as NATO dictates them and Ukraine obeys.
For example the radars they attacked in Russian territories over the past weeks (that long range early warning thing) is attacked under a direct order from United States. Otherwise hitting that radar has absolutely no benefit for Ukraine. It only benefits United States to weaken Russian Nuclear Defense against NATO's nuclear threat.
You reasonably noted that any supply or sale of weapons must comply with international legal standards, and therefore let’s see whether the sale of shells, missiles, drones and other weapons to Russia by Iran and North Korea complies. First, let's look at what applies to the supply of weapons.
According to Article 2 of the International Code of Conduct on Arms Transfers of 2000 (
https://www.un.org/ru/documents/decl_conv/conventions/code_arms.shtml), arms transfers include “any transaction resulting in a change in legal title and/or control in relation to any weapons..., and to any physical movement of any weapons... from one territory to another Such supplies include supplies made in exchange for direct payment, credit, foreign assistance, subsidies. and goods obtained as a result of mutual settlements and barter agreements."
That is, regardless of whether weapons are purchased or supplied to another state as assistance, this is equally regarded as the supply of weapons from one country to another.
Now comes the interesting part: According to Title II, which governs the principles of arms transfers, “arms transfers may only be made if the proposed recipient State or the recipient party in the final destination country complies with all of the following principles, namely:
- if it can be reasonably demonstrated that the proposed supply will not be used by the recipient State or the recipient party in the country of final destination to promote serious violations of human rights, such as genocide and other crimes against humanity, such as “ethnic cleansing” (Article 3 ),
- if the proposed recipient State or recipient party in the country of final destination: does not commit serious violations of the laws and customs of war as set out in the 1949 Geneva Conventions... (Article 4),
- if the proposed recipient State or recipient party in the final destination country complies with international agreements relating to arms embargoes and other military sanctions imposed by the United Nations Security Council... (Article 6),
- if the proposed recipient State or the recipient party in the final destination country is not involved in any armed conflict in the region, unless the United Nations recognizes that it is acting in self-defense in accordance with Article 51 of the Charter of the United Nations (Article 8 ).
All these principles are violated by the Russian Federation as a recipient state of weapons, as well as Iran and North Korea as those supplying them to the Russian Federation.