DUBAI, United Arab Emirates — Two Saudi women detained for nearly a month after they defied edicts that prohibit women from driving were referred on Thursday to a court established to try terrorism cases, several people close to the defendants said.

The cases of the two women, Loujain al-Hathloul and Maysa al-Amoudi, were sent to the antiterrorism court in connection with opinions they expressed on Twitter and other social media sites, according to four people close to them.

They did not elaborate on the charges or what the opinions were. Both women have spoken out online against the driving ban. Activists say they fear the case is intended to send a warning to others pushing for greater rights. The four people said they would speak only on the condition of anonymity because they feared government reprisals.

The Specialized Criminal Court, to which their cases were referred, was established in the capital, Riyadh, to try terrorism cases but has also tried and given long prison sentences to a number of human rights workers, peaceful dissidents, activists and critics of the government.