China has accused the countries of interfering in its internal affairs and defended the security law as crucial to restore order in Hong Kong