Malaysia legislation
Section 9
of Ports And Harbours Ports Harbours And Dues Regulations 2008
Section 9
The master of every ship entering or leaving port between sunrise to sunset shall hoist the Malaysia ensign and the signal letters. The signal letters may be lowered when the ship is safely berthed and cleared but the Malaysia Ensign shall be exhibited from sunrise to sunset during the ship stay in port or anchorage.