As for the EU, EASA has published SIB 2016-09 which states that: (emphasis mine)
CAT.OP.MPA.210 of Regulation (EU) No 965/2012 stipulates that flight crew members required to be on duty in the flight crew compartment shall remain at the assigned station, unless absence is necessary for the performance of duties in connection with the operations or for physiological needs, provided at least one suitably qualified pilot remains at the controls of the aircraft at all times.
In such cases, the Agency recommends operators to assess the safety and security risks associated with a flight crew member remaining alone in the flight crew compartment.
This assessment should take the following elements into account:
1) the operator’s psychological and security screening policy of flight crews;
2) employment stability and turnover rate of flight crews;
3) access to a support programme, providing psychological support and relief to flight crew when needed; and
4) ability of the operator’s management system to mitigate psychological and social risks.
In other words, it is up to the individual airlines to decide if they want to implement a rule requiring two people in the cockpit at all time. It is not a legal requirement.