China and Germany have reached an agreement on what to do with 15 North Korean refugees who forced their way into a German school in Beijing. But neither side is saying exactly what will happen to the asylum seekers.

China's Foreign Ministry spokesman Kong Quan says the matter has been resolved according to domestic and international laws and in a humanitarian spirit.

According to Mr. Kong, the two sides "reached a consensus" and that consensus "is being implemented." He would not say what that means in practical terms, but a series of similar cases has been resolved by allowing the refugees to go to South Korea via a third country.

The latest episode began Tuesday when 15 North Koreans scrambled over a wall surrounding a school run by the German Embassy.

Over the past year, scores of desperate North Koreans have managed to get out of China by rushing into foreign diplomatic buildings and begging for political asylum and passage to South Korea.

They are among tens of thousands of North Koreans living illegally in China after fleeing repression and starvation in their homeland, which shares a long border with China.

Just this week, Chinese police blocked members of a different North Korean group that tried to push its way into the Embassy of Ecuador. Eight people were captured, four others appeared to escape. And another 21 North Koreans, ranging in age from infancy to retirement age are said to have taken refuge in a diplomatic building run by South Korea's Embassy.

China has promised its Communist ally, North Korea, that it will send home any illegal North Korean migrants it captures. But human rights groups say returned refugees face brutal treatment in North Korea and Beijing has been reluctant to repatriate those who come to public attention.

Mr. Kong of the Foreign Ministry says the Chinese people have treated their starving neighbors well, providing them with food and jobs.

But he is sharply critical of "foreign groups" with "ulterior motives" that incite illegal North Korean migrants to break Chinese laws by "breaking and entering" diplomatic missions.

A German physician, Norbert Vollertsen, says he has helped organize some of these incidents. Dr. Vollertsen says health conditions in North Korea are appalling, and has urged the Chinese not to repatriate the refugees.

Mr. Kong also said many developed nations, including some that criticize China's human rights practices, treat illegal migrants far more harshly than China does.