The Laws of ArmedConflict (LOAC) prohibit targeting non-combatants, sothe commanderwouldhave been obliged tocancel the order and ceaseactionif he knewwhowas inside.
Not least of these is how cyber operations across national borders are dealt with by the lawsofarmedconflict and their reliance on principles such as proportionality, neutrality, distinction between combatants and non-combatants, and military necessity.
In 1949, in the aftermath of two devastating global wars, new Geneva Conventions were developed to codify the lawsofarmedconflict and to limit the activities of combatants with respect both to other combatants and to non-combatants.