The shipping line operates ships globally carrying cargo from Point A to Point B. Sometimes. This transit could involve transit through areas affected by war and other risks.
In cases like that (for example, passage through the Suez Canal/Red Sea at the height of the Iraq War, the shipping line/ship operator needs to cover themselves against any exigencies such as cargo claims, damage, or loss due to the situation of war.
This surcharge is levied to cover the insurance premiums for such passage and is usually charged along with the freight charges.