ISLAMABAD, Pakistan — Gunmen killed 14 commuter bus passengers in southwestern Pakistan on Thursday, apparently singling out people who worked for the armed services, in an attack claimed by separatists in Baluchistan province.

The killings took place on the coastal highway near Ormara, in Gwadar district, where armed men dressed as paramilitary forces stopped six buses late Wednesday night. They checked the passengers’ identification papers and separated 16 of them from the group, then let the rest go.

The local police found the victims’ bodies, which had been shot at close range, early Thursday. Two of those pulled from the buses managed to escape, officials said.

A separatist group, Raji Aajoi Sangar, claimed responsibility for the killings and said that all of the dead were part of the security forces.