It's true, some fruits pass gas — ethylene gas to be exact. It's released by the growing tips of roots, flowers, damaged tissue (a.k.a. bruising) and during ripening. This hormone is responsible for several plant effects, one of which is ripening. When fruit ripens, ethylene converts the starch in the fruit's flesh into sugar, creating a sweeter, tastier fruit.
When an ethylene gas-producing fruit is placed in a closed environment like a paper bag, the gas begins to accumulate around it, essentially giving it a hearty dose of ripening elixir. And thus, the fruit ripens faster. You can even add a ripened piece of fruit to an unripe one for an additional ethylene boost.
Plastic bags can trap ethylene gas as well, but they are not breathable. So, they also trap moisture which can cause the fruit to rot before it ripens. Paper bags — whether they are brown or white or any color in between — are ideal because they promote airflow. But they aren't the only ideal ripening container. You can also store ripening fruit in other breathable materials such as cotton cloth or even bowls of rice (though this option isn't ideal for softer-skin fruits like peaches).