This is something I have always wondered about.
This falls under what is known as "Trading with the Enemy." The US has had a law since 1917, the Trading with the Enemy Act, which says that the US President can regulate trade between US citizens and declared enemies during times of war. Violation during WWII came with a maximum fine of up to $10,000 and/or ten years imprisonment. Note this only applies in times of declared war so prior to late 1941 this wouldn't have gotten people in trouble.
So in principle US owners would have been cut off from their assets in enemy countries. One example of this which has been discussed at length by historians is the case of IBM, whose German subsidiary, Dehomag, was implicated in the Holocaust. Through 1941, the US-based IBM did maintain close connections with Dehomag; after 1941, it is unclear what connections they had. Dehomag kept operating during the war for the German government. Historians disagree on how culpable IBM should be considered for Dehomag's actions.
In the reverse situation (e.g. German property in America), Roosevelt appointed an Alien Property Custodian who oversaw the investments and used them for American purposes. (This included, interestingly enough, intellectual property.) I presume the Germans had something similar.