The bill - which now passes to China's senior leadership - has caused deep concern among those who say it could end Hong Kong's unique status.
It could also see China installing its own security agencies in the region for the first time.
The move has already sparked a new wave of anti-mainland protest.
Clashes broke out on Wednesday as Hong Kong's parliament debated a different proposed law, which would make it a crime to disrespect the Chinese national anthem. Hundreds of people were arrested in protests over that and the security law.
Security remains high on Thursday, as a tense debate in the Legislative Council continues.
At least two pro-democracy legislators were ejected from the council on Thursday. One lawmaker, Ted Hui, threw rotten plants on to the floor of the chamber, saying it symbolised the decay of Hong Kong's political system.
"I want the speaker to feel what is meant by rotten," he said.
The speaker deemed the package to be an "unknown dangerous object", and called police and fire crews.