Uganda's parliament has passed a bill that critics said will prevent all public rallies against President Yoweri Museveni and his government.
Opposition parties are threatening a legal challenge to the measure, known as the Public Management Order Bill -- which the president still has to sign into law.
The bill said police must be given advance written notice of any public meeting, and allows police to break up any gathering deemed a breach of the peace. The restrictions would apply to meetings of as few as three people.
Rights groups have criticized Uganda's government as being authoritarian and heavy-handed toward perceived political opponents.
Amnesty International said the government "must stop trying to crush the rights to free speech and peaceful demonstration" enshrined in Uganda's constitution.
President Museveni has led the central African country for 27 years, since a 1986 coup.