JOHANNESBURG, DEC. 18 -- Gunmen opened fire with automatic rifles and hurled a hand grenade at a group of black policemen marching in formation in a black township near Cape Town today, wounding 10 constables and two civilian passers-by.

It was the fourth serious attack on black policemen in 10 days and appeared to reinforce fears expressed by the white minority government in Pretoria that the outlawed African National Congress guerrilla movement planned to launch a pre-Christmas offensive of ambushes and bombings.

Authorities said the black special constables were being drilled near a police station in the Nyanga township when at least two gunmen appeared over a dune and opened fire on the group. After hurling the grenade, the gunmen escaped as police began to return the fire, officials said.

The police command in Pretoria said one of the constables was seriously wounded and that the injured civilians were a 62-year-old man and a 30-year-old woman who were standing nearby. It said 9-mm shell casings, which are used in AK47 automatic assault rifles, among other weapons, were found at the scene.

The incident was similar to an ambush Saturday in Johannesburg's Soweto township, when gunmen opened fire on a police vehicle, killing two black policemen and wounding four others.

On Tuesday, a black policeman was killed and two others were wounded when a gunman fired on a patrol in Nyanga township. On Dec. 9, two black policemen were wounded when assailants shot at a vehicle carrying 30 officers to their post near the New Crossroads squatters' camp near Cape Town.

Black policemen, employed by the South African police and by township councils, have long been the target of attacks by militant nationalists, who regard them as collaborators with the white government. the frequency of such attacks has increased in recent months, especially against hastily trained special constables, referred to in local jargon as kitkonstables, or instant constables.

The expanded recruitment of black policemen has been viewed by the government as not only helpful in resolving a manpower shortage in law enforcement, but also crucial to forming a link between conservative blacks and the government.

But in practice, one of their main functions has been to protect black town councilmen from attacks by radicals, which in many townships has only served to further alienate them from the local population. In most townships, the councils either have been appointed by the white provincial government or elected by a small turnout of voters in boycotted polling.

The black policemen generally live in heavily guarded compounds protected by barbed wire and usually are escorted to and from their posts. With the increasing numbers of attacks on them, the special constables have begun striking to protest their wages, which are as low as $64 a month.

Meanwhile, the police today reported that three more persons have been killed in clashes between rival black factions around the Natal Province city of Pietermaritzburg, bringing to 10 the number killed this week. More than 200 have been killed in the past eight months.

Authorities said the victims, all black men in their 20s, were stabbed to death in clashes between supporters of the conservative Zulu leader, Mangosuthu Gatsha Buthelezi, and the militant United Democratic Front antiapartheid coalition.