Tuesday's dual rulings in separate but similar cases highlight the ways in which Facebook leverages user-generated information to produce hundreds of millions of dollars in revenue — and the legal risks it runs in the process.