They held a 21 second advantage over the home crew at the second mark but that was cut to 13 seconds by the third mark.
Knowing they had to remain in front of the Brazilians to claim gold, Maloney, 24, and Meech, 23, saw their lead cut to six seconds at the next mark as Grael and Kunze opted to head to the opposite side of the course to make up the advantage.
The move paid off for the locals with them grabbing a 10 second lead at the final mark to set up a dramatic drag race to the line and earn gold.
Maloney hoped Rio's fickle winds would do them a favour on the final leg.
"We were getting close, we were getting quite excited. It's never over until it's over in Rio," she said.
"But the Brazilians sailed it out. They made a ballsy call on the leg before that and good on them. They had to do it if they were going to catch us and it worked."