Being a 7.62, it's probably from an AK47 that are common around Rio de Janeiro. Given the routes for that plane, I'd bet it was shot while landing at GIG. Probably after flying over some "favela", a straight-up shot could reach it.
And considering that drug dealers use to fire just to practice or for fun, I bet someone just aimed and shot.
Luckily, no serious damage was done nor a passenger was hit.