JOHANNESBURG, South Africa (AP) _ Officials in the Ciskei black homeland Friday accused a South African army officer working for the rival Transkei homeland of masterminding an aborted raid on Ciskei's presidential compound.

Heavily armed men attacked the home of Ciskei's president, Lennox Sebe, on Thursday but were repulsed by guards. One attacker was killed and six were captured, leaving 16 at large. Sebe and his family were not harmed.

Immediately after the attack, Ciskei blamed Transkei, saying Transkei wanted to kidnap Sebe with the objective of merging the two homelands. Transkei denied the allegations.

The two homelands, nominally independent but not recognized by other countries, have been feuding for months. They are home to most of South Africa's 6 million Xhosa.

In a statement Friday, Ciskei officials said an officer identified as Maj. Van der Riet masterminded the raid. They said Van der Riet was a member of the South African Defense Force and was ''appointed to the Transkei defense.''

The statement did not make it clear whether Van der Riet had been captured. It said that ''according to appointment cards left behind this (Van der Riet) is a member of the SADF ... and his rank is that of a staff sergeant.''

In Johannesburg, the South African Defense Force said in a statement that it was ''not aware of a Maj. Van der Riet'' but added it was possible he had served in the South African army at one time.

Ciskei officials also said they found it ''incomprehensible'' that trucks with armed men used in the attack passed through South African territory without being noticed. Ciskei and Transkei are separated by a narrow strip of South African terrritory.

The South African Defense Force statement did not address that issue.

The South African government did not comment. It had issued a warning to Transkei on Thursday, saying it would not tolerate the use of South African territory for attacks on Ciskei. However, the South African government also said it could not take sides in the dispute.

The Citizen, a Johannesburg newspaper, on Friday quoted unidentified South African intelligence sources as saying they had confirmed Transkei's involvement in the attack.

Ciskei officials said earlier that they were looking for a Frenchman, Michael Desbele, in connection with the raid. They said the car driven by Desbele was one of three vehicles used in the attack.

Business Day, a Johannesburg newspaper, said Desbele was a professional soldier who served in the Rhodesian army during the civil war there that ended in 1980 with the black majority taking power. The country is now Zimbabwe.

Ciskei has been feuding with Transkei for six months and announced Wednesday that all Transkeians in its territory must leave by Aug. 31.

One of the unresolved issues between the two countries centers around Gen. Charles Sebe, a brother of Ciskei's president.

Charles Sebe, at one time Ciskei's police and military chief, was jailed in Ciskei in 1983 for allegedly plotting a coup against his brother. He escaped last year and was given political asylum in Transkei.

Ciskei and Transkei are two of four tribal homelands designated as independent by South Africa but whose sovereignty is not recognized abroad.

They border the Indian Ocean on South Africa's southeast coast, about 50 miles apart with the port of East London between them. Inland, as little as 15 miles separates them.

They are impoverished one-party states led by strongmen who cooperate with the white authorities in South Africa.