Valve is beta testing a new feature that allows users to trade in-game items, games and other stuff called Steam Trading. Right now they are testing it with Team Fortress 2. From the Steam blog:
"Team Fortress 2 items and Steam Gifts can currently be traded in the Steam Trading Beta.
Any game you've purchased from the store as a gift, or received as an Extra Copy, can be traded to other users. They can be used to trade for other Gifts, or for items in Team Fortress 2.
We've added a new checkout option to the Store when purchasing a gift so you can save it for trading or sending later, to support users who want to save games for trade fodder."
Valve says that it is also working with other developers to incorporate the new feature into games on Steam. Ultimately enabling the feature will be up to developers and publishers that want to use it.
It will be interesting to see what valve does with this new features in its own games, though Team Fortress 2 is a good place to start. Let the hat-trading begin!