Malfunctioning scaffolding temporarily trapped two people 21 stories above the ground of the Ted Weiss Federal Building Monday afternoon, said Deputy Fire Chief Dan Donoghue.

"They were fine. They were just stuck," he said.

The two were washing windows when the scaffolding got struck on the 30 story building.

Fire department officials cut glass panes and secured the men before pulling them in safely.

They were inside in about 25 minutes, he said.